CPS: Fix exporting definitions in CMake 4.1

Backport commit 37b15eda3b (CPS: Fix exporting definitions, 2025-11-21)
to CMake 4.1.

Export compile definitions to CPS using the correct attribute name.

Fixes: #27403
This commit is contained in:
Matthew Woehlke
2025-11-21 15:32:41 -05:00
committed by Brad King
parent 0848aac41c
commit b2ca9fba8b
5 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -451,7 +451,7 @@ void cmExportPackageInfoGenerator::GenerateInterfaceCompileDefines(
}
if (!defines.empty()) {
component["compile_definitions"]["*"] = std::move(defines);
component["definitions"]["*"] = std::move(defines);
}
}