build: n'utilise plus objcopy pour la génération du binaire pur
This commit is contained in:
parent
5bea78de5b
commit
19dca7321b
|
@ -1,30 +1,20 @@
|
||||||
FREEC=gcc -O2 -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -I ../Include -c -o
|
FREEC=gcc -O2 -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -I ../Include -c -o
|
||||||
|
LINK=ld -N -Ttext 0x100000 -e main -o
|
||||||
|
|
||||||
LINK=ld -Ttext 0x100000 -e __main -o
|
|
||||||
|
|
||||||
all: system.sys
|
all: system.sys
|
||||||
sync
|
sync
|
||||||
|
|
||||||
copy:
|
|
||||||
(cp system.sys /cygdrive/a)
|
|
||||||
|
|
||||||
copy2:
|
|
||||||
(cp system.sys /cygdrive/b)
|
|
||||||
|
|
||||||
system.sys:
|
system.sys:
|
||||||
nasm -f bin -o loader.bin loader.asm
|
nasm -f bin -o loader.bin loader.asm
|
||||||
nasm -f elf -o system.o system.asm
|
nasm -f elf -o system.o system.asm
|
||||||
|
|
||||||
$(FREEC) systemc.o system.c
|
$(FREEC) systemc.o system.c
|
||||||
$(LINK) system.out systemc.o system.o ../lib/libs.o
|
$(LINK) system.bin systemc.o system.o ../lib/libs.o --oformat binary
|
||||||
objcopy -O binary system.out system.bin
|
|
||||||
cat loader.bin>system.sys
|
cat loader.bin>system.sys
|
||||||
cat system.bin>>system.sys
|
cat system.bin>>system.sys
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -f *.o
|
rm -f *.o
|
||||||
rm -f *.out
|
|
||||||
rm -f *.bin
|
rm -f *.bin
|
||||||
rm -f *.sys
|
rm -f *.sys
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue