@@ -36,9 +36,10 @@ if(PROJ_COMPILER_FRONTEND STREQUAL "MSVC")
3636 target_compile_options (rt_common_settings INTERFACE -Wno-duplicated-branches )
3737 endif ()
3838elseif (PROJ_COMPILER_FRONTEND STREQUAL "GNU" )
39- target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Debug >:-O0 >" )
40- target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Release >:-O2 >" )
41- target_compile_options (rt_common_settings INTERFACE -ggdb -x c++ -mavx2 -mbmi2 -fpermissive -pthread )
39+ target_compile_options (rt_common_settings INTERFACE -x c++ -gdwarf-4 ) # dwarf-4 (for gdb8); must come before -g1
40+ target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Debug >:-O0 ;-g >" )
41+ target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Release >:-O2 ;-g1 >" )
42+ target_compile_options (rt_common_settings INTERFACE -mavx2 -mbmi2 -fpermissive -pthread )
4243 target_compile_options (rt_common_settings INTERFACE -falign-functions=32 -fno-strict-aliasing )
4344 target_compile_options (rt_common_settings INTERFACE -Wall -Werror )
4445 target_compile_options (rt_common_settings INTERFACE -Wno-error=cast-qual )
@@ -59,9 +60,9 @@ elseif(PROJ_COMPILER_FRONTEND STREQUAL "GNU")
5960 target_compile_options (rt_common_settings INTERFACE -Wno-useless-cast )
6061 target_compile_options (rt_common_settings INTERFACE -Wno-old-style-cast )
6162elseif (PROJ_COMPILER_FRONTEND STREQUAL "LLVM" )
62- target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Debug >:-O0 >" )
63- target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Release >:-O2 >" )
64- target_compile_options (rt_common_settings INTERFACE -ggdb - x c++ -mavx2 -mbmi2 -fpermissive -pthread )
63+ target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Debug >:-O0 ;- g >" )
64+ target_compile_options (rt_common_settings INTERFACE "$<$<CONFIG :Release >:-O2 ;- g1 >" )
65+ target_compile_options (rt_common_settings INTERFACE -x c++ -mavx2 -mbmi2 -fpermissive -pthread )
6566 target_compile_options (rt_common_settings INTERFACE -falign-functions=32 -fno-strict-aliasing )
6667 target_compile_options (rt_common_settings INTERFACE -Wall -Werror )
6768 target_compile_options (rt_common_settings INTERFACE -Wno-format ) # TODO: Remove this and fix all the printf format mismatches
0 commit comments