summaryrefslogtreecommitdiffstats
path: root/lib/libjove/Makefile
diff options
context:
space:
mode:
authorJon Santmyer <jon@jonsantmyer.com>2025-08-10 15:46:33 -0400
committerJon Santmyer <jon@jonsantmyer.com>2025-08-10 15:46:33 -0400
commit65ba015d6c1f248d36ad01a653bc49637804b15b (patch)
treea77c3fb3ca7ecac8f65eb9638d152f1e90307d0a /lib/libjove/Makefile
downloadjove-os-65ba015d6c1f248d36ad01a653bc49637804b15b.tar.gz
jove-os-65ba015d6c1f248d36ad01a653bc49637804b15b.tar.bz2
jove-os-65ba015d6c1f248d36ad01a653bc49637804b15b.zip
working usermode objdir iteration
Diffstat (limited to 'lib/libjove/Makefile')
-rw-r--r--lib/libjove/Makefile18
1 files changed, 18 insertions, 0 deletions
diff --git a/lib/libjove/Makefile b/lib/libjove/Makefile
new file mode 100644
index 0000000..cc5f347
--- /dev/null
+++ b/lib/libjove/Makefile
@@ -0,0 +1,18 @@
+include $(CONFIG)
+
+CDIRS := syscall object arch/$(TARGET_MACHINE)
+CFILES := $(wildcard *.c)
+CFILES += $(foreach dir,$(CDIRS),$(wildcard $(dir)/*.c))
+
+OFILES := $(patsubst %.c,%.o,$(CFILES))
+
+CFLAGS := -ffreestanding -nostdlib -Iinclude -g
+
+all: ${OFILES}
+ ar rcs $(OUT)/libjove.a $(OFILES)
+
+clean:
+ -rm $(OFILES)
+
+%.o:%.c
+ $(CC) $(CFLAGS) -c $< -o $@