2022-01-26 20:19:39 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
set -e
|
|
|
|
|
|
|
|
BIN='../cross/root/bin'
|
|
|
|
CROSS="$BIN/i386-elf-"
|
|
|
|
|
2022-01-27 00:29:05 +00:00
|
|
|
./clean.sh
|
|
|
|
|
2022-01-26 21:46:30 +00:00
|
|
|
${CROSS}gcc -c src/x86_stage1.S -o src/x86_stage1.o
|
|
|
|
${CROSS}gcc -c src/x86_stage2.S -o src/x86_stage2.o
|
2022-01-26 20:19:39 +00:00
|
|
|
${CROSS}ld -Ttext 200000 --oformat binary -o src/x86_stage1.bin src/x86_stage1.o
|
|
|
|
${CROSS}ld -Ttext 200000 --oformat binary -o src/x86_stage2.bin src/x86_stage2.o
|
|
|
|
./testyboot mbr mbr.bin src/x86_stage1.bin
|
|
|
|
cat mbr.bin src/x86_stage2.bin > disk.img
|