-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathMakefile
46 lines (32 loc) · 994 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
include build.opts
.PHONY: all clean common rts hos cbits progs test util
all: rts common hos cbits util progs hos.iso
hos.iso: rts hos cbits kernel.bin kernel.elf
@echo "Building ISO image..."
cp kernel.bin cd/hos.bin
cp build/progs/init.elf build/progs/storage.elf cd/
cp build/hos.bundle cd
${XORRISO} -as mkisofs -o hos.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table cd
kernel.bin: build/libcbits.a build/librts.a build/hos.o linker.ld
$(CROSSCOMPILE_LD) -T linker.ld build/hos.o -lrts -lcbits -Lbuild -o kernel.bin -Map=kernel.symbols
kernel.elf: build/libcbits.a build/librts.a build/hos.o linker-elf.ld
$(CROSSCOMPILE_LD) -T linker-elf.ld build/hos.o -lrts -lcbits -Lbuild -o kernel.elf
progs:
make -C progs
cbits:
make -C cbits
rts:
make -C rts
common:
make -C common
hos:
make -C src
util:
make -C util
test:
make -C cbits test
make -C rts test
make -C src test
clean:
rm -rf build
make -C util clean