From bc3f9c1b71bdf15e80e80b6aa41a4e39a258ba82 Mon Sep 17 00:00:00 2001 From: Dominik Riebeling Date: Sun, 29 May 2011 17:23:52 +0000 Subject: [PATCH] Add source tree version into AndroidManifest.xml Use the source tree version as versionName string. As result the Android Settings menu will now show that version instead of a rather unhelpful "1.0". git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29929 a1c6a512-1295-4272-9138-f99709370657 --- android/android.make | 7 ++++++- tools/root.make | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/android/android.make b/android/android.make index 109eb61d2e..d68a81635a 100644 --- a/android/android.make +++ b/android/android.make @@ -33,7 +33,8 @@ ZIPALIGN=$(ANDROID_SDK_PATH)/tools/zipalign KEYSTORE=$(HOME)/.android/debug.keystore ADB=$(ANDROID_SDK_PATH)/platform-tools/adb -MANIFEST := $(ANDROID_DIR)/AndroidManifest.xml +MANIFEST := $(BUILDDIR)/AndroidManifest.xml +MANIFEST_SRC := $(ANDROID_DIR)/AndroidManifest.xml R_JAVA := $(BUILDDIR)/gen/$(PACKAGE_PATH)/R.java R_OBJ := $(BUILDDIR)/bin/$(PACKAGE_PATH)/R.class @@ -64,6 +65,10 @@ CLEANOBJS += bin gen libs data JAVAC_OPTS += -implicit:none -classpath $(ANDROID_PLATFORM)/android.jar:$(BUILDDIR)/bin +.PHONY: +$(MANIFEST): $(MANIFEST_SRC) + $(call PRINTS,MANIFEST $(@F))sed -e 's/versionName="1.0"/versionName="$(SVNVERSION)"/' $(MANIFEST_SRC) > $(MANIFEST) + $(R_JAVA) $(AP_): $(MANIFEST) $(RES) | $(DIRS) $(call PRINTS,AAPT $(subst $(BUILDDIR)/,,$@))$(AAPT) package -f -m \ -J $(BUILDDIR)/gen -M $(MANIFEST) -S $(ANDROID_DIR)/res \ diff --git a/tools/root.make b/tools/root.make index 1ac5568316..9cf9eef1d0 100644 --- a/tools/root.make +++ b/tools/root.make @@ -148,7 +148,7 @@ clean:: $(LINKRAM) $(LINKROM) rockbox.elf rockbox.map rockbox.bin \ make.dep rombox.elf rombox.map rombox.bin rombox.ucl romstart.txt \ $(BINARY) $(FLASHFILE) uisimulator bootloader flash $(BOOTLINK) \ - rockbox.apk + rockbox.apk AndroidManifest.xml #### linking the binaries: ####