summaryrefslogtreecommitdiffstats
path: root/makefile
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2015-11-02 11:47:04 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2015-11-02 11:47:04 +0100
commit38b74d5116d410d8a43434ce2564cd6f155cb62b (patch)
tree1b594a8f25168746353500d02f24624a0c934c9a /makefile
parent695f975ca73cdbfe8b9a50dc0ddf7788b2cca650 (diff)
downloados_skeleton-38b74d5116d410d8a43434ce2564cd6f155cb62b.zip
os_skeleton-38b74d5116d410d8a43434ce2564cd6f155cb62b.tar.gz
makefile: add simple subdir handling
Diffstat (limited to 'makefile')
-rw-r--r--makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/makefile b/makefile
index ffe85c3..fd06b87 100644
--- a/makefile
+++ b/makefile
@@ -1,3 +1,5 @@
+SUBDIR=kernel
+
all: run
run: create_iso
@@ -7,8 +9,11 @@ create_iso: cpy
grub-mkrescue -o mini_kernel/mini_kernel.iso mini_kernel
cpy:
+ cd $(SUBDIR); $(MAKE) run
cp grub/grub.cfg mini_kernel/
cp kernel/kernel.elf mini_kernel/
+
clean:
+ cd $(SUBDIR); $(MAKE) clean
-rm mini_kernel/*.iso mini_kernel/*.cfg mini_kernel/*.elf 2>/dev/null