summaryrefslogtreecommitdiff
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-02-15 10:38:45 -0500
committerBrad King <brad.king@kitware.com>2023-02-15 10:48:26 -0500
commitef5a4d964ba1743fd7c343f1a6194ff82936d014 (patch)
tree3fb2f0b8cba3c32d5ee1c7b276bb710cc7227176 /Source
parent37f068083ba53e4140e5660a82bda9708e53c356 (diff)
downloadcmake-ef5a4d964ba1743fd7c343f1a6194ff82936d014.tar.gz
Deprecate "extra" generators in favor of cmake-file-api(7)
The "extra" generators were created in CMake's early years to provide support for users of specific IDEs by directly generating their project files alongside make or ninja files. Nowadays the file-api provides a more generic, maintainable, well-tested, and robust way for IDEs to view CMake project build trees. Deprecate the legacy "extra" generators to encourage the corresponding IDEs to use the file-api. Fixes: #19090
Diffstat (limited to 'Source')
-rw-r--r--Source/cmExtraCodeBlocksGenerator.cxx2
-rw-r--r--Source/cmExtraCodeLiteGenerator.cxx2
-rw-r--r--Source/cmExtraEclipseCDT4Generator.cxx3
-rw-r--r--Source/cmExtraKateGenerator.cxx2
-rw-r--r--Source/cmExtraSublimeTextGenerator.cxx3
-rw-r--r--Source/cmGlobalGenerator.cxx10
6 files changed, 17 insertions, 5 deletions
diff --git a/Source/cmExtraCodeBlocksGenerator.cxx b/Source/cmExtraCodeBlocksGenerator.cxx
index 988c5c3d55..e9e2921316 100644
--- a/Source/cmExtraCodeBlocksGenerator.cxx
+++ b/Source/cmExtraCodeBlocksGenerator.cxx
@@ -45,7 +45,7 @@ cmExtraCodeBlocksGenerator::GetFactory()
{
static cmExternalMakefileProjectGeneratorSimpleFactory<
cmExtraCodeBlocksGenerator>
- factory("CodeBlocks", "Generates CodeBlocks project files.");
+ factory("CodeBlocks", "Generates CodeBlocks project files (deprecated).");
if (factory.GetSupportedGlobalGenerators().empty()) {
#if defined(_WIN32)
diff --git a/Source/cmExtraCodeLiteGenerator.cxx b/Source/cmExtraCodeLiteGenerator.cxx
index 9e8ac5cf0e..7538a7f469 100644
--- a/Source/cmExtraCodeLiteGenerator.cxx
+++ b/Source/cmExtraCodeLiteGenerator.cxx
@@ -33,7 +33,7 @@ cmExtraCodeLiteGenerator::GetFactory()
{
static cmExternalMakefileProjectGeneratorSimpleFactory<
cmExtraCodeLiteGenerator>
- factory("CodeLite", "Generates CodeLite project files.");
+ factory("CodeLite", "Generates CodeLite project files (deprecated).");
if (factory.GetSupportedGlobalGenerators().empty()) {
#if defined(_WIN32)
diff --git a/Source/cmExtraEclipseCDT4Generator.cxx b/Source/cmExtraEclipseCDT4Generator.cxx
index a07acdc9ae..6201889f22 100644
--- a/Source/cmExtraEclipseCDT4Generator.cxx
+++ b/Source/cmExtraEclipseCDT4Generator.cxx
@@ -63,7 +63,8 @@ cmExtraEclipseCDT4Generator::GetFactory()
{
static cmExternalMakefileProjectGeneratorSimpleFactory<
cmExtraEclipseCDT4Generator>
- factory("Eclipse CDT4", "Generates Eclipse CDT 4.0 project files.");
+ factory("Eclipse CDT4",
+ "Generates Eclipse CDT 4.0 project files (deprecated).");
if (factory.GetSupportedGlobalGenerators().empty()) {
// TODO: Verify if __CYGWIN__ should be checked.
diff --git a/Source/cmExtraKateGenerator.cxx b/Source/cmExtraKateGenerator.cxx
index 0020690060..a128a8b11f 100644
--- a/Source/cmExtraKateGenerator.cxx
+++ b/Source/cmExtraKateGenerator.cxx
@@ -25,7 +25,7 @@ cmExtraKateGenerator::cmExtraKateGenerator() = default;
cmExternalMakefileProjectGeneratorFactory* cmExtraKateGenerator::GetFactory()
{
static cmExternalMakefileProjectGeneratorSimpleFactory<cmExtraKateGenerator>
- factory("Kate", "Generates Kate project files.");
+ factory("Kate", "Generates Kate project files (deprecated).");
if (factory.GetSupportedGlobalGenerators().empty()) {
#if defined(_WIN32)
diff --git a/Source/cmExtraSublimeTextGenerator.cxx b/Source/cmExtraSublimeTextGenerator.cxx
index 19e87d52f8..33901ac594 100644
--- a/Source/cmExtraSublimeTextGenerator.cxx
+++ b/Source/cmExtraSublimeTextGenerator.cxx
@@ -43,7 +43,8 @@ cmExtraSublimeTextGenerator::GetFactory()
{
static cmExternalMakefileProjectGeneratorSimpleFactory<
cmExtraSublimeTextGenerator>
- factory("Sublime Text 2", "Generates Sublime Text 2 project files.");
+ factory("Sublime Text 2",
+ "Generates Sublime Text 2 project files (deprecated).");
if (factory.GetSupportedGlobalGenerators().empty()) {
#if defined(_WIN32)
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index 492f848a21..72eed69511 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -1327,6 +1327,16 @@ void cmGlobalGenerator::Configure()
this->BinaryDirectories.insert(
this->CMakeInstance->GetHomeOutputDirectory());
+ if (this->ExtraGenerator && !this->CMakeInstance->GetIsInTryCompile()) {
+ this->CMakeInstance->IssueMessage(
+ MessageType::DEPRECATION_WARNING,
+ cmStrCat("Support for \"Extra Generators\" like\n ",
+ this->ExtraGenerator->GetName(),
+ "\nis deprecated and will be removed from a future version "
+ "of CMake. IDEs may use the cmake-file-api(7) to view "
+ "CMake-generated project build trees."));
+ }
+
// now do it
this->ConfigureDoneCMP0026AndCMP0024 = false;
dirMf->Configure();