From 35ffd5f71ee21d9f69103a1eaf1d6cef3faa1941 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sun, 5 Aug 2018 20:12:16 -0700 Subject: Android: add -quick flag to build.sh This allows us to skip all the checking / building of dependency libraries. This also allows us to pass extra arguments to the make command by separating them from the arguments to build.sh with '--'. This commit is easier to understand because it didn't increase the indent in the large block of code that is now only executed if we aren't in 'quick' mode. That will be fixed in the next commit that is whitespace only. Signed-off-by: Dirk Hohndel --- packaging/android/build.sh | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/packaging/android/build.sh b/packaging/android/build.sh index b39c7d9ae..79947ec85 100755 --- a/packaging/android/build.sh +++ b/packaging/android/build.sh @@ -41,6 +41,8 @@ ARCH=arm # Read build variables source subsurface/packaging/android/variables.sh +QUICK="" + while [ "$#" -gt 0 ] ; do case "$1" in Release|release) @@ -65,6 +67,14 @@ while [ "$#" -gt 0 ] ; do ARCH=$1 shift ;; + -quick) + QUICK="1" + shift + ;; + --) + shift + break + ;; *) echo "Unknown argument $1" exit 1 @@ -152,6 +162,11 @@ fi QMAKE=$QT5_ANDROID/android_armv7/bin/qmake $QMAKE -query +# if we are just doing a quick rebuild, don't bother with any of the dependencies + +if [ "$QUICK" = "" ] ; then + +# don't adjust indentation to make this a more reasonable commit # build google maps plugin "${SUBSURFACE_SOURCE}"/scripts/get-dep-lib.sh singleAndroid . googlemaps # find qmake @@ -322,6 +337,8 @@ if [ -e "$PREFIX/lib/libftdi1.so" ] ; then rm "$PREFIX"/lib/libftdi1.so* fi +fi # QUICK + pushd "$SUBSURFACE_SOURCE" git submodule update --recursive popd @@ -357,7 +374,9 @@ else SUBSURFACE_MOBILE=ON fi -if [ "$SUBSURFACE_MOBILE" = "ON" ] ; then +# if we are building Subsurface-mobile and this isn't just a quick +# rebuild, pull kirigami, icons, etc +if [ "$SUBSURFACE_MOBILE" = "ON" ] && [ "$QUICK" = "" ] ; then pushd "$SUBSURFACE_SOURCE" bash ./scripts/mobilecomponents.sh popd -- cgit v1.2.3-70-g09d2