[Dune-devel] behaviour of "make build_tests"

Christoph Grüninger christoph.grueninger at iws.uni-stuttgart.de
Sun Nov 1 18:09:22 CET 2015


Hi Christian,
it's a limitation of CMake's Unix Makefile generator. This
behavior was also part of PDELab since it uses build_tests.

> I tried to call make build_tests in subdirectory in order to 
> build the tests for this directory... to no vail. It seems
> the command is only known in the top level directory. Is this
> on purpose? Why?

Some people say recursive makefiles are slow or plain evil. As
it has a use-case, I don't follow this argument. Still, it is
a limitation from CMake. We know about it since Dominic
implemented headercheck.
I tried to find a source for the reason or whether this is
documented somewhere, but I could not find anything related. 
For
sure there is some rational behind it.


> a) the command is available in every subdirectory
> and if possible (I'm aware that cmake sometimes doesn't 
> allow everything that make can do)

That's true for built-in targets like all, test, clean etc.

> b) only apply to that sub-tree.

Maybe we can create a target per test folder.

In general I don't understand why so many people want all
targets in the top directory. Ninja-build supports only
targets there. For IDEs like Eclipse or Visual Studio I
get it, but not for the command line.

Bye
Christoph

-- 
Je n'ai rien contre les étrangers, quelques uns de mes 
meilleurs amis
sont des étrangers. Mais ces étrangers là ne sont pas de chez 
nous!
[Agecanonix, Astérix - Le cadeau de César]




More information about the Dune-devel mailing list