Place resource files after all
This will avoid them acting as default targets
This commit is contained in:
40
Makefile
40
Makefile
@@ -49,26 +49,10 @@ include project.mk
|
|||||||
|
|
||||||
################################################
|
################################################
|
||||||
# #
|
# #
|
||||||
# RESOURCE FILES #
|
# TARGETS #
|
||||||
# #
|
# #
|
||||||
################################################
|
################################################
|
||||||
|
|
||||||
# By default, asset recipes convert files in `res/` into other files in `res/`
|
|
||||||
# This line causes assets not found in `res/` to be also looked for in `src/res/`
|
|
||||||
# "Source" assets can thus be safely stored there without `make clean` removing them
|
|
||||||
VPATH := $(SRCDIR)
|
|
||||||
|
|
||||||
# Define how to compress files using the PackBits16 codec
|
|
||||||
# Compressor script requires Python 3
|
|
||||||
$(RESDIR)/%.pb16: $(SRCDIR)/tools/pb16.py $(RESDIR)/%
|
|
||||||
$^ $@
|
|
||||||
|
|
||||||
###############################################
|
|
||||||
# #
|
|
||||||
# COMPILATION #
|
|
||||||
# #
|
|
||||||
###############################################
|
|
||||||
|
|
||||||
# `all` (Default target): build the ROM
|
# `all` (Default target): build the ROM
|
||||||
all: $(ROM)
|
all: $(ROM)
|
||||||
.PHONY: all
|
.PHONY: all
|
||||||
@@ -88,6 +72,12 @@ rebuild:
|
|||||||
$(MAKE) all
|
$(MAKE) all
|
||||||
.PHONY: rebuild
|
.PHONY: rebuild
|
||||||
|
|
||||||
|
###############################################
|
||||||
|
# #
|
||||||
|
# COMPILATION #
|
||||||
|
# #
|
||||||
|
###############################################
|
||||||
|
|
||||||
# How to build a ROM
|
# How to build a ROM
|
||||||
$(BINDIR)/%.$(ROMEXT) $(BINDIR)/%.sym $(BINDIR)/%.map: $(patsubst $(SRCDIR)/%.asm,$(OBJDIR)/%.o,$(SRCS))
|
$(BINDIR)/%.$(ROMEXT) $(BINDIR)/%.sym $(BINDIR)/%.map: $(patsubst $(SRCDIR)/%.asm,$(OBJDIR)/%.o,$(SRCS))
|
||||||
@$(MKDIR_P) $(@D)
|
@$(MKDIR_P) $(@D)
|
||||||
@@ -106,3 +96,19 @@ $(OBJDIR)/%.o $(DEPDIR)/%.mk: $(SRCDIR)/%.asm
|
|||||||
ifneq ($(MAKECMDGOALS),clean)
|
ifneq ($(MAKECMDGOALS),clean)
|
||||||
-include $(patsubst $(SRCDIR)/%.asm,$(DEPDIR)/%.mk,$(SRCS))
|
-include $(patsubst $(SRCDIR)/%.asm,$(DEPDIR)/%.mk,$(SRCS))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
################################################
|
||||||
|
# #
|
||||||
|
# RESOURCE FILES #
|
||||||
|
# #
|
||||||
|
################################################
|
||||||
|
|
||||||
|
# By default, asset recipes convert files in `res/` into other files in `res/`
|
||||||
|
# This line causes assets not found in `res/` to be also looked for in `src/res/`
|
||||||
|
# "Source" assets can thus be safely stored there without `make clean` removing them
|
||||||
|
VPATH := $(SRCDIR)
|
||||||
|
|
||||||
|
# Define how to compress files using the PackBits16 codec
|
||||||
|
# Compressor script requires Python 3
|
||||||
|
$(RESDIR)/%.pb16: $(SRCDIR)/tools/pb16.py $(RESDIR)/%
|
||||||
|
$^ $@
|
||||||
|
|||||||
Reference in New Issue
Block a user