mirror of
https://github.com/cc65/cc65.git
synced 2024-08-20 09:29:12 +00:00
The target util convert.system is to be used in conjunction with GEOS on the Apple II but has to be built as an "ordinary" Apple II program. The way the cc65 library build system is designed there's no way to define dependencies between targets. The solution used so far was to explicitly trigger a build of the target 'apple2enh' from the target 'geos-apple'. However, that approach tends to break parallel builds which may be in the middle of building 'appple2enh' at the time it is triggered by 'geos-apple'. There might be ways to get this fixed - but the the cc65 library build systrem is already (more than) complex enough, so I really don't want to add anything special to it. On the other hand there are easier ways (outside the scope of cc65) to archive what convert.system does so I don't presume convert.system to be actually used - it's more a reference type of thing. Putting all facts together the decision was easy: Just move convert.system from the target it is used with to the target(s) it is built with.
18 lines
739 B
Makefile
18 lines
739 B
Makefile
DEPS += ../libwrk/$(TARGET)/convert.d \
|
|
../libwrk/$(TARGET)/loader.d
|
|
|
|
../libwrk/$(TARGET)/convert.o: $(SRCDIR)/targetutil/convert.c | ../libwrk/$(TARGET)
|
|
$(COMPILE_recipe)
|
|
|
|
../libwrk/$(TARGET)/loader.o: $(SRCDIR)/targetutil/loader.s | ../libwrk/$(TARGET)
|
|
$(ASSEMBLE_recipe)
|
|
|
|
../target/$(TARGET)/util/convert.system: ../libwrk/$(TARGET)/convert.o ../lib/$(TARGET).lib | ../target/$(TARGET)/util
|
|
$(LD65) -o $@ -C $(TARGET)-system.cfg $^
|
|
|
|
../target/$(TARGET)/util/loader.system: ../libwrk/$(TARGET)/loader.o $(SRCDIR)/targetutil/loader.cfg | ../target/$(TARGET)/util
|
|
$(LD65) -o $@ -C $(filter %.cfg,$^) $(filter-out %.cfg,$^)
|
|
|
|
$(TARGET): ../target/$(TARGET)/util/convert.system \
|
|
../target/$(TARGET)/util/loader.system
|