diff options
author | Alex Merry <alex.merry@kde.org> | 2014-04-20 15:26:54 +0100 |
---|---|---|
committer | Alex Merry <alex.merry@kde.org> | 2014-04-25 10:43:45 +0100 |
commit | bef4cdd905980b2c8a45a50e2201678c1e4e38af (patch) | |
tree | 2463e7978a73f35cde707206863aefef2a359cfd /modules | |
parent | 035c6fa9390ecb66422ee684be71eea692989009 (diff) | |
download | extra-cmake-modules-bef4cdd905980b2c8a45a50e2201678c1e4e38af.tar.gz extra-cmake-modules-bef4cdd905980b2c8a45a50e2201678c1e4e38af.tar.bz2 |
Add a stub for ECMFindModuleHelpers to the find-modules dir
ECMUseFindModules allows find modules to be copied to a local directory.
These find modules may use ECMFindModuleHelpers, but they will not be in
the same relative location to ECMFindModuleHelpers.cmake and there is no
guarantee that ECMFindModulesHelpers.cmake will be in the CMake module
path.
To solve this, we make sure there is always a stub file in the same
directory as the find modules that includes the real
ECMFindModuleHelpers.cmake. The one installed with ECM just includes
"../modules/ECMFindModuleHelpers.cmake", while ecm_use_find_modules
generates a stub that uses an absolute path.
REVIEW 117658
Diffstat (limited to 'modules')
-rw-r--r-- | modules/ECMUseFindModules.cmake | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/ECMUseFindModules.cmake b/modules/ECMUseFindModules.cmake index 25f42666..a48f599b 100644 --- a/modules/ECMUseFindModules.cmake +++ b/modules/ECMUseFindModules.cmake @@ -82,5 +82,8 @@ function(ecm_use_find_modules) configure_file("${ECM_FIND_MODULE_DIR}/${file}" "${EUFM_DIR}/${file}" COPYONLY) endif() endforeach() + # This is required by some of the find modules + file(WRITE "${EUFM_DIR}/ECMFindModuleHelpersStub.cmake" + "include(\"${ECM_MODULE_DIR}/ECMFindModuleHelpers.cmake\")") endfunction() |