]> sigrok.org Git - sigrok-util.git/commitdiff
sigrok-cross-android: Strip shared libs to reduce APK size.
authorUwe Hermann <redacted>
Fri, 31 Oct 2014 17:53:16 +0000 (18:53 +0100)
committerUwe Hermann <redacted>
Fri, 31 Oct 2014 17:53:16 +0000 (18:53 +0100)
This reduces the APK size from ca. 109MB to ca. 18MB.

cross-compile/android/sigrok-cross-android

index 2bc0eb26cd22a4bc63478628e1685c629a1d69f0..a37f2629c724a7cf301dea95a3d0388c937342d4 100755 (executable)
@@ -370,11 +370,16 @@ make $PARALLEL V=1
 make install
 cd ..
 
+# Strip all shared libs to reduce size.
+find $PREFIX -iname "*.so" -exec ${TOOLCHAIN_TRIPLET}-strip -S {} \;
+
 # PulseView
 $GIT_CLONE git://sigrok.org/pulseview
 cd pulseview
 cmake $CM -DANDROID_STL_PATH=${ANDROID_NDK}/sources/cxx-stl .
 make $PARALLEL VERBOSE=1
+make install
+${TOOLCHAIN_TRIPLET}-strip -S libs/$TARGET_ARCH/libpulseview.so
 cd android
 "${ANDROID_SDK}/tools/android" update project -p . -t android-14 -n PulseView
 ant debug