mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-08 15:20:45 +01:00
cmake: Use new option in check_and_add_flag to add options correctly
Previously, -ggdb wouldn't be added when using the Xcode generator. And now, the code for -fomit-frame-pointer is much more simple.
This commit is contained in:
parent
00c15d84d6
commit
f5fd5477e3
@ -225,10 +225,8 @@ else()
|
||||
check_and_add_flag(VISIBILITY_INLINES_HIDDEN -fvisibility-inlines-hidden)
|
||||
check_and_add_flag(VISIBILITY_HIDDEN -fvisibility=hidden)
|
||||
|
||||
check_c_compiler_flag(-fomit-frame-pointer FLAG_C_FOMIT_FRAME_POINTER)
|
||||
if(FLAG_C_FOMIT_FRAME_POINTER)
|
||||
add_compile_options($<$<CONFIG:Release>:-fomit-frame-pointer>)
|
||||
endif()
|
||||
check_and_add_flag(FOMIT_FRAME_POINTER -fomit-frame-pointer RELEASE_ONLY)
|
||||
check_and_add_flag(GGDB -ggdb DEBUG_ONLY)
|
||||
|
||||
if(NOT ANDROID AND _M_X86_64)
|
||||
# PIE is required on Android, but not supported with the x86_64 jit currently
|
||||
@ -337,7 +335,6 @@ endif()
|
||||
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||
add_definitions(-D_DEBUG)
|
||||
check_and_add_flag(GGDB -ggdb)
|
||||
|
||||
option(ENABLE_GPROF "Enable gprof profiling (must be using Debug build)" OFF)
|
||||
if(ENABLE_GPROF)
|
||||
|
Loading…
Reference in New Issue
Block a user