summaryrefslogtreecommitdiffstats
path: root/testsuite/iproute2/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/iproute2/Makefile')
-rw-r--r--testsuite/iproute2/Makefile34
1 files changed, 34 insertions, 0 deletions
diff --git a/testsuite/iproute2/Makefile b/testsuite/iproute2/Makefile
new file mode 100644
index 0000000..f894605
--- /dev/null
+++ b/testsuite/iproute2/Makefile
@@ -0,0 +1,34 @@
+# SPDX-License-Identifier: GPL-2.0
+SUBDIRS := $(filter-out Makefile,$(wildcard *))
+.PHONY: all configure clean distclean show $(SUBDIRS)
+
+all: configure
+ @for dir in $(SUBDIRS); do \
+ $(MAKE) -C $$dir; \
+ done
+
+link:
+ @if [ ! -L iproute2-this ]; then \
+ ln -s ../.. iproute2-this; \
+ fi
+
+configure: link
+ @for dir in $(SUBDIRS); do \
+ echo "Entering $$dir" && cd $$dir && if [ -f configure ]; then ./configure; fi && cd ..; \
+ done
+
+clean: link
+ @for dir in $(SUBDIRS); do \
+ $(MAKE) -C $$dir clean; \
+ done
+
+distclean: clean
+ @for dir in $(SUBDIRS); do \
+ $(MAKE) -C $$dir distclean; \
+ done
+
+show: link
+ @echo "$(SUBDIRS)"
+
+$(SUBDIRS):
+ cd $@ && $(MAKE)