LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 02-27-2006, 04:12 AM   #1
lucky6969b
Member
 
Registered: Nov 2005
Posts: 337

Rep: Reputation: 30
Can't find exception.h


I tried to compile with commonc++ 2, to no avail.
still crashing on Fedora 4
I was compiling Berkeley DB 4.4
Thanks
Jack
 
Old 02-27-2006, 07:35 PM   #2
lucky6969b
Member
 
Registered: Nov 2005
Posts: 337

Original Poster
Rep: Reputation: 30
g++ -c -g -I. -I/usr/local/BerkeleyDB.4.4/include -D_GNU_SOURCE -D_REENTRANT -O db.cpp -fPIC -DPIC -o db.o
In file included from /usr/lib/gcc/i386-redhat-linux/4.0.0/../../../../include/c++/4.0.0/backward/iostream.h:31,
from db.cpp:1:
/usr/lib/gcc/i386-redhat-linux/4.0.0/../../../../include/c++/4.0.0/backward/backward_warning.h:32:2: warning: #warning This file includes at least one deprecated or antiquated header. Please consider using one of the 32 headers found in section 17.4.1.2 of the C++ standard. Examples include substituting the <X> header for the <X.h> header for C++ includes, or <iostream> instead of the deprecated header <iostream.h>. To disable this warning use -Wno-deprecated.
In file included from db.cpp:3:
/usr/local/BerkeleyDB.4.4/include/db_cxx.h:61:23: error: exception.h: No such file or directory
/usr/local/BerkeleyDB.4.4/include/db_cxx.h:1032: error: expected class-name before ‘{’ token
make: *** [db.o] Error 1

Thx
Jack
 
Old 02-27-2006, 07:36 PM   #3
lucky6969b
Member
 
Registered: Nov 2005
Posts: 337

Original Poster
Rep: Reputation: 30
###### start makefile


INCLUDES = -I. -I/usr/local/BerkeleyDB.4.4/include

.SUFFIXES: .cpp


.cpp.o:
g++ -c -g $(INCLUDES) -D_GNU_SOURCE -D_REENTRANT -O $< -fPIC -DPIC -o $@


SRC = db.cpp
OBJ = $(addsuffix .o, $(basename $(SRC)))


dbx : $(OBJ)
g++ -O -g -o $@ $(OBJ) \
-L/usr/local/BerkeleyDB.4.4/lib -ldb_cxx-4.4 \
-Wl,--rpath -Wl,/usr/local/BerkeleyDB.4.4/lib -ldb-4 -ldbcxx-4


clean:
rm dbx $(OBJ)


###### end makefile

...And the makefile
Thx
Jack
 
Old 02-27-2006, 07:38 PM   #4
lucky6969b
Member
 
Registered: Nov 2005
Posts: 337

Original Poster
Rep: Reputation: 30
Forget to say....
When I installed commonc++ 2, there was still errors, so I did not continue to use it. But even though I have the exception.h in that dir, the compiler still complaint. Thx
Jack
 
Old 02-27-2006, 07:49 PM   #5
lucky6969b
Member
 
Registered: Nov 2005
Posts: 337

Original Poster
Rep: Reputation: 30
And one more thin', I tried once that including c++2 in my search dir,
but after that, the compiler said missing.h was missing but it was obviously resided on the same dir as exception.h, so why?

Thanks
Jack
 
Old 02-27-2006, 11:35 PM   #6
DanTaylor
Member
 
Registered: Jan 2006
Distribution: Debian Sarge
Posts: 265

Rep: Reputation: 30
you know that you can edit your current posts, right?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Exception Handling vipinsharma Programming 2 09-25-2005 11:05 AM
Exception Handling C++ Hady Programming 3 07-26-2005 11:07 PM
help createing exception class from base STL exception qwijibow Programming 4 04-20-2005 05:23 AM
Glib::ustring::find() raises exception! QtCoder Programming 1 12-09-2003 10:29 PM
Runtime Exception vs. Exception mikeshn Programming 1 09-22-2002 05:33 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 12:30 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration