mirror of https://github.com/pret/pokecrystal.git
Get rid of globals.asm
This breaks the build until labels are exported again!
This commit is contained in:
parent
65efbe55e7
commit
7f0f21b1fc
15
Makefile
15
Makefile
|
@ -30,7 +30,7 @@ ROMS := pokecrystal.gbc
|
||||||
ALL_DEPENDENCIES :=
|
ALL_DEPENDENCIES :=
|
||||||
# generate a list of dependencies for each object file
|
# generate a list of dependencies for each object file
|
||||||
$(shell $(foreach obj, $(OBJS), \
|
$(shell $(foreach obj, $(OBJS), \
|
||||||
$(eval $(obj:.o=)_DEPENDENCIES := $(shell $(PYTHON) $(POKEMONTOOLS)/scan_includes.py $(obj:.o=.asm) | sed s/globals.asm//g)) \
|
$(eval $(obj:.o=)_DEPENDENCIES := $(shell $(PYTHON) $(POKEMONTOOLS)/scan_includes.py $(obj:.o=.asm))) \
|
||||||
))
|
))
|
||||||
$(shell $(foreach obj, $(OBJS), \
|
$(shell $(foreach obj, $(OBJS), \
|
||||||
$(eval ALL_DEPENDENCIES += $($(obj:.o=)_DEPENDENCIES)) \
|
$(eval ALL_DEPENDENCIES += $($(obj:.o=)_DEPENDENCIES)) \
|
||||||
|
@ -44,7 +44,6 @@ crystal: pokecrystal.gbc
|
||||||
clean:
|
clean:
|
||||||
rm -f $(ROMS)
|
rm -f $(ROMS)
|
||||||
rm -f $(OBJS)
|
rm -f $(OBJS)
|
||||||
rm -f globals.asm
|
|
||||||
find -iname '*.tx' -exec rm {} +
|
find -iname '*.tx' -exec rm {} +
|
||||||
|
|
||||||
baserom.gbc: ;
|
baserom.gbc: ;
|
||||||
|
@ -56,17 +55,13 @@ baserom.gbc: ;
|
||||||
$(eval TEXTQUEUE := $(TEXTQUEUE) $<)
|
$(eval TEXTQUEUE := $(TEXTQUEUE) $<)
|
||||||
@rm -f $@
|
@rm -f $@
|
||||||
|
|
||||||
globals.asm: $(ALL_DEPENDENCIES:.asm=.tx) $(OBJS:.o=.tx)
|
|
||||||
@touch $@
|
|
||||||
@$(PYTHON) prequeue.py $(TEXTQUEUE)
|
|
||||||
globals.tx: globals.asm
|
|
||||||
@cp $< $@
|
|
||||||
|
|
||||||
$(OBJS): $$*.tx $$(patsubst %.asm, %.tx, $$($$*_DEPENDENCIES))
|
$(OBJS): $$*.tx $$(patsubst %.asm, %.tx, $$($$*_DEPENDENCIES))
|
||||||
|
@$(PYTHON) prequeue.py $(TEXTQUEUE)
|
||||||
|
@$(eval TEXTQUEUE :=)
|
||||||
rgbasm -o $@ $*.tx
|
rgbasm -o $@ $*.tx
|
||||||
|
|
||||||
pokecrystal.gbc: globals.tx $(CRYSTAL_OBJS)
|
pokecrystal.gbc: $(CRYSTAL_OBJS)
|
||||||
rgblink -n $*.sym -m $*.map -o $@ $(CRYSTAL_OBJS)
|
rgblink -n $*.sym -m $*.map -o $@ $^
|
||||||
rgbfix -Cjv -i BYTE -k 01 -l 0x33 -m 0x10 -p 0 -r 3 -t PM_CRYSTAL $@
|
rgbfix -Cjv -i BYTE -k 01 -l 0x33 -m 0x10 -p 0 -r 3 -t PM_CRYSTAL $@
|
||||||
cmp baserom.gbc $@
|
cmp baserom.gbc $@
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,2 @@
|
||||||
INCLUDE "globals.asm"
|
|
||||||
INCLUDE "contents.asm"
|
INCLUDE "contents.asm"
|
||||||
INCLUDE "constants.asm"
|
INCLUDE "constants.asm"
|
||||||
|
|
|
@ -66,7 +66,6 @@ def setup_processor():
|
||||||
def main():
|
def main():
|
||||||
processor = setup_processor()
|
processor = setup_processor()
|
||||||
processor.preprocess()
|
processor.preprocess()
|
||||||
processor.update_globals()
|
|
||||||
|
|
||||||
# only run against stdin when not included as a module
|
# only run against stdin when not included as a module
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
|
@ -23,8 +23,6 @@ def preprocess_queue(filenames=sys.argv[1:]):
|
||||||
sys.stdout = open(dest, 'w')
|
sys.stdout = open(dest, 'w')
|
||||||
processor.preprocess()
|
processor.preprocess()
|
||||||
|
|
||||||
processor.update_globals()
|
|
||||||
|
|
||||||
sys.stdin = stdin
|
sys.stdin = stdin
|
||||||
sys.stdout = stdout
|
sys.stdout = stdout
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue