diff options
author | Christian Fetzer <fetzer.ch@gmail.com> | 2016-05-21 12:28:06 +0200 |
---|---|---|
committer | Christian Fetzer <fetzer.ch@gmail.com> | 2016-06-01 18:57:52 +0200 |
commit | ee443bb43f0e256a27898e7ccbcc3b782c73c1f0 (patch) | |
tree | 56bbb14c54088db22448e324ec6e6e7376d742b4 /project/cmake/scripts/common/AddonHelpers.cmake | |
parent | 29e2b13cada09c90c0b8bb7de3512abc19e2e774 (diff) |
[cmake] Make CMake aware of textfiles that configure the build
The CMake based buildsystem is based on reading the input of textfiles
at configure-time. As CMake does not track files that are just accessed
using "file(READ)" building does not automatically retrigger a
reconfiguration when those files are changes. This commit fixes it by
either using configure_file or using the CMAKE_CONFIGURE_DEPENDS
variable.
This should remove the necessity to manually rerun CMake when files are
changed during development. (Due to globbing CMake still has to be
rerun when files are added or removed!)
Diffstat (limited to 'project/cmake/scripts/common/AddonHelpers.cmake')
-rw-r--r-- | project/cmake/scripts/common/AddonHelpers.cmake | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/project/cmake/scripts/common/AddonHelpers.cmake b/project/cmake/scripts/common/AddonHelpers.cmake index 1941da5ddc..a5c9de32c7 100644 --- a/project/cmake/scripts/common/AddonHelpers.cmake +++ b/project/cmake/scripts/common/AddonHelpers.cmake @@ -67,6 +67,7 @@ macro (build_addon target prefix libs) # if there's an addon.xml.in we need to generate the addon.xml if(EXISTS ${PROJECT_SOURCE_DIR}/${target}/addon.xml.in) + set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS ${PROJECT_SOURCE_DIR}/${target}/addon.xml.in) set(PLATFORM ${CORE_SYSTEM_NAME}) file(READ ${PROJECT_SOURCE_DIR}/${target}/addon.xml.in addon_file) |