From a8ed339ba573e48b82d0fdda348a748e142f803d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Stenberg?= Date: Fri, 24 Sep 2010 12:03:15 +0000 Subject: Minor build script tweaks to make android auto-buildable. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28156 a1c6a512-1295-4272-9138-f99709370657 --- android/README | 20 +++++++++----------- android/android.make | 11 +++++------ 2 files changed, 14 insertions(+), 17 deletions(-) (limited to 'android') diff --git a/android/README b/android/README index 6c9d2ad..8f0a85c 100644 --- a/android/README +++ b/android/README @@ -16,22 +16,20 @@ compiling the java files will fail. * Build instructions -Use this as your build folder, using '../tools/configure' etc. - $ ../tools/configure # type 200, then chose A for android and your screen resolution - $ make +1. Create a separate build folder. Do not build in this source directory. +2. Run "../tools/configure". Choose target 200, then chose 'A' for Android + and input your screen resolution. -After the build finished, build the zip file which contains codecs and themes (the binary is a separate file): - $ make zip +3. Run "make" -Once you have the zip, pack it and the binary into the apk - $ make apk +4. Run "make zip". This has to be run the first time, and any time themes + or plugins have changed. Otherwise you may skip it. -Side note: You don't necessarily need to recreate the zip once you have it, only if you're unsure or if you know its content changed. -Not recreating it will save time because it's only unzipped on the device if it's newer than what's on the device +5. Run "make apk" -You can install that on your device or emulator with the following command: - $ $ANDROID_SDK_PATH/tools/adb install -r bin/Rockbox.apk +6. Optional. Install on your target/emulator, using the following command: + "$ANDROID_SDK_PATH/tools/adb install -r rockbox.apk" [1]: http://developer.android.com/sdk/index.html diff --git a/android/android.make b/android/android.make index f611d5d..492c012 100644 --- a/android/android.make +++ b/android/android.make @@ -41,11 +41,11 @@ JAVA_SRC := $(wildcard $(ANDROID_DIR)/src/$(PACKAGE_PATH)/*.java) JAVA_OBJ := $(call java2class,$(subst $(ANDROID)/src/$(PACKAGE_PATH),$(ANDROID)/bin/$(PACKAGE_PATH),$(JAVA_SRC))) LIBS := $(BINLIB_DIR)/$(BINARY) $(BINLIB_DIR)/libmisc.so -TEMP_APK := $(BUILDDIR)/bin/_Rockbox.apk -TEMP_APK2 := $(BUILDDIR)/bin/__Rockbox.apk +TEMP_APK := $(BUILDDIR)/bin/_rockbox.apk +TEMP_APK2 := $(BUILDDIR)/bin/__rockbox.apk DEX := $(BUILDDIR)/bin/classes.dex AP_ := $(BUILDDIR)/bin/resources.ap_ -APK := $(BUILDDIR)/bin/Rockbox.apk +APK := $(BUILDDIR)/rockbox.apk _DIRS := $(BUILDDIR)/___/$(PACKAGE_PATH) DIRS := $(subst ___,bin,$(_DIRS)) @@ -53,6 +53,8 @@ DIRS += $(subst ___,gen,$(_DIRS)) DIRS += $(subst ___,data,$(_DIRS)) DIRS += $(BUILDDIR)/libs/armeabi +CLEANOBJS += bin gen libs data + $(R_JAVA) $(AP_): $(MANIFEST) $(call PRINTS,AAPT $(subst $(BUILDDIR)/,,$@))$(AAPT) package -f -m \ -J $(BUILDDIR)/gen -M $(MANIFEST) -S $(ANDROID_DIR)/res \ @@ -106,6 +108,3 @@ $(DIRS): dirs: $(DIRS) apk: $(APK) - -clean:: - $(SILENT)rm -f $(BUILDDIR)/bin/$(PACKAGE_PATH)/*.class $(R_JAVA) $(TEMP_APK) $(TEMP_APK2) $(APK) $(DEX) $(BUILDDIR)/_rockbox.zip $(AP_) $(LIBS) -- cgit v1.1