Mercurial > lcfOS
annotate cos/Makefile @ 24:d8627924d40d
Split up in more files and reboot command
author | windel |
---|---|
date | Fri, 02 Dec 2011 14:00:02 +0100 |
parents | 69bc6d477b38 |
children | d3c4bf3720a3 |
rev | line source |
---|---|
9 | 1 # vim: set noexpandtab: |
2 | |
12 | 3 all: bootdisk.img Makefile |
9 | 4 |
20 | 5 bootdisk.img: lcfosc.bin grub/menu.lst Makefile |
9 | 6 cp grub/emptybootdisk.img bootdisk.img |
7 mcopy -D o -i bootdisk.img lcfosc.bin :: | |
8 mcopy -D o -i bootdisk.img grub/menu.lst ::/grub | |
9 | |
10 CRT0 = kernel/goto64.o | |
11 | |
12 CFLAGS = -m64 \ | |
13 -nostdinc \ | |
14 -nostdlib \ | |
15 -nostartfiles \ | |
18
6129643f5c34
Fixed interrupt issue, ds, es, ss, fs and gs were not initialized to 0
windel
parents:
14
diff
changeset
|
16 -mno-red-zone \ |
9 | 17 -fno-builtin \ |
22 | 18 -mcmodel=large |
9 | 19 |
20 OBJECTS = \ | |
21 kernel/video.o \ | |
22 kernel/snprintf.o \ | |
14 | 23 kernel/kernel.o \ |
24 kernel/asmcode.o \ | |
24 | 25 kernel/handlers.o \ |
26 kernel/keyboard.o \ | |
27 kernel/klib.o \ | |
28 kernel/malloc.o \ | |
29 kernel/timer.o | |
14 | 30 |
20 | 31 lcfosc.bin: $(CRT0) $(OBJECTS) linker.ld |
22 | 32 ld -T linker.ld -s -o lcfosc.bin $(CRT0) $(OBJECTS) |
9 | 33 |
12 | 34 %.o : %.asm Makefile |
9 | 35 nasm -f elf64 -o $@ $< |
36 | |
12 | 37 %.o : %.c Makefile |
9 | 38 gcc $(CFLAGS) -o $@ -c $< -Wall -Wextra -Werror |
39 | |
40 clean: | |
20 | 41 rm $(OBJECTS) $(CRT0) lcfosc.bin |
9 | 42 |