I want to use gprof to analyze my code. So I try to embed the -pg paramter for g++ in my CMakeLists.txt file.
But after I embeded the -pg to my CMakeLists.txt like this: --------- add_definitions(-pg -march=pentium4 -msse3 -g) --------- and I recompile my code. There is no gprof output file. But when I use command like: -------- $ g++ -pg .... -------- to compile my code, gprof will generate a output file gmon.out. So, how can I enable gprof profiler in my CMakeLists.txt? Thanks Water Lin -- Water Lin's notes and pencils: http://en.waterlin.org Email: water...@ymail.com __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake