I am writing a library and planning to compile it with dependencies (such as GoogleTest). The build system looks something like this:
[PROJECT]
|--- deps
|--- src
|--- tests
When running make, the source found in tests is excluded, and when running make check, the contents of tests is compiled and some unit tests run.
The initial idea for deps was for it to be compiled with unit tests when running a custom target such as make deps. How I immagine this to work would be something like:
% cat [PROJECT]/deps/Makefile.am
deps-local:
SUBDIRS=gtest
make check
Although this does not work it seems.
Another idea was to override make check in deps so that it at least does not run the unit tests (which take longer than my patience permits). I tried something like:
% cat [PROJECT]/deps/Makefile.am
SUBDIRS=gtest
check-local:
make
Although this also was unsuccessful.
This have become a curiosity to me, and I would greatly appreciate some pointers. Cheers.
Aucun commentaire:
Enregistrer un commentaire