I have a project with different sub-modules. Each sub-module has a CMakeLists.txt
and I have a general CMakeLists.txt
at the root of the project.
When I run cmake --build [...]
or make [...]
, it recursively builds sub-modules as expected but it prints verbose like this:
make[2]: Entering directory '/some/path/'
make[2]: Entering directory '/some/path/'
make[2]: Leaving directory '/some/path/'
make[2]: Leaving directory '/some/path/'
...
set(CMAKE_VERBOSE_MAKEFILE OFF)
in the general CMakeLists.txt
.make [...] --no-print-directory
cmake [...] -- [...] --no-print-directory
The --no-print-directory
flag removes these messages as intended, but I used to not have to specify this flag in previous projects. I would prefer to avoid using this flag to get the same results as before.
GNU Make 4.3
cmake version 3.16.4
You can use
MAKEFLAGS += --no-print-directory
Described in the GNU make manual
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With