mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-16 20:21:41 -06:00
Makefiles: Fix silencing of nested calls for GNU make 4.3
Since GNU make 4.3, `.SILENT:` no longer causes nested `$(MAKE)` calls to get `-s` implicitly. Add the `-s` flag explicitly on such calls to suppress messages about Entering/Leaving directories. Fixes: #20487
This commit is contained in:
@@ -712,6 +712,10 @@ void cmLocalUnixMakefileGenerator3::WriteSpecialTargetsTop(
|
|||||||
;
|
;
|
||||||
/* clang-format on */
|
/* clang-format on */
|
||||||
} else {
|
} else {
|
||||||
|
makefileStream << "# Command-line flag to silence nested $(MAKE).\n"
|
||||||
|
"$(VERBOSE)MAKESILENT = -s\n"
|
||||||
|
"\n";
|
||||||
|
|
||||||
// Write special target to silence make output. This must be after
|
// Write special target to silence make output. This must be after
|
||||||
// the default target in case VERBOSE is set (which changes the
|
// the default target in case VERBOSE is set (which changes the
|
||||||
// name). The setting of CMAKE_VERBOSE_MAKEFILE to ON will cause a
|
// name). The setting of CMAKE_VERBOSE_MAKEFILE to ON will cause a
|
||||||
@@ -1910,7 +1914,7 @@ std::string cmLocalUnixMakefileGenerator3::GetRecursiveMakeCall(
|
|||||||
{
|
{
|
||||||
// Call make on the given file.
|
// Call make on the given file.
|
||||||
std::string cmd = cmStrCat(
|
std::string cmd = cmStrCat(
|
||||||
"$(MAKE) -f ",
|
"$(MAKE) $(MAKESILENT) -f ",
|
||||||
this->ConvertToOutputFormat(makefile, cmOutputConverter::SHELL), ' ');
|
this->ConvertToOutputFormat(makefile, cmOutputConverter::SHELL), ' ');
|
||||||
|
|
||||||
cmGlobalUnixMakefileGenerator3* gg =
|
cmGlobalUnixMakefileGenerator3* gg =
|
||||||
|
|||||||
Reference in New Issue
Block a user