Hello again,
I have some targets that are not build by default (using
EXCLUDE_FROM_ALL), these are build when a special target called
extras.
Now I want to add a target that builds both all and extras, but cant
seem to get it to work. For discussion I have these rules:
PROJECT (tester)
2009/10/9 jens persson j...@persson.cx:
add_custom_target(extras
DEPENDS bar
)
which builds foo when running make all and bar when make extras
I have tried to simply add:
add_custom_target(complete
DEPENDS extras all
)
which gives the following error:
[...]
I get the
2009/10/9 Eric Noulard eric.noul...@gmail.com:
2009/10/9 jens persson j...@persson.cx:
I get the impression that I have two problems: depending on a
custom_target and depending on all.
Dependency from builtin target is currently unsupported.
see:
2009/10/9 jens persson j...@persson.cx:
I think dependency from extras should work did you try with
only extras and not all?
Yes I get the following error:
$ make complete
[100%] Built target bar
[100%] Built target extras
make[3]: *** No rule to make target `extras', needed by
Hi Jens,
It's not a bug. Quoting from the docs for add_custom_target:
Dependencies listed with the DEPENDS argument may reference files and
outputs of custom commands created with ADD_CUSTOM_COMMAND.
The problem is that your target 'extras' doesn't create any files. By
saying