CMake: Implement configure -gdb-index
Change-Id: Iea0fb99297751b1baf830a416ea5041d0b9a3b63 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
parent
4306fc019a
commit
721812c5d2
@ -221,6 +221,10 @@ elseif(QT_FEATURE_use_lld_linker)
|
||||
target_link_options(PlatformCommonInternal INTERFACE "-fuse-ld=lld")
|
||||
endif()
|
||||
|
||||
if(QT_FEATURE_enable_gdb_index)
|
||||
target_link_options(PlatformCommonInternal INTERFACE "-Wl,--gdb-index")
|
||||
endif()
|
||||
|
||||
function(qt_get_implicit_sse2_genex_condition out_var)
|
||||
set(is_shared_lib "$<STREQUAL:$<TARGET_PROPERTY:TYPE>,SHARED_LIBRARY>")
|
||||
set(is_static_lib "$<STREQUAL:$<TARGET_PROPERTY:TYPE>,STATIC_LIBRARY>")
|
||||
|
@ -32,7 +32,7 @@ The effort of this is tracked in QTBUG-85373 and QTBUG-85349.
|
||||
| -optimized-tools | n/a | This affects only host tools. |
|
||||
| -force-debug-info | Use the RelWithDebInfo build config. | |
|
||||
| -separate-debug-info | -DFEATURE_separate_debug_info=ON | |
|
||||
| -gdb-index | | |
|
||||
| -gdb-index | -DFEATURE_enable_gdb_index=ON | |
|
||||
| -strip | | |
|
||||
| -gc-binaries | -DFEATURE_gc_binaries=ON | |
|
||||
| -force-asserts | | |
|
||||
|
@ -622,6 +622,12 @@ qt_feature("ltcg"
|
||||
CONDITION CMAKE_INTERPROCEDURAL_OPTIMIZATION
|
||||
)
|
||||
qt_feature_config("ltcg" QMAKE_PRIVATE_CONFIG)
|
||||
qt_feature("enable_gdb_index"
|
||||
LABEL "Generating GDB index"
|
||||
AUTODETECT QT_FEATURE_developer_build
|
||||
CONDITION GCC AND NOT CLANG AND ( QT_FEATURE_debug OR QT_FEATURE_force_debug_info OR QT_FEATURE_debug_and_release ) AND TEST_gdb_index
|
||||
)
|
||||
qt_feature_config("enable_gdb_index" QMAKE_PRIVATE_CONFIG)
|
||||
qt_feature("reduce_exports" PRIVATE
|
||||
LABEL "Reduce amount of exported symbols"
|
||||
CONDITION NOT WIN32 AND CMAKE_CXX_COMPILE_OPTIONS_VISIBILITY
|
||||
|
@ -897,7 +897,6 @@ def get_feature_mapping():
|
||||
"condition": "CMAKE_BUILD_TYPE STREQUAL Debug OR Debug IN_LIST CMAKE_CONFIGURATION_TYPES"
|
||||
},
|
||||
"dlopen": {"condition": "UNIX"},
|
||||
"enable_gdb_index": None,
|
||||
"enable_new_dtags": None,
|
||||
"force_debug_info": {
|
||||
"autoDetect": "CMAKE_BUILD_TYPE STREQUAL RelWithDebInfo OR RelWithDebInfo IN_LIST CMAKE_CONFIGURATION_TYPES"
|
||||
|
Loading…
x
Reference in New Issue
Block a user