diff options
author | Joerg Bornemann <joerg.bornemann@qt.io> | 2020-04-15 06:48:44 +0200 |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@qt.io> | 2020-04-17 23:10:08 +0200 |
commit | 34124a4b0b967ec79b207eae5f3cabbd0690ef69 (patch) | |
tree | f6949e60b92b2e6f0dd0eb25c99a836c680b1a80 /cmake/QtSeparateDebugInfo.cmake | |
parent | eb3b37de83c19b35197fbd5d288f32cc8b93bccf (diff) | |
download | qtbase-34124a4b0b967ec79b207eae5f3cabbd0690ef69.tar.gz |
CMake: Make use of CMAKE_CURRENT_FUNCTION_LIST_DIR
Once we can require CMake 3.17 everywhere, we can remove the variable
set up from QtSeparateDebugInfo.cmake.
Change-Id: I91572583654054f5fa47ac1e41be23050a5a8c0b
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'cmake/QtSeparateDebugInfo.cmake')
-rw-r--r-- | cmake/QtSeparateDebugInfo.cmake | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/cmake/QtSeparateDebugInfo.cmake b/cmake/QtSeparateDebugInfo.cmake index 5e71775431..d2c976f164 100644 --- a/cmake/QtSeparateDebugInfo.cmake +++ b/cmake/QtSeparateDebugInfo.cmake @@ -1,6 +1,8 @@ include(CMakeFindBinUtils) -set(QtSeparateDebugInfo_cmake_DIR ${CMAKE_CURRENT_LIST_DIR}) +if(CMAKE_VERSION VERSION_LESS 3.17.0) +set(CMAKE_CURRENT_FUNCTION_LIST_DIR ${CMAKE_CURRENT_LIST_DIR}) +endif() # Enable separate debug information for the given target function(qt_enable_separate_debug_info target installDestination) @@ -37,7 +39,7 @@ function(qt_enable_separate_debug_info target installDestination) set(debug_info_contents_dir "${debug_info_bundle_dir}/Contents") set(debug_info_target_dir "${debug_info_contents_dir}/Resources/DWARF") configure_file( - "${QtSeparateDebugInfo_cmake_DIR}/QtSeparateDebugInfo.Info.plist.in" + "${CMAKE_CURRENT_FUNCTION_LIST_DIR}/QtSeparateDebugInfo.Info.plist.in" "Info.dSYM.plist" ) list(APPEND commands |