Eric Blake <ebl...@redhat.com> writes: > Adding a new qapi module requires some rather tedious repetition to > wire it into Makefile and Makefile.objs. Add some indirection by > taking advantage of GNU Make string processing to expand a list > of module names into all the required artifacts, so that future > additions of a new module need only touch the list of module names. > > The list has to live in Makefile.objs, due to the way that > unnest-vars slirps in that file without remembering any definition > of $(QAPI_MODULES) from Makefile. > > Signed-off-by: Eric Blake <ebl...@redhat.com> > > --- > v2: also condense Makefile.objs, prefer $(FOO:%=a%b) over > %(patsubst %,a%b,$(foo)) > --- > Makefile | 192 ++++++-------------------------------------------- > Makefile.objs | 75 ++------------------ > 2 files changed, 30 insertions(+), 237 deletions(-)
Lovely diffstat. Reviewed-by: Markus Armbruster <arm...@redhat.com>