selfmade-os

view makefile @ 1:42ba76f77035

the kernel with output and mem alloc
author meillo@marmaro.de
date Sun, 01 Nov 2009 23:50:51 +0100
parents
children
line source
2 CC = i386-elf-gcc
3 CFLAGS = -Wall -Wextra -nostdlib -nostartfiles -nodefaultlibs
5 LD = i386-elf-ld
6 LDFLAGS = -T linker.ld
8 OBJ = loader.o kernel.o io.o mem.o
10 qemu: os.iso
11 qemu -m 16 -boot cd -cdrom os.iso
13 os.iso: kernel
14 cp kernel os-isofiles/boot/kernel
15 genisoimage -R -b boot/grub/stage2_eltorito -no-emul-boot -boot-load-size 4 -boot-info-table -o os.iso os-isofiles
17 loader.o: loader.s
18 yasm -f elf -o loader.o loader.s
20 kernel: linker.ld $(OBJ)
21 i386-elf-ld -T linker.ld -o kernel $(OBJ)
23 clean:
24 rm -f *.o
25 rm -f kernel
27 distclean: clean
28 rm -f os.iso