mirror of
https://github.com/cc65/cc65.git
synced 2025-02-08 11:31:34 +00:00
Added a makefile dependency for the libraries' "extra" files.
Some of the files in "libsrc/*/extra/" include other library files. But, the "lib/*.o" files weren't rebuilt when those other files changed. The new dependency rules must be "bootstrapped". You must force a rebuild of all of the extra library object files (it will create the dependency files). Use these commands: rm lib/*.o make lib
This commit is contained in:
parent
4cf7ee1dba
commit
d1501731e4
@ -196,6 +196,7 @@ DEPS = $(OBJS:.o=.d)
|
||||
EXTRA_SRCPAT = $(SRCDIR)/extra/%.s
|
||||
EXTRA_OBJPAT = ../lib/$(TARGET)-%.o
|
||||
EXTRA_OBJS := $(patsubst $(EXTRA_SRCPAT),$(EXTRA_OBJPAT),$(wildcard $(SRCDIR)/extra/*.s))
|
||||
DEPS += $(EXTRA_OBJS:../lib/%.o=../libwrk/$(TARGET)/%.d)
|
||||
|
||||
ZPOBJ = ../libwrk/$(TARGET)/zeropage.o
|
||||
ifeq ($(TARGET),$(filter $(TARGET),$(EXTZP)))
|
||||
@ -281,7 +282,7 @@ endef # COMPILE_recipe
|
||||
|
||||
$(EXTRA_OBJPAT): $(EXTRA_SRCPAT) | ../lib
|
||||
@echo $(TARGET) - $(<F)
|
||||
@$(CA65) -t $(TARGET) $(CA65FLAGS) -o $@ $<
|
||||
@$(CA65) -t $(TARGET) $(CA65FLAGS) --create-dep $(@:../lib/%.o=../libwrk/$(TARGET)/%.d) -o $@ $<
|
||||
|
||||
../lib/$(TARGET).lib: $(OBJS) | ../lib
|
||||
$(AR65) a $@ $?
|
||||
|
Loading…
x
Reference in New Issue
Block a user