diff options
author | Benji Dial <Benji3.141@gmail.com> | 2019-12-24 22:31:22 -0500 |
---|---|---|
committer | Benji Dial <Benji3.141@gmail.com> | 2019-12-24 22:31:22 -0500 |
commit | f5f0f5ddae199121daebcd2213aabd81686cc074 (patch) | |
tree | 91d8d29ea497e282f841849e620d43f8fcafcfcc /makefile | |
parent | a947a7a143029ee8ef5cb4a4232d7439b8a79670 (diff) | |
download | portland-os-f5f0f5ddae199121daebcd2213aabd81686cc074.tar.gz |
start of 0.0.9 branch, using multiboot this time
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 24 |
1 files changed, 10 insertions, 14 deletions
@@ -1,18 +1,14 @@ -floppy: bootloader fs - mkfs.fat -C -f 1 -F 12 -n "PORTLAND OS" -R 2 -S 512 out/floppy.img 1440 - mkdir out/floppy_mount - mount out/floppy.img out/floppy_mount - cp out/fs/* out/floppy_mount/ - umount out/floppy_mount - dd if=obj/bootloader.bin of=out/floppy.img bs=1 seek=62 conv=notrunc +floppy: kernel + #TODO -bootloader: obj - nasm src/bootloader.asm -o obj/bootloader.bin - -kernel: obj fs - gcc src/kernel/*.c -o obj/kernel.elf -ffreestanding -nostdlib -m32 -fno-asynchronous-unwind-tables - ld obj/kernel.elf -o obj/kernel-stripped.elf -T src/kernel/link.ld -s --orphan-handling=discard -m elf_i386 - objcopy obj/kernel-stripped.elf out/fs/kernel.sys -O binary +kernel: obj out + nasm src/kernel/stub.asm -o obj/kstub.o -f elf32 + gcc -c src/kernel/files.c -o obj/kfiles.o -ffreestanding -nostdlib -m32 + gcc -c src/kernel/main.c -o obj/kmain.o -ffreestanding -nostdlib -m32 + gcc -c src/kernel/mem.c -o obj/kmem.o -ffreestanding -nostdlib -m32 + gcc -c src/kernel/proc.c -o obj/kproc.o -ffreestanding -nostdlib -m32 + gcc -c src/kernel/vga.c -o obj/kvga.o -ffreestanding -nostdlib -m32 + ld obj/k*.o -o out/kernel.elf -T src/kernel/link.ld -s --orphan-handling=discard -m elf_i386 clean: rm -r obj out |