mardi 4 novembre 2014

Control the output of subcalls to `make`


Vote count:

0




I have a Makefile where one of the goals looks as follows:



task: $(foreach t,$(SUBDIRS),subtask_$t)

subtask_%:
make -C $* subtask


In words, task runs the subtask goals defined in each Makefile found in the directories in the list $(SUBDIRS). By default, the output to the console is the combination of all outputs from the subtasks. Is there a way to simply output, e.g. $* SUCCESS or $* FAILED depending on the exit code?


I have tried using @make..., but this doesn't mask the output of the commands run from the other Makefiles.


Ideally, I would like to keep the sub-Makefiles unchanges, as I still occasionally want to use them directly and get the full output.



asked 52 secs ago

Philippe

5,464






Control the output of subcalls to `make`

Aucun commentaire:

Enregistrer un commentaire