This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: gcc problem


> 
> g++ is in a separate package named gcc-g++, be sure you have installed
> this too.  Then you need to link against libstdc++ when using gcc as
> driver:
>  gcc -o gtest gtest.cc -lstdc++
> or you use g++ as driver which includes libstdc++ automatically:
>  g++ -o gtest gtest.cc

Just want to drop my usual line here - Do use g++ rather then gcc -lstdc++
Since gcc -lstdc++ isn't always enough, and what is enough may not always be
enough in the future.

Gareth
PS - in response to the other email - .cc Is pre-processor input - since
that's the Normal state for c++ code - pre-processor input of which the
output is then fed to a c++ compiler. (Virtually at least, in practice it
can end up being integrated somewhat.  The C standard allows 'as if'
interpretation in the implementation of the pre-processing component.)



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


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