aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorKimplul <kimi.h.kuparinen@gmail.com>2022-05-05 22:50:00 +0000
committerKimplul <kimi.h.kuparinen@gmail.com>2022-05-05 22:50:00 +0000
commita3c239e78ac9e2f6238287c89222671b23624b7f (patch)
treec3c3f82ed3bc6d8f7fcd07878a8edcfc6f1e5777 /Makefile
parent5fb1af3ab12880331fb1e2150aa23b1278e60ddd (diff)
downloadkmi-a3c239e78ac9e2f6238287c89222671b23624b7f.tar.gz
kmi-a3c239e78ac9e2f6238287c89222671b23624b7f.zip
fix makefiles on netbsd
+ Doesn't quite compile all the way unfortunately, building the GNU toolchain on NetBSD is a bit more difficult than I was expecting. LLVM does compile, but fails to link for some reason.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 2e46774..7d7e04d 100644
--- a/Makefile
+++ b/Makefile
@@ -32,7 +32,7 @@ COMPILER != [ $(LLVM) ] \
KERNEL_SOURCES != echo common/*.c common/uapi/*.c lib/*.c
-CLEANUP := build deps.mk kernel.* init.* apos.bin
+CLEANUP := build kernel.* init.* apos.bin
CLEANUP_CMD :=
INIT_SOURCES :=
@@ -64,7 +64,7 @@ KERN_INFO = sed "s/<KERNEL_SIZE>/$$($(KERN_SIZE))/"
KERNEL_LINK := arch/$(ARCH)/conf/kernel-link
INIT_LINK := arch/$(ARCH)/conf/init-link
-KERN_FLAGS != [ $(UBSAN) ] && echo -fsanitize=undefined
+KERN_FLAGS != [ $(UBSAN) ] && echo -fsanitize=undefined || echo
INIT_FLAGS :=
KERNEL_OBJECTS != ./scripts/gen-deps --kernel --compile "$(KERNEL_SOURCES)"
@@ -97,6 +97,8 @@ format:
find arch lib common include -iname '*.[ch]' \
-exec clang-format -i -style=file {} \+
+RM ?= rm -f
+
clean:
$(RM) -r $(CLEANUP)