diff options
author | Marc Chevrier <marc.chevrier@gmail.com> | 2020-10-18 14:11:27 (GMT) |
---|---|---|
committer | Marc Chevrier <marc.chevrier@gmail.com> | 2020-11-29 14:25:42 (GMT) |
commit | 2c71d051facad13b0a42a57066be2489d5fff6ea (patch) | |
tree | d07f850f8abc74d9df34ad885681c08d36c14472 /Tests/RunCMake/Make | |
parent | afd0f6785dc1220a07743d31699fcd9097cca46a (diff) | |
download | CMake-2c71d051facad13b0a42a57066be2489d5fff6ea.zip CMake-2c71d051facad13b0a42a57066be2489d5fff6ea.tar.gz CMake-2c71d051facad13b0a42a57066be2489d5fff6ea.tar.bz2 |
Makefiles Generators: use compiler for dependencies generation
Each source compilation generates a dependencies file. These dependencies
files are consolidated in one file per target. This consolidation is done
as part of command 'cmake -E cmake_depends` launched before evaluation of
makefile dependency graph.
The consolidation uses the same approach as `CMake` dependencies management.
Fixes: #21321
Diffstat (limited to 'Tests/RunCMake/Make')
9 files changed, 26 insertions, 26 deletions
diff --git a/Tests/RunCMake/Make/TargetMessages-OFF-build-check.cmake b/Tests/RunCMake/Make/TargetMessages-OFF-build-check.cmake new file mode 100644 index 0000000..74a0564 --- /dev/null +++ b/Tests/RunCMake/Make/TargetMessages-OFF-build-check.cmake @@ -0,0 +1,3 @@ + +set (CHECK_TARGET_MESSAGES OFF) +include ("${CMAKE_CURRENT_LIST_DIR}/TargetMessages-validation.cmake") diff --git a/Tests/RunCMake/Make/TargetMessages-OFF-build-stdout.txt b/Tests/RunCMake/Make/TargetMessages-OFF-build-stdout.txt index 77a582a..8d98f9d 100644 --- a/Tests/RunCMake/Make/TargetMessages-OFF-build-stdout.txt +++ b/Tests/RunCMake/Make/TargetMessages-OFF-build-stdout.txt @@ -1,5 +1 @@ -^(([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]* -)*Scanning dependencies of target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)*$ +.* diff --git a/Tests/RunCMake/Make/TargetMessages-ON-build-check.cmake b/Tests/RunCMake/Make/TargetMessages-ON-build-check.cmake new file mode 100644 index 0000000..afd8efb --- /dev/null +++ b/Tests/RunCMake/Make/TargetMessages-ON-build-check.cmake @@ -0,0 +1,3 @@ + +set (CHECK_TARGET_MESSAGES ON) +include ("${CMAKE_CURRENT_LIST_DIR}/TargetMessages-validation.cmake") diff --git a/Tests/RunCMake/Make/TargetMessages-ON-build-stdout.txt b/Tests/RunCMake/Make/TargetMessages-ON-build-stdout.txt index a827624..8d98f9d 100644 --- a/Tests/RunCMake/Make/TargetMessages-ON-build-stdout.txt +++ b/Tests/RunCMake/Make/TargetMessages-ON-build-stdout.txt @@ -1,8 +1 @@ -^(([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]* -)*Scanning dependencies of target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)* -Built target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)*$ +.* diff --git a/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-check.cmake b/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-check.cmake new file mode 100644 index 0000000..74a0564 --- /dev/null +++ b/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-check.cmake @@ -0,0 +1,3 @@ + +set (CHECK_TARGET_MESSAGES OFF) +include ("${CMAKE_CURRENT_LIST_DIR}/TargetMessages-validation.cmake") diff --git a/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-stdout.txt b/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-stdout.txt index 77a582a..8d98f9d 100644 --- a/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-stdout.txt +++ b/Tests/RunCMake/Make/TargetMessages-VAR-OFF-build-stdout.txt @@ -1,5 +1 @@ -^(([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]* -)*Scanning dependencies of target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)*$ +.* diff --git a/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-check.cmake b/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-check.cmake new file mode 100644 index 0000000..afd8efb --- /dev/null +++ b/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-check.cmake @@ -0,0 +1,3 @@ + +set (CHECK_TARGET_MESSAGES ON) +include ("${CMAKE_CURRENT_LIST_DIR}/TargetMessages-validation.cmake") diff --git a/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-stdout.txt b/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-stdout.txt index a827624..8d98f9d 100644 --- a/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-stdout.txt +++ b/Tests/RunCMake/Make/TargetMessages-VAR-ON-build-stdout.txt @@ -1,8 +1 @@ -^(([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]* -)*Scanning dependencies of target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)* -Built target CustomTarget( -([^B]|B[^u]|Bu[^i]|Bui[^l]|Buil[^t]|Built[^ ])[^ -]*)*$ +.* diff --git a/Tests/RunCMake/Make/TargetMessages-validation.cmake b/Tests/RunCMake/Make/TargetMessages-validation.cmake new file mode 100644 index 0000000..f3d7af1 --- /dev/null +++ b/Tests/RunCMake/Make/TargetMessages-validation.cmake @@ -0,0 +1,10 @@ + +if (CHECK_TARGET_MESSAGES) + if (NOT actual_stdout MATCHES "Built target CustomTarget") + set (RunCMake_TEST_FAILED "Not found expected 'Built target' message.") + endif() +else() + if (actual_stdout MATCHES "Built target CustomTarget") + set (RunCMake_TEST_FAILED "Found unexpected 'Built target' message.") + endif() +endif() |