diff options
author | Brad King <brad.king@kitware.com> | 2013-11-12 08:44:08 -0500 |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2013-11-12 08:47:19 -0500 |
commit | 684063c0363687285126f30a517239aa2ad46149 (patch) | |
tree | c7bb4a0540da44dc14d1b8ab5de4b0102d925dd2 /Source/cmExtraSublimeTextGenerator.cxx | |
parent | eaf5b7a776e24af55f6f7f254171c3e2d2932d9b (diff) | |
download | cmake-684063c0363687285126f30a517239aa2ad46149.tar.gz |
Refactor tool selection for edit_cache (#14544)
Refactor edit_cache tool selection to ask each global generator for its
preference. Teach the Ninja generator to always use cmake-gui because
Ninja by design cannot run interactive terminal dialogs like ccmake.
Teach the Makefile generator to use cmake-gui when also using an "extra"
generator whose IDE has no terminal to run ccmake, and otherwise fall
back to CMAKE_EDIT_COMMAND selection for normal Makefile build systems.
Diffstat (limited to 'Source/cmExtraSublimeTextGenerator.cxx')
-rw-r--r-- | Source/cmExtraSublimeTextGenerator.cxx | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/Source/cmExtraSublimeTextGenerator.cxx b/Source/cmExtraSublimeTextGenerator.cxx index baed733561..9cbdd7ce6d 100644 --- a/Source/cmExtraSublimeTextGenerator.cxx +++ b/Source/cmExtraSublimeTextGenerator.cxx @@ -172,31 +172,11 @@ void cmExtraSublimeTextGenerator:: { case cmTarget::GLOBAL_TARGET: { - bool insertTarget = false; // Only add the global targets from CMAKE_BINARY_DIR, // not from the subdirs if (strcmp(makefile->GetStartOutputDirectory(), makefile->GetHomeOutputDirectory())==0) { - insertTarget = true; - // only add the "edit_cache" target if it's not ccmake, because - // this will not work within the IDE - if (ti->first == "edit_cache") - { - const char* editCommand = makefile->GetDefinition - ("CMAKE_EDIT_COMMAND"); - if (editCommand == 0) - { - insertTarget = false; - } - else if (strstr(editCommand, "ccmake")!=NULL) - { - insertTarget = false; - } - } - } - if (insertTarget) - { this->AppendTarget(fout, ti->first.c_str(), *lg, 0, make.c_str(), makefile, compiler.c_str(), sourceFileFlags, false); |