summaryrefslogtreecommitdiff
path: root/standalone
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-11-26 13:24:24 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-11-26 13:24:24 -0400
commit8b79b8f3acdfc94233dc6f389013168d6a4d5013 (patch)
tree574c6bc463909d1c3056f735f261376097ad2479 /standalone
parent01c0042f39068e43443e667edbde15205f738608 (diff)
2 android bug fixes
Diffstat (limited to 'standalone')
-rw-r--r--standalone/android/Makefile8
1 files changed, 7 insertions, 1 deletions
diff --git a/standalone/android/Makefile b/standalone/android/Makefile
index d80d568db..f5cd67b26 100644
--- a/standalone/android/Makefile
+++ b/standalone/android/Makefile
@@ -15,6 +15,8 @@ GIT_ANNEX_ANDROID_SOURCETREE?=$(HOME)/.android/git-annex-sourcetree
GITTREE=$(GIT_ANNEX_ANDROID_SOURCETREE)/git/installed-tree
+VER=$(shell perl -e '$$_=<>;print m/\((.*?)\)/'<../../CHANGELOG)
+
build: start
if [ ! -e "$(GIT_ANNEX_ANDROID_SOURCETREE)" ]; then $(MAKE) source; fi
$(MAKE) $(GIT_ANNEX_ANDROID_SOURCETREE)/openssl/build-stamp
@@ -25,6 +27,8 @@ build: start
$(MAKE) $(GIT_ANNEX_ANDROID_SOURCETREE)/git/build-stamp
$(MAKE) $(GIT_ANNEX_ANDROID_SOURCETREE)/term/build-stamp
+ perl -i -pe 's/(android:versionName=)"[^"]+"/$$1"'$(VER)'"/' $(GIT_ANNEX_ANDROID_SOURCETREE)/term/AndroidManifest.xml
+
# Debug build because it does not need signing keys.
cd $(GIT_ANNEX_ANDROID_SOURCETREE)/term && tools/build-debug
@@ -76,10 +80,12 @@ build: start
mkdir -p ../../tmp/4.0 ../../tmp/4.3
cp ../../tmp/androidtree/dist/build/git-annex/4.3/git-annex $(GIT_ANNEX_ANDROID_SOURCETREE)/term/libs/armeabi/lib.git-annex.so
+ arm-linux-androideabi-strip --strip-unneeded --remove-section=.comment --remove-section=.note $(GIT_ANNEX_ANDROID_SOURCETREE)/term/libs/armeabi/lib.git-annex.so
cd $(GIT_ANNEX_ANDROID_SOURCETREE)/term && ant debug
cp $(GIT_ANNEX_ANDROID_SOURCETREE)/term/bin/Term-debug.apk ../../tmp/4.3/git-annex.apk
-
+
cp ../../tmp/androidtree/dist/build/git-annex/4.0/git-annex $(GIT_ANNEX_ANDROID_SOURCETREE)/term/libs/armeabi/lib.git-annex.so
+ arm-linux-androideabi-strip --strip-unneeded --remove-section=.comment --remove-section=.note $(GIT_ANNEX_ANDROID_SOURCETREE)/term/libs/armeabi/lib.git-annex.so
cd $(GIT_ANNEX_ANDROID_SOURCETREE)/term && ant debug
cp $(GIT_ANNEX_ANDROID_SOURCETREE)/term/bin/Term-debug.apk ../../tmp/4.0/git-annex.apk