This is the mail archive of the gcc@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: specs file method for detecting when preprocessor is being called for C++?


Have you noticed the file cp/lang-specs.h?  Does that help?

Neil.

Christopher Faylor wrote:-

> I'm probably missing something obvious, but I can't find any method for
> setting up a rule which adds additional options to "cpp" when a user is
> invoking g++.
> 
> I've tried something like:
> 
> %{Dcplusplus:blah}
> 
> but that doesn't work.
> 
> Can anyone tell me if this is possible?  I'd like to be able to do this
> with both 2.95.3 and gcc 3.0, if possible.  I don't know if the methods
> would be different for each.
> 
> My reason for wanting this is that I want to completely separate the
> include file parsing for -mcygwin/-mno-cygwin.  In the -mno-cygwin case
> the g++ include file search path should include /usr/include/mingw/g++
> in the -mcygwin case, it should include /usr/include/g++.
> 
> I can't seem to find any way to add these include search paths only when
> g++ is invoked.
> 
> Any pointers are appreciated.
> 
> cgf


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