Can generate iso image

This commit is contained in:
Mathieu Maret 2018-07-20 16:55:41 +02:00
parent c1afe927cb
commit 84d421a014
2 changed files with 13 additions and 3 deletions

View File

@ -19,9 +19,14 @@ deps = $(csrc:%.c=%.d)
kernel:$(asmobj) $(cobj) linker.ld
$(CC) -m32 -ffreestanding -nostdlib $(cobj) $(asmobj) -o $@ -T linker.ld
fd.img: kernel
dd if=/dev/zero of=$@ bs=512 count=2880
dd if=$< of=$@ conv=notrunc
fd.iso: kernel
mkdir -p isodir/boot/grub
cp $< isodir/boot/grub/
@echo -e "menuentry \"myos\" {\n\tmultiboot /boot/kernel\n}" > isodir/boot/grub/grub.cfg
grub-mkrescue -o $@ isodir
#https://gcc.gnu.org/onlinedocs/gcc/x86-Function-Attributes.html#x86-Function-Attributes
core/exception_handler.o:core/exception_handler.c

5
README.md Normal file
View File

@ -0,0 +1,5 @@
# Dependencies
To generate iso image
`mtools xorriso (which is libisoburn on ArchLinux)`