[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Alternative compiling for debug/optimized code?
From: |
Daniel Kraft |
Subject: |
Alternative compiling for debug/optimized code? |
Date: |
Thu, 8 Dec 2005 10:24:26 +0100 |
Hi!
Prior to using the GNU build system (especially automake) I used my own plain
Makefiles which set compiler flags like -g, -O2
or -Ds enabling assertions depending on a variable set on commandline. So it was
possible to compile debugging/optimized code just by changing the make-command:
make mode=opt
make mode=debug
...
Using automake the default compiler flags seem to be -g -O2; but most of the
time I don't need debug code, so I want to disable that -g - option. But by
lines like:
konGE_CXXFLAGS = -O2
I just get that -O2 appended to the default -g -O2; so I can't disable -g this
way. What must be done to resolve this issue properly?
And it is possible to do something similiar to the alternative compiling
described above - i.e. to have a simple way for switching opt/debug mode, maybe
without having to reconfigure?
Thank you very much!
Yours,
Daniel Kraft
- Alternative compiling for debug/optimized code?,
Daniel Kraft <=