g++ -D compiler options
- From: markhobley@xxxxxxxxxxxxxxxxxxxxxxxxxxx (Mark Hobley)
- Date: Fri, 21 Mar 2008 15:08:09 GMT
I have some C++ package files, which are currently compiled using a command
line syntax as follows:
g++ -Ddebian -D_GNU_SOURCE -g -O2 -fno-rtti -fno-exceptions -Wall
-Wno-trigraphs -DUSE_TERMIO -DKLUDGELINEMODE foobar.cc -c
What are the effects of the -D options?
-Ddebian
-D_GNU_SOURCE
-DUSE_TERMIO
-DKLUDGELINEMODE
The gcc manual states:
-D name
Predefine name as a macro, with definition 1.
I tried to locate references using:
grep debian *.cc *.h
grep _GNU_SOURCE *.cc *.h
These return nothing.
I did however find #ifdef and #ifndef references for USE_TERMIO and
KLUDGELINEMODE.
Presumably, the -DUSE_TERMIO -DKLUDGELINEMODE options cause inclusion of the
enclosed definitions (or exclusion in the case of #ifndef).
What about the -Ddebian -D_GNU_SOURCE options? Can I just drop these?
FYI, The packages sources are the separated client component of
the netkit-telnet package and am trying to achieve a build using
autotools.
Regards,
Mark.
--
Mark Hobley,
393 Quinton Road West,
Quinton, BIRMINGHAM.
B32 1QE.
.
- Follow-Ups:
- Re: g++ -D compiler options
- From: Daniel Franklin
- Re: g++ -D compiler options
- From: HASM
- Re: g++ -D compiler options
- From: Erik de Castro Lopo
- Re: g++ -D compiler options
- Prev by Date: Re: coding text editor
- Next by Date: Re: coding text editor
- Previous by thread: coding text editor
- Next by thread: Re: g++ -D compiler options
- Index(es):