Assembly statements for main game code

This commit is contained in:
Ryan Dwyer 2019-10-04 17:29:31 +10:00
parent 34d7db60bf
commit 77cd742ed4
2 changed files with 495325 additions and 0 deletions

View File

@ -184,6 +184,25 @@ $(B_DIR)/ucode/rarezip.elf: $(B_DIR)/ucode/rarezip.o
$(B_DIR)/ucode/rarezip.bin: $(B_DIR)/ucode/rarezip.elf
$(TOOLCHAIN)-objcopy $< $@ -O binary
################################################################################
# Main game
game: $(B_DIR)/ucode/game.bin
$(B_DIR)/game.o: src/game/game.c
mkdir -p $(B_DIR)/ucode
python tools/asmpreproc/asm-processor.py -O2 $< | $(QEMU_IRIX) -silent -L $(IRIX_ROOT) $(IRIX_ROOT)/usr/bin/cc -c $(CFLAGS) tools/asmpreproc/include-stdin.c -o $@ -O2
python tools/asmpreproc/asm-processor.py -O2 $< --post-process $@ --assembler "$(TOOLCHAIN)-as -march=vr4300 -mabi=32" --asm-prelude tools/asmpreproc/prelude.s
$(B_DIR)/game.elf: $(B_DIR)/game.o $(B_DIR)/library.o $(B_DIR)/setup.o
$(TOOLCHAIN)-ld -T ld/game.ld -o $@
$(B_DIR)/ucode/game.bin: $(B_DIR)/game.elf
mkdir -p $(B_DIR)/ucode
$(TOOLCHAIN)-objcopy $< $@ -O binary
dd if="$@" of="$@.tmp" bs=1808864 count=1
mv "$@.tmp" "$@"
################################################################################
# Test related

495306
src/game/game.c Normal file

File diff suppressed because it is too large Load Diff