mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-09 13:12:37 -05:00
Prevent spurious recompiles on account of changed version.
After a local commit, any file that included version.h would have to be recompiled on account of the changed version string. This changes version.h in the build directory to rbversion.h and includes the preprocessor macro from rbversion.h in firmware/common/version.c so that only that one file needs to be recompiled after a local commit rather than a whole slew of them. Change-Id: I900d97e3a24a0610698283416d97b4fa3a3a2cf6 Reviewed-on: http://gerrit.rockbox.org/937 Reviewed-by: Michael Sevakis <jethead71@rockbox.org> Tested: Michael Sevakis <jethead71@rockbox.org>
This commit is contained in:
parent
25f73d6207
commit
21e2b595c2
4 changed files with 37 additions and 12 deletions
|
|
@ -47,11 +47,11 @@ $(BUILDDIR)/sysfont.o: $(SYSFONT) $(BUILDDIR)/sysfont.h
|
|||
$(call PRINTS,CC $(subst $(ROOTDIR)/,,$(BUILDDIR)/sysfont.c))$(CC) $(CFLAGS) -c $(BUILDDIR)/sysfont.c -o $@
|
||||
|
||||
SVNVERSION:=$(shell $(TOOLSDIR)/version.sh $(ROOTDIR))
|
||||
OLDSVNVERSION:=$(shell grep 'RBVERSION' $(BUILDDIR)/version.h 2>/dev/null|cut -d '"' -f 2 || echo "NOREVISION")
|
||||
OLDSVNVERSION:=$(shell grep 'RBVERSION' $(BUILDDIR)/rbversion.h 2>/dev/null|cut -d '"' -f 2 || echo "NOREVISION")
|
||||
|
||||
ifneq ($(SVNVERSION),$(OLDSVNVERSION))
|
||||
.PHONY: $(BUILDDIR)/version.h
|
||||
.PHONY: $(BUILDDIR)/rbversion.h
|
||||
endif
|
||||
|
||||
$(BUILDDIR)/version.h:
|
||||
$(BUILDDIR)/rbversion.h:
|
||||
$(call PRINTS,GEN $(@F))$(TOOLSDIR)/genversion.sh $(BUILDDIR) $(TOOLSDIR)/version.sh $(ROOTDIR)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue