[CMake] How can I add -gstabs to the compile item for Debug?

Kermit Mei kermit.mei at gmail.com
Thu Dec 18 23:41:41 EST 2008


Tyler Roscoe wrote:
> On Fri, Dec 19, 2008 at 01:33:45AM +0800, Kermit Mei wrote:
>   
>> c++ -Wall -gstabs(or -g)  main.cpp hello.cpp -o main
>>
>> How can I use cmake to do the same thing?
>>     
>
> Add your -g flag to CMAKE_CXX_FLAGS or I think you can use
> ADD_DEFINITIONS("-g").
>
> tyler
>   
Thank you, tyler;p



More information about the CMake mailing list