diff options
author | Christian Fetzer <fetzer.ch@gmail.com> | 2016-10-03 13:31:00 +0200 |
---|---|---|
committer | Christian Fetzer <fetzer.ch@gmail.com> | 2016-10-03 14:07:10 +0200 |
commit | f52c43bf228a65f633713d78aabdce20b8bd8602 (patch) | |
tree | 88696c1b78014c7384f9499917c975f56c7a47af | |
parent | b8eceaf998e049e229aeb03de6b2b0032535ba60 (diff) |
[cmake] Fix always outdated targets (with autotools remnants)
When the source directory has build artefacts from a previous autotools
build, cmake always ran the pack-skin target or build addon libraries.
AutotoolsRemoval: Should be revisited when autotools has been removed.
-rw-r--r-- | project/cmake/scripts/common/Macros.cmake | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/project/cmake/scripts/common/Macros.cmake b/project/cmake/scripts/common/Macros.cmake index 4f0ae67c44..b30dfab56e 100644 --- a/project/cmake/scripts/common/Macros.cmake +++ b/project/cmake/scripts/common/Macros.cmake @@ -211,6 +211,14 @@ function(copy_file_to_buildtree file) file(APPEND ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/ExportFiles.cmake "# Export files to build tree\n") endif() + # Exclude autotools build artefacts and other blacklisted files in source tree. + if(file MATCHES "(Makefile|\.in|\.xbt|\.so|\.dylib|\.gitignore)$") + if(VERBOSE) + message(STATUS "copy_file_to_buildtree - ignoring file: ${file}") + endif() + return() + endif() + if(NOT file STREQUAL ${CMAKE_BINARY_DIR}/${outfile}) if(VERBOSE) message(STATUS "copy_file_to_buildtree - copying file: ${file} -> ${CMAKE_BINARY_DIR}/${outfile}") |