summaryrefslogtreecommitdiffstats
path: root/testsuite/module-playground/Makefile.arch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 17:03:56 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 17:03:56 +0000
commit18da3ffcd7f3c8a0c5f790c801b5813503c2273d (patch)
tree84caf98dc5cef3d123c56ba12e35fd67026e0693 /testsuite/module-playground/Makefile.arch
parentInitial commit. (diff)
downloadkmod-18da3ffcd7f3c8a0c5f790c801b5813503c2273d.tar.xz
kmod-18da3ffcd7f3c8a0c5f790c801b5813503c2273d.zip
Adding upstream version 31+20240202.upstream/31+20240202
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testsuite/module-playground/Makefile.arch')
-rw-r--r--testsuite/module-playground/Makefile.arch14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/module-playground/Makefile.arch b/testsuite/module-playground/Makefile.arch
new file mode 100644
index 0000000..47bd9cb
--- /dev/null
+++ b/testsuite/module-playground/Makefile.arch
@@ -0,0 +1,14 @@
+ifeq ($(ARCH),)
+ $(error ARCH must be set to a valid architecture)
+endif
+
+default:
+ @cmp --quiet mod-simple.c mod-simple-$(ARCH).c || ( \
+ ln -sf mod-simple.c mod-simple-$(ARCH).c; \
+ /bin/false \
+ )
+ $(MAKE) -C $(KDIR_$(ARCH)) CROSS_COMPILE=$(CROSS_COMPILE_$(ARCH)) M=$$PWD KMOD_TESTSUITE_ARCH_BUILD=1
+
+clean:
+ $(MAKE) -C $(KDIR_$(ARCH)) CROSS_COMPILE=$(CROSS_COMPILE_$(ARCH)) M=$$PWD KMOD_TESTSUITE_ARCH_BUILD=1 clean
+ rm -f mod-simple-$(ARCH).c