summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Help/release/dev/ninja-edit_cache.rst5
-rw-r--r--Source/cmGlobalCommonGenerator.cxx2
-rw-r--r--Source/cmGlobalNinjaGenerator.cxx7
-rw-r--r--Source/cmGlobalNinjaGenerator.h1
4 files changed, 6 insertions, 9 deletions
diff --git a/Help/release/dev/ninja-edit_cache.rst b/Help/release/dev/ninja-edit_cache.rst
new file mode 100644
index 0000000..9083f56
--- /dev/null
+++ b/Help/release/dev/ninja-edit_cache.rst
@@ -0,0 +1,5 @@
+ninja-edit_cache
+----------------
+
+* The :ref:`Ninja Generators` now implement the ``edit_cache`` target
+ using :manual:`ccmake(1)` if available.
diff --git a/Source/cmGlobalCommonGenerator.cxx b/Source/cmGlobalCommonGenerator.cxx
index a4112db..a8e0f23 100644
--- a/Source/cmGlobalCommonGenerator.cxx
+++ b/Source/cmGlobalCommonGenerator.cxx
@@ -110,7 +110,7 @@ std::string cmGlobalCommonGenerator::GetEditCacheCommand() const
std::string editCacheCommand = cm->GetCMakeEditCommand();
if (!cm->GetCacheDefinition("CMAKE_EDIT_COMMAND") ||
!editCacheCommand.empty()) {
- if (editCacheCommand.empty()) {
+ if (this->SupportsDirectConsole() && editCacheCommand.empty()) {
editCacheCommand = cmSystemTools::GetCMakeCursesCommand();
}
if (editCacheCommand.empty()) {
diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx
index bfc50c8..2d36fd8 100644
--- a/Source/cmGlobalNinjaGenerator.cxx
+++ b/Source/cmGlobalNinjaGenerator.cxx
@@ -1019,13 +1019,6 @@ bool cmGlobalNinjaGenerator::HasRule(const std::string& name)
// Private virtual overrides
-std::string cmGlobalNinjaGenerator::GetEditCacheCommand() const
-{
- // Ninja by design does not run interactive tools in the terminal,
- // so our only choice is cmake-gui.
- return cmSystemTools::GetCMakeGUICommand();
-}
-
void cmGlobalNinjaGenerator::ComputeTargetObjectDirectory(
cmGeneratorTarget* gt) const
{
diff --git a/Source/cmGlobalNinjaGenerator.h b/Source/cmGlobalNinjaGenerator.h
index 519be3f..ec73475 100644
--- a/Source/cmGlobalNinjaGenerator.h
+++ b/Source/cmGlobalNinjaGenerator.h
@@ -488,7 +488,6 @@ protected:
std::string DefaultFileConfig;
private:
- std::string GetEditCacheCommand() const override;
bool FindMakeProgram(cmMakefile* mf) override;
void CheckNinjaFeatures();
void CheckNinjaCodePage();