summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorMichal Idziorek <m.i@gmx.at>2014-09-03 14:04:12 +0200
committerMichal Idziorek <m.i@gmx.at>2014-09-03 14:04:12 +0200
commita6efba7a22b85c0556c8c262f3bbcaf7bda7ddfa (patch)
treee060237fe895995ad1fd6eee0f7f3b19beed8088 /Makefile
parent0ce7674a27043cfdf4115d09d65493ac8af13563 (diff)
Moved kernel to 0x10000 !
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile19
1 files changed, 13 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 936cdab..b591a0a 100644
--- a/Makefile
+++ b/Makefile
@@ -14,17 +14,19 @@
############ some constants ############
#lets use the size of a 1.44 floppy for a start for our boot img
-IMAGE_SIZE=1474560
+IMAGE_SIZE=1474560 #floppy
#ap bin :
-MP_IMG_START=25088
+MP_IMG_START=26112 #multiboot is initially at 0x6600
#font data starts here:
-FONT_DATA_START=26624
+FONT_DATA_START=26624 #fool font initially at 0x6800
USB_STICK=/dev/sdd
+KERNEL_START=0x10000
+
############ flags ############
@@ -81,7 +83,7 @@ all: FoolOS.img
# the kernel_entry.o needs to be FIRST!!
kernel.bin: $(KERNEL_ENTRY) $(ASMOBJECTS) $(OBJECTS)
- ld -o $@ -Ttext 0x1000 --oformat binary -melf_i386 $^ -O0 # --gc-sections --entry=kernel_main -v
+ ld -o $@ -Ttext $(KERNEL_START) --oformat binary -melf_i386 $^ -O0 # --gc-sections --entry=kernel_main -v
############ fool-font ############
@@ -127,5 +129,10 @@ stick: FoolOS.img
-
-
+##### floppy operations #######
+floppy_losetup_on:
+ sudo losetup /dev/loop0 data/floppy.img
+floppy_losetup_off:
+ sudo losetup -d /dev/loop0
+floppy_init:
+ sudo dd if=/dev/zero of=data/floppy.img count=2880 bs=512