This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: <iostream> does not work??


Hi,
Guy Van Den Bergh (guy.vandenbergh2@advalvas.be) wrote:
: but looking for faqs and manuals was the first thing I did, before posting a
: message.
: But I didn't find useful information ( I checked the LDP and egcs.cygnus.com a
: second time), but I didn't find anything useful.

Hm... Maybe I was to hasty and remembered incorrectly that this was
covered in the FAQ for this newsgroup. In particular, I didn't find a
FAQ for gnu.g++.help at rtfm.mit.edu at all.

Please excuse this false pointer!

: Finally I discovered how to compile c++ code: use the command g++ instead of
: gcc (by looking what programs are available on my disk, and just try)
: I thought gcc would handle all *.cpp files as c++ code, but it seems not to do
: so.

gcc handles various kinds of source files but it adds only the C
library by default. If you also want to get the C++ library inspected
for missing symbols, you have to pass the flag -lstdc++ (or whatever
librar you are using). g++ includes libstdc++ by default.
: And this was something I have read once in some man page or faq or manual...

: If you do know where I can find a FAQ for such newbie problems, please let me
: know!

I was pretty sure that there is a FAQ for gnu.g++.help which would
corresondingly be available from rtfm.mit.edu. But there is none...

I'm sorry for giving a false pointer in a somewhat unfriendly fashion.
Please excuse this.
--
<mailto:dietmar.kuehl@claas-solutions.de>
<http://www.informatik.uni-konstanz.de/~kuehl/>
I am a realistic optimist - that's why I appear to be slightly pessimistic


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]