1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-07 14:50:15 +00:00

Read static symbols from .mdebug in sym_info.py (#2460)

* Patch .mdebug for data_with_rodata objects

* Read static symbols from .mdebug in sym_info.py

* Add ability to print all symbols

* Add license

* Fix bug when missing .mdebug section

* /patch_data_with_rodata_mdebug.py license + nitpicks
This commit is contained in:
cadmic 2025-02-09 15:16:18 -08:00 committed by GitHub
parent 36b71ca2de
commit be1f9e75f0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 384 additions and 21 deletions

View file

@ -937,6 +937,7 @@ endif
# Incremental link to move z_message and z_game_over data into rodata
$(BUILD_DIR)/src/code/z_message_z_game_over.o: $(BUILD_DIR)/src/code/z_message.o $(BUILD_DIR)/src/code/z_game_over.o
$(LD) -r -G 0 -T linker_scripts/data_with_rodata.ld -o $@ $^
$(PYTHON) tools/patch_data_with_rodata_mdebug.py $@
$(BUILD_DIR)/dmadata_table_spec.h $(BUILD_DIR)/compress_ranges.txt: $(BUILD_DIR)/spec
$(MKDMADATA) $< $(BUILD_DIR)/dmadata_table_spec.h $(BUILD_DIR)/compress_ranges.txt
@ -971,6 +972,7 @@ ifneq ($(RUN_CC_CHECK),0)
endif
$(CC) -c $(CFLAGS) $(MIPS_VERSION) $(OPTFLAGS) -o $(@:.o=.tmp) $<
$(LD) -r -T linker_scripts/data_with_rodata.ld -o $@ $(@:.o=.tmp)
$(PYTHON) tools/patch_data_with_rodata_mdebug.py $@
@$(OBJDUMP) $(OBJDUMP_FLAGS) $@ > $(@:.o=.s)
ifeq ($(PLATFORM),IQUE)
@ -1136,6 +1138,7 @@ ifneq ($(RUN_CC_CHECK),0)
endif
$(CC) -c $(CFLAGS) $(MIPS_VERSION) $(OPTFLAGS) -o $(@:.o=.tmp) $<
$(LD) -r -T linker_scripts/data_with_rodata.ld $(@:.o=.tmp) -o $@
$(PYTHON) tools/patch_data_with_rodata_mdebug.py $@
@$(RM) $(@:.o=.tmp)
$(BUILD_DIR)/assets/audio/sequence_font_table.o: $(BUILD_DIR)/assets/audio/sequence_font_table.s