Prevent building unused asm (#369)

* Grep spec to know which asm should be built

* Remove cut
This commit is contained in:
Anghelo Carvajal 2021-10-24 15:56:48 -03:00 committed by GitHub
parent 57a9fb7b34
commit 6b8baad7bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -129,7 +129,8 @@ TEXTURE_FILES_OUT := $(foreach f,$(TEXTURE_FILES_PNG:.png=.inc.c),build/$f) \
$(foreach f,$(TEXTURE_FILES_JPG:.jpg=.jpg.inc.c),build/$f) \
C_FILES := $(foreach dir,$(SRC_DIRS),$(wildcard $(dir)/*.c))
S_FILES := $(foreach dir,$(ASM_DIRS),$(wildcard $(dir)/*.s))
S_FILES := $(shell grep -F "build/asm" spec | sed 's/.*build\/// ; s/\.o\".*/.s/') \
$(shell grep -F "build/data" spec | sed 's/.*build\/// ; s/\.o\".*/.s/')
O_FILES := $(foreach f,$(S_FILES:.s=.o),build/$f) \
$(foreach f,$(wildcard baserom/*),build/$f.o) \
$(foreach f,$(C_FILES:.c=.o),build/$f) \