diff options
Diffstat (limited to 'apps/Makefile')
-rw-r--r-- | apps/Makefile | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/apps/Makefile b/apps/Makefile index 69de3a0f78..0b8f0ad304 100644 --- a/apps/Makefile +++ b/apps/Makefile | |||
@@ -90,6 +90,8 @@ $(DEPFILE): $(BITMAPLIBS) | |||
90 | 90 | ||
91 | dep: $(DEPFILE) | 91 | dep: $(DEPFILE) |
92 | 92 | ||
93 | features: $(OBJDIR)/features | ||
94 | |||
93 | build-codecs: | 95 | build-codecs: |
94 | $(SILENT)$(MAKE) -C codecs/lib OBJDIR=$(OBJDIR)/codecs/lib | 96 | $(SILENT)$(MAKE) -C codecs/lib OBJDIR=$(OBJDIR)/codecs/lib |
95 | $(SILENT)$(MAKE) -C codecs OBJDIR=$(OBJDIR)/codecs | 97 | $(SILENT)$(MAKE) -C codecs OBJDIR=$(OBJDIR)/codecs |
@@ -195,9 +197,22 @@ $(BUILDDIR)/rombox.iriver: $(OBJDIR)/rombox.bin | |||
195 | 197 | ||
196 | include $(TOOLSDIR)/make.inc | 198 | include $(TOOLSDIR)/make.inc |
197 | 199 | ||
198 | $(OBJDIR)/lang.o: lang/$(LANGUAGE).lang | 200 | # apps/features.txt is a file that (is preprocessed and) lists named features |
199 | @mkdir -p $(dir $@) | 201 | # based on defines in the config-*.h files. The named features will be passed |
200 | $(call PRINTS,GENLANG)perl -s $(TOOLSDIR)/genlang -p=$(BUILDDIR)/lang -t=$(ARCHOS) $< | 202 | # to genlang and thus (translated) phrases can be used based on those names. |
203 | # button.h is included for the HAS_BUTTON_HOLD define. | ||
204 | # | ||
205 | |||
206 | $(OBJDIR)/features: features.txt | ||
207 | $(SILENT)cat $< | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) \ | ||
208 | $(TARGET) $(DEFINES) $(EXTRA_DEFINES) -E -P -imacros "config.h" -imacros "button.h" - | \ | ||
209 | grep -v "^\#" | grep -v "^$$" > $@; \ | ||
210 | echo "" >/dev/null | ||
211 | |||
212 | $(OBJDIR)/lang.o: lang/$(LANGUAGE).lang $(OBJDIR)/features | ||
213 | $(SILENT)mkdir -p `dirname $@` | ||
214 | $(SILENT)for f in `cat $(OBJDIR)/features`; do feat="$$feat:$$f" ; done; \ | ||
215 | perl -s $(TOOLSDIR)/genlang -p=$(BUILDDIR)/lang -t=$(ARCHOS):$$feat $< | ||
201 | $(call PRINTS,CC lang.c)$(CC) $(CFLAGS) -c $(BUILDDIR)/lang.c -o $@ | 216 | $(call PRINTS,CC lang.c)$(CC) $(CFLAGS) -c $(BUILDDIR)/lang.c -o $@ |
202 | 217 | ||
203 | clean: | 218 | clean: |