From f9677cc1223fb23f6e6c329e9f7de954639554d1 Mon Sep 17 00:00:00 2001 From: Brad King Date: Tue, 23 May 2023 14:27:08 -0400 Subject: Tests: Improve RunCMake.CXXModules expectation matching and error reporting --- .../export-bmi-and-interface-build-stderr.txt | 2 +- .../test/CMakeLists.txt | 20 +++++++++++++++----- .../export-bmi-and-interface-install-stderr.txt | 2 +- .../test/CMakeLists.txt | 20 +++++++++++++++----- .../examples/export-interface-build-stderr.txt | 2 +- .../export-interface-build/test/CMakeLists.txt | 20 +++++++++++++++----- .../examples/export-interface-install-stderr.txt | 2 +- .../export-interface-install/test/CMakeLists.txt | 20 +++++++++++++++----- .../export-interface-no-properties-build-stderr.txt | 2 +- .../test/CMakeLists.txt | 9 ++++++--- ...export-interface-no-properties-install-stderr.txt | 2 +- .../test/CMakeLists.txt | 9 ++++++--- 12 files changed, 78 insertions(+), 32 deletions(-) diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build-stderr.txt index 5e4392a..c8dbdcf 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9]+ \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt index 2e37da2..a0cf4d9 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt @@ -14,19 +14,29 @@ get_property(file_sets TARGET CXXModules::export_bmi_and_interfaces PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_bmi_and_interfaces`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_bmi_and_interfaces:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_bmi_and_interfaces PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_source_dir}/importable.cxx") +set(expected_file_set_files + "${expected_source_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_bmi_and_interfaces`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_bmi_and_interfaces:\n ${file_set_files}") endif () get_property(imported_modules TARGET CXXModules::export_bmi_and_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) -if (NOT imported_modules MATCHES "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_bmi_and_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)") +set(expected_imported_modules + "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_bmi_and_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)" + ) +if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR - "Incorrect exported modules in CXXModules::export_bmi_and_interfaces`: `${imported_modules}`") + "Incorrect exported modules in CXXModules::export_bmi_and_interfaces:\n" + " ${imported_modules}\n" + "does not match:\n" + " ${expected_imported_modules}" + ) endif () diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install-stderr.txt index 5e4392a..c8dbdcf 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9]+ \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt index 1adccb3..98f6e52 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt @@ -14,19 +14,29 @@ get_property(file_sets TARGET CXXModules::export_bmi_and_interfaces PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_bmi_and_interfaces`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_bmi_and_interfaces:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_bmi_and_interfaces PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_source_dir}/importable.cxx") +set(expected_file_set_files + "${expected_source_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_bmi_and_interfaces`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_bmi_and_interfaces:\n ${file_set_files}") endif () get_property(imported_modules TARGET CXXModules::export_bmi_and_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) -if (NOT imported_modules MATCHES "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/importable.(gcm|pcm|ifc)") +set(expected_imported_modules + "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/importable.(gcm|pcm|ifc)" + ) +if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR - "Incorrect exported modules in CXXModules::export_bmi_and_interfaces`: `${imported_modules}`") + "Incorrect exported modules in CXXModules::export_bmi_and_interfaces:\n" + " ${imported_modules}\n" + "does not match:\n" + " ${expected_imported_modules}" + ) endif () diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-interface-build-stderr.txt index 5e4392a..e318a34 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-build-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9] \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt index 9949969..6005676 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt @@ -14,19 +14,29 @@ get_property(file_sets TARGET CXXModules::export_interfaces PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_interfaces`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_interfaces:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_interfaces PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_source_dir}/importable.cxx") +set(expected_file_set_files + "${expected_source_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_interfaces`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_interfaces:\n ${file_set_files}") endif () get_property(imported_modules TARGET CXXModules::export_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) -if (NOT imported_modules MATCHES "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)") +set(expected_imported_modules + "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)" + ) +if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR - "Incorrect exported modules in CXXModules::export_interfaces`: `${imported_modules}`\n`importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)`") + "Incorrect exported modules in CXXModules::export_interfaces:\n" + " ${imported_modules}\n" + "does not match:\n" + " ${expected_imported_modules}" + ) endif () diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-interface-install-stderr.txt index 5e4392a..c8dbdcf 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-install-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9]+ \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt index 7079256..6ea2831 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt @@ -14,19 +14,29 @@ get_property(file_sets TARGET CXXModules::export_interfaces PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_interfaces`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_interfaces:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_interfaces PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_source_dir}/importable.cxx") +set(expected_file_set_files + "${expected_source_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_interfaces`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_interfaces:\n ${file_set_files}") endif () get_property(imported_modules TARGET CXXModules::export_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) -if (NOT imported_modules STREQUAL "importable=${expected_source_dir}/importable.cxx") +set(expected_imported_modules + "importable=${expected_source_dir}/importable.cxx" + ) +if (NOT imported_modules STREQUAL "${expected_imported_modules}") message(FATAL_ERROR - "Incorrect exported modules in CXXModules::export_interfaces`: `${imported_modules}`") + "Incorrect exported modules in CXXModules::export_interfaces:\n" + " ${imported_modules}\n" + "does not match:\n" + " ${expected_imported_modules}" + ) endif () diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build-stderr.txt index 5e4392a..c8dbdcf 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9]+ \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt index 9cdc80a..9ff88df 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt @@ -14,14 +14,17 @@ get_property(file_sets TARGET CXXModules::export_interfaces_no_properties PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_interfaces_no_properties`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_interfaces_no_properties:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_interfaces_no_properties PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_dir}/importable.cxx") +set(expected_file_set_files + "${expected_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_interfaces_no_properties`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_interfaces_no_properties:\n ${file_set_files}") endif () get_property(imported_modules_set TARGET CXXModules::export_interfaces_no_properties diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install-stderr.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install-stderr.txt index 5e4392a..c8dbdcf 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install-stderr.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install-stderr.txt @@ -1,4 +1,4 @@ -CMake Warning \(dev\) at CMakeLists.txt:7 \(target_sources\): +CMake Warning \(dev\) at CMakeLists.txt:[0-9]+ \(target_sources\): CMake's C\+\+ module support is experimental. It is meant only for experimentation and feedback to CMake developers. This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt index 9cdc80a..9ff88df 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt @@ -14,14 +14,17 @@ get_property(file_sets TARGET CXXModules::export_interfaces_no_properties PROPERTY INTERFACE_CXX_MODULE_SETS) if (NOT file_sets STREQUAL "modules") message(FATAL_ERROR - "Incorrect exported file sets in `CXXModules::export_interfaces_no_properties`: `${file_sets}`") + "Incorrect exported file sets in CXXModules::export_interfaces_no_properties:\n ${file_sets}") endif () get_property(file_set_files TARGET CXXModules::export_interfaces_no_properties PROPERTY CXX_MODULE_SET_modules) -if (NOT file_set_files STREQUAL "${expected_dir}/importable.cxx") +set(expected_file_set_files + "${expected_dir}/importable.cxx" + ) +if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR - "Incorrect exported file set paths in CXXModules::export_interfaces_no_properties`: `${file_set_files}`") + "Incorrect exported file set paths in CXXModules::export_interfaces_no_properties:\n ${file_set_files}") endif () get_property(imported_modules_set TARGET CXXModules::export_interfaces_no_properties -- cgit v0.12 From f2a699261b9d3d494bc791caad2d8f1fb21d6b4b Mon Sep 17 00:00:00 2001 From: Tyler Date: Fri, 12 May 2023 18:58:35 -0600 Subject: cxxmodules: Do not expect collator install scripts with no CXX_MODULES Calling `install(EXPORT)` with the `CXX_MODULES_DIRECTORY` parameter leads to installation rules being generated which `include()` CMake scripts that set the `IMPORTED_CXX_MODULES_[CONFIG]` target property for relevant targets. However, these scripts don't get generated for targets in an export set which don't have any C++20 modules. When the installation rules attempt to `include()` the missing scripts, the install fails. Co-authored-by: Brad King --- Source/cmExportBuildFileGenerator.cxx | 6 ++++++ Source/cmExportInstallFileGenerator.cxx | 6 ++++++ .../examples/export-bmi-and-interface-build/CMakeLists.txt | 4 +++- .../examples/export-bmi-and-interface-build/no_modules.cxx | 3 +++ .../examples/export-bmi-and-interface-install/CMakeLists.txt | 4 +++- .../examples/export-bmi-and-interface-install/no_modules.cxx | 3 +++ .../CXXModules/examples/export-interface-build/CMakeLists.txt | 4 +++- .../CXXModules/examples/export-interface-build/no_modules.cxx | 3 +++ .../CXXModules/examples/export-interface-install/CMakeLists.txt | 4 +++- .../CXXModules/examples/export-interface-install/no_modules.cxx | 3 +++ .../examples/export-interface-no-properties-build/CMakeLists.txt | 4 +++- .../examples/export-interface-no-properties-build/no_modules.cxx | 3 +++ .../examples/export-interface-no-properties-install/CMakeLists.txt | 4 +++- .../examples/export-interface-no-properties-install/no_modules.cxx | 3 +++ 14 files changed, 48 insertions(+), 6 deletions(-) create mode 100644 Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/no_modules.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/no_modules.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-build/no_modules.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-install/no_modules.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/no_modules.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/no_modules.cxx diff --git a/Source/cmExportBuildFileGenerator.cxx b/Source/cmExportBuildFileGenerator.cxx index 437ae69..a3637d8 100644 --- a/Source/cmExportBuildFileGenerator.cxx +++ b/Source/cmExportBuildFileGenerator.cxx @@ -542,6 +542,12 @@ bool cmExportBuildFileGenerator::GenerateImportCxxModuleConfigTargetInclusion( os.SetCopyIfDifferent(true); for (auto const* tgt : this->ExportedTargets) { + // Only targets with C++ module sources will have a + // collator-generated install script. + if (!tgt->HaveCxx20ModuleSources()) { + continue; + } + os << "include(\"${CMAKE_CURRENT_LIST_DIR}/target-" << tgt->GetExportName() << '-' << config << ".cmake\")\n"; } diff --git a/Source/cmExportInstallFileGenerator.cxx b/Source/cmExportInstallFileGenerator.cxx index 51c91f3..df119ae 100644 --- a/Source/cmExportInstallFileGenerator.cxx +++ b/Source/cmExportInstallFileGenerator.cxx @@ -752,6 +752,12 @@ bool cmExportInstallFileGenerator:: auto& prop_files = this->ConfigCxxModuleTargetFiles[config]; for (auto const* tgt : this->ExportedTargets) { + // Only targets with C++ module sources will have a + // collator-generated install script. + if (!tgt->HaveCxx20ModuleSources()) { + continue; + } + auto prop_filename = cmStrCat("target-", tgt->GetExportName(), '-', filename_config, ".cmake"); prop_files.emplace_back(cmStrCat(dest, prop_filename)); diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt index a450b7e..62971a3 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_bmi_and_interfaces importable.cxx) target_compile_features(export_bmi_and_interfaces PUBLIC cxx_std_20) -install(TARGETS export_bmi_and_interfaces +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_bmi_and_interfaces no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu" CXX_MODULES_BMI DESTINATION "lib/cxx/bmi") diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt index a5574fe..bc19d93 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_bmi_and_interfaces importable.cxx) target_compile_features(export_bmi_and_interfaces PUBLIC cxx_std_20) -install(TARGETS export_bmi_and_interfaces +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_bmi_and_interfaces no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu" CXX_MODULES_BMI DESTINATION "lib/cxx/bmi") diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt index 8584dce..62352ff 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_interfaces importable.cxx) target_compile_features(export_interfaces PUBLIC cxx_std_20) -install(TARGETS export_interfaces +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_interfaces no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu") export(EXPORT CXXModules diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-build/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt index b5c6224..15c91d9 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_interfaces importable.cxx) target_compile_features(export_interfaces PUBLIC cxx_std_20) -install(TARGETS export_interfaces +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_interfaces no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu") install(EXPORT CXXModules diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-install/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt index 7633bec..7d04c50 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_interfaces_no_properties importable.cxx) target_compile_features(export_interfaces_no_properties PUBLIC cxx_std_20) -install(TARGETS export_interfaces_no_properties +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_interfaces_no_properties no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu") export(EXPORT CXXModules diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt index 75f2440..c0db766 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt @@ -21,7 +21,9 @@ target_sources(export_interfaces_no_properties importable.cxx) target_compile_features(export_interfaces_no_properties PUBLIC cxx_std_20) -install(TARGETS export_interfaces_no_properties +add_library(no_modules STATIC no_modules.cxx) + +install(TARGETS export_interfaces_no_properties no_modules EXPORT CXXModules FILE_SET modules DESTINATION "lib/cxx/miu") install(EXPORT CXXModules diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/no_modules.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/no_modules.cxx new file mode 100644 index 0000000..eea854f --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/no_modules.cxx @@ -0,0 +1,3 @@ +void no_modules() +{ +} -- cgit v0.12 From 28ece63fee1d5b4cd37f79ea5c7f078509f44bcd Mon Sep 17 00:00:00 2001 From: Tyler Date: Fri, 12 May 2023 18:58:35 -0600 Subject: cxxmodules: Fix exported path to installed module sources in subdirs When generating the `IMPORTED_CXX_MODULES_[CONFIG]` target property, there was a missing path separator after a non-empty relative directory part of the path to a module source file. Co-authored-by: Brad King --- Source/cmDyndepCollation.cxx | 4 ++++ .../examples/export-bmi-and-interface-build/CMakeLists.txt | 4 +++- .../examples/export-bmi-and-interface-build/subdir/importable.cxx | 6 ++++++ .../examples/export-bmi-and-interface-build/test/CMakeLists.txt | 2 ++ .../examples/export-bmi-and-interface-install/CMakeLists.txt | 4 +++- .../examples/export-bmi-and-interface-install/subdir/importable.cxx | 6 ++++++ .../examples/export-bmi-and-interface-install/test/CMakeLists.txt | 2 ++ .../CXXModules/examples/export-interface-build/CMakeLists.txt | 4 +++- .../examples/export-interface-build/subdir/importable.cxx | 6 ++++++ .../CXXModules/examples/export-interface-build/test/CMakeLists.txt | 2 ++ .../CXXModules/examples/export-interface-install/CMakeLists.txt | 4 +++- .../examples/export-interface-install/subdir/importable.cxx | 6 ++++++ .../examples/export-interface-install/test/CMakeLists.txt | 2 ++ .../examples/export-interface-no-properties-build/CMakeLists.txt | 4 +++- .../export-interface-no-properties-build/subdir/importable.cxx | 6 ++++++ .../export-interface-no-properties-build/test/CMakeLists.txt | 1 + .../examples/export-interface-no-properties-install/CMakeLists.txt | 4 +++- .../export-interface-no-properties-install/subdir/importable.cxx | 6 ++++++ .../export-interface-no-properties-install/test/CMakeLists.txt | 1 + 19 files changed, 68 insertions(+), 6 deletions(-) create mode 100644 Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/subdir/importable.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/subdir/importable.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-build/subdir/importable.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-install/subdir/importable.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/subdir/importable.cxx create mode 100644 Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/subdir/importable.cxx diff --git a/Source/cmDyndepCollation.cxx b/Source/cmDyndepCollation.cxx index f45d81b..80e1357 100644 --- a/Source/cmDyndepCollation.cxx +++ b/Source/cmDyndepCollation.cxx @@ -358,6 +358,10 @@ cmDyndepCollation::ParseExportInfo(Json::Value const& tdi) fsi.Name = tdi_cxx_module_info["name"].asString(); fsi.RelativeDirectory = tdi_cxx_module_info["relative-directory"].asString(); + if (!fsi.RelativeDirectory.empty() && + fsi.RelativeDirectory.back() != '/') { + fsi.RelativeDirectory = cmStrCat(fsi.RelativeDirectory, '/'); + } fsi.SourcePath = tdi_cxx_module_info["source"].asString(); fsi.Type = tdi_cxx_module_info["type"].asString(); fsi.Visibility = cmFileSetVisibilityFromName( diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt index 62971a3..71e7b62 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_bmi_and_interfaces BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_bmi_and_interfaces PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt index a0cf4d9..3cb185c 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-build/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_bmi_and_interfaces PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_source_dir}/importable.cxx" + "${expected_source_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR @@ -31,6 +32,7 @@ get_property(imported_modules TARGET CXXModules::export_bmi_and_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) set(expected_imported_modules "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_bmi_and_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)" + "subdir_importable=${expected_source_dir}/subdir/importable.cxx,${expected_binary_dir}/CMakeFiles/export_bmi_and_interfaces.dir(/Debug)?/subdir_importable.(gcm|pcm|ifc)" ) if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt index bc19d93..e675507 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_bmi_and_interfaces BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_bmi_and_interfaces PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt index 98f6e52..7b36f8c 100644 --- a/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-bmi-and-interface-install/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_bmi_and_interfaces PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_source_dir}/importable.cxx" + "${expected_source_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR @@ -31,6 +32,7 @@ get_property(imported_modules TARGET CXXModules::export_bmi_and_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) set(expected_imported_modules "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/importable.(gcm|pcm|ifc)" + "subdir_importable=${expected_source_dir}/subdir/importable.cxx,${expected_binary_dir}/subdir_importable.(gcm|pcm|ifc)" ) if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt index 62352ff..136e885 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_interfaces BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_interfaces PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-build/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt index 6005676..1874c97 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-build/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_interfaces PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_source_dir}/importable.cxx" + "${expected_source_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR @@ -31,6 +32,7 @@ get_property(imported_modules TARGET CXXModules::export_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) set(expected_imported_modules "importable=${expected_source_dir}/importable.cxx,${expected_binary_dir}/CMakeFiles/export_interfaces.dir(/Debug)?/importable.(gcm|pcm|ifc)" + "subdir_importable=${expected_source_dir}/subdir/importable.cxx,${expected_binary_dir}/CMakeFiles/export_interfaces.dir(/Debug)?/subdir_importable.(gcm|pcm|ifc)" ) if (NOT imported_modules MATCHES "^${expected_imported_modules}$") message(FATAL_ERROR diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt index 15c91d9..df87980 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_interfaces BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_interfaces PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-install/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt index 6ea2831..78177ce 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-install/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_interfaces PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_source_dir}/importable.cxx" + "${expected_source_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR @@ -31,6 +32,7 @@ get_property(imported_modules TARGET CXXModules::export_interfaces PROPERTY IMPORTED_CXX_MODULES_DEBUG) set(expected_imported_modules "importable=${expected_source_dir}/importable.cxx" + "subdir_importable=${expected_source_dir}/subdir/importable.cxx" ) if (NOT imported_modules STREQUAL "${expected_imported_modules}") message(FATAL_ERROR diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt index 7d04c50..a93e3a4 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_interfaces_no_properties BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_interfaces_no_properties PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt index 9ff88df..18e933c 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-build/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_interfaces_no_properties PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_dir}/importable.cxx" + "${expected_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt index c0db766..99e67e7 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/CMakeLists.txt @@ -18,7 +18,9 @@ target_sources(export_interfaces_no_properties BASE_DIRS "${CMAKE_CURRENT_SOURCE_DIR}" FILES - importable.cxx) + importable.cxx + subdir/importable.cxx + ) target_compile_features(export_interfaces_no_properties PUBLIC cxx_std_20) add_library(no_modules STATIC no_modules.cxx) diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/subdir/importable.cxx b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/subdir/importable.cxx new file mode 100644 index 0000000..07d6af6 --- /dev/null +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/subdir/importable.cxx @@ -0,0 +1,6 @@ +export module subdir_importable; + +export int from_subdir() +{ + return 0; +} diff --git a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt index 9ff88df..18e933c 100644 --- a/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt +++ b/Tests/RunCMake/CXXModules/examples/export-interface-no-properties-install/test/CMakeLists.txt @@ -21,6 +21,7 @@ get_property(file_set_files TARGET CXXModules::export_interfaces_no_properties PROPERTY CXX_MODULE_SET_modules) set(expected_file_set_files "${expected_dir}/importable.cxx" + "${expected_dir}/subdir/importable.cxx" ) if (NOT file_set_files STREQUAL "${expected_file_set_files}") message(FATAL_ERROR -- cgit v0.12