mbox series

[0/4] Makefile: Generalize recursion machinery

Message ID 20190528082308.22032-1-armbru@redhat.com (mailing list archive)
Headers show
Series Makefile: Generalize recursion machinery | expand

Message

Markus Armbruster May 28, 2019, 8:23 a.m. UTC
We make a few sub-directories recursively, in particular
$(TARGET_DIRS).

For goal "all", we do it the nice way: "all" has a prerequisite
subdir-T for each T in $(TARGET_DIRS), and T's recipe runs make
recursively.  Behaves nicely with -j and -k.

For other goals such as "clean" and "install", the recipe runs make
recursively in a for loop.  Ignores -j and -k.

Generalize the recursion machinery used by "all" so we can reuse it
for "clean" and "install".

This was previously posted as PATCH 1-4 of "[RFC v4 0/7] Baby steps
towards saner headers".  Changes since then:
* PATCH 1: Don't lose @ [Philippe]
* PATCH 3: Update check-report-qtest-%.tap [Philippe]

Markus Armbruster (4):
  Makefile: Remove code to smooth transition to config.status
  Makefile: Drop bogus cleaning of $(ALL_SUBDIRS)/qemu-options.def
  Makefile: Rename targets for make recursion
  Makefile: Reuse all's recursion machinery for clean and install

 Makefile               | 73 ++++++++++++++++++++----------------------
 configure              |  6 ++--
 tests/Makefile.include |  5 +--
 3 files changed, 40 insertions(+), 44 deletions(-)