mirror of
https://github.com/torvalds/linux.git
synced 2024-11-13 23:51:39 +00:00
1d8617b2a6
Donald points out most YNL makefiles are missing distclean in .PHONY, even tho generated/Makefile does list it. Suggested-by: Donald Hunter <donald.hunter@gmail.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org> Reviewed-by: Donald Hunter <donald.hunter@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
22 lines
349 B
Makefile
22 lines
349 B
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
|
|
SUBDIRS = lib generated samples
|
|
|
|
all: $(SUBDIRS)
|
|
|
|
samples: | lib generated
|
|
|
|
$(SUBDIRS):
|
|
@if [ -f "$@/Makefile" ] ; then \
|
|
$(MAKE) -C $@ ; \
|
|
fi
|
|
|
|
clean distclean:
|
|
@for dir in $(SUBDIRS) ; do \
|
|
if [ -f "$$dir/Makefile" ] ; then \
|
|
$(MAKE) -C $$dir $@; \
|
|
fi \
|
|
done
|
|
|
|
.PHONY: all clean distclean $(SUBDIRS)
|