This commit is contained in:
2025-02-17 23:46:39 +00:00
parent 113fed4ae1
commit e392f01c65
4 changed files with 48 additions and 27 deletions

View File

@@ -1,6 +1,6 @@
all:
arm-none-eabi-gcc -r -Tlibpqscheme.ld -fPIC -nostartfiles -o libpqscheme_test.elf libpqscheme_test.c -Iruntime_mps2/out/an386/pack/include
arm-none-eabi-gcc -mcpu=Cortex-M4 -Truntime_mps2/out/an386/pack/lib/mps2.ld -nostartfiles -o runner.elf runner.c -Lruntime_mps2/out/an386/pack/lib -lmps2-an386_runtime -Iruntime_mps2/out/an386/pack/include
arm-none-eabi-gcc -ggdb -mcpu=Cortex-M4 -mthumb -r -Tlibpqscheme.ld -fPIC -nostartfiles -o libpqscheme_test.elf libpqscheme_test.c -Iruntime_mps2/out/an386/pack/include
arm-none-eabi-gcc -ggdb -mcpu=Cortex-M4 -mthumb -Truntime_mps2/out/an386/pack/lib/mps2.ld -nostartfiles -o runner.elf runner.c -Lruntime_mps2/out/an386/pack/lib -lmps2-an386_runtime -Iruntime_mps2/out/an386/pack/include
arm-none-eabi-ar rcs runner runner.elf
arm-none-eabi-objcopy -O binary libpqscheme_test.elf libpqscheme_test.bin
@@ -11,8 +11,11 @@ run:
-cpu cortex-m4 \
-nographic \
-kernel runner.elf \
-initrd libpqscheme_test.elf \
-semihosting
-semihosting \
-device loader,file=libpqscheme_test.elf,addr=0x00300000
# -S -gdb tcp::1234
# -monitor unix:/tmp/qemu-monitor,server,nowait
clean:
rm -rf *.o *.a *.elf *.bin