Error when compiling with g++ in Fedora Core 7

Aquil H. Abdullah aquil.abdullah at gmail.com
Sat Jun 16 02:48:02 UTC 2007


Ok, so this was a false alarm.  I didn't have libstdc++-devel installed.  I
am not sure how I missed it.  I apologize for the any undue stress this may
have caused.  I am a bit baffled as to why it did not get installed though?
I selected all of the development tools.  Ok, that's a problem for
tomorrow.  std::cout << "Good Night, World? std::endl;

On 6/15/07, Aquil H. Abdullah <aquil.abdullah at gmail.com> wrote:
>
> Hello All,
>   I have just installed Fedora Core 7 on an x86 system.  It was the
> smoothest install of any Fedora Core that I have attempted.  However, I am
> having a problem using the gnu compiler in particular with g++.  I have
> written a simple hello world program:
>
> #include <iostream>
>
> int main(void)
> {
>   std::cout <<"Hello, World!" << std::endl;
>   return 0;
> }
>
> and attempted to compile it using the command:
>
> [aha at boombata devel]$ g++ -o hello hello.cc
> hello.cc:1:20: error: iostream: No such file or directory
> hello.cc: In function 'int main()':
> hello.cc:5: error: 'cout' is not a member of 'std'
> hello.cc:5: error: 'endl' is not a member of 'std'
>
> As you can see for some reason iostream.h is not being found, even though
> I have confirmed it's existence:
>
> [aha at boombata backward]$ ls /usr/include/c++/4.1.2/backward/iostream.h
> /usr/include/c++/4.1.2/backward/iostream.h
>
> Now I may be in the wrong place for such a question, but does anyone have
> any about how to fix this problem. I am embarrassed to call myself a
> developer :(
>
> Regards
>
> --
> Aquil H. Abdullah
> aquil.abdullah at gmail.com




-- 
Aquil H. Abdullah
aquil.abdullah at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20070615/fce00b58/attachment-0001.htm>


More information about the fedora-list mailing list