mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
ios: add -all to build.sh
-all will build debug and release for the choosen architectures armv7,arm64,x86_64 without extra parameter and only x86_64 with -simulator Use -all to prebuild all 6 variants we support. Signed-off-by: Jan Iversen <jani@apache.org>
This commit is contained in:
parent
13b9c7a822
commit
abc3125b8e
1 changed files with 24 additions and 8 deletions
|
@ -6,7 +6,6 @@ set -e
|
||||||
|
|
||||||
doVersion=$1
|
doVersion=$1
|
||||||
DEBUGRELEASE="Release"
|
DEBUGRELEASE="Release"
|
||||||
DRCONFIG="release"
|
|
||||||
ARCHS="armv7 arm64 x86_64"
|
ARCHS="armv7 arm64 x86_64"
|
||||||
TARGET="iphoneos"
|
TARGET="iphoneos"
|
||||||
TARGET2="Device"
|
TARGET2="Device"
|
||||||
|
@ -17,7 +16,6 @@ while [[ $# -gt 0 ]] ; do
|
||||||
-debug)
|
-debug)
|
||||||
# build for debugging
|
# build for debugging
|
||||||
DEBUGRELEASE="Debug"
|
DEBUGRELEASE="Debug"
|
||||||
DRCONFIG="qml_debug"
|
|
||||||
;;
|
;;
|
||||||
-simulator)
|
-simulator)
|
||||||
# build for the simulator instead of for a device
|
# build for the simulator instead of for a device
|
||||||
|
@ -25,6 +23,10 @@ while [[ $# -gt 0 ]] ; do
|
||||||
TARGET="iphonesimulator"
|
TARGET="iphonesimulator"
|
||||||
TARGET2="simulator"
|
TARGET2="simulator"
|
||||||
;;
|
;;
|
||||||
|
-all)
|
||||||
|
# build both debug and release for all devices
|
||||||
|
DEBUGRELEASE="All"
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Unknown command line argument $arg"
|
echo "Unknown command line argument $arg"
|
||||||
;;
|
;;
|
||||||
|
@ -242,10 +244,24 @@ done
|
||||||
# in order to be able to use xcode without going through Qt Creator
|
# in order to be able to use xcode without going through Qt Creator
|
||||||
# call qmake directly
|
# call qmake directly
|
||||||
|
|
||||||
BUILDX=build-Subsurface-mobile-Qt_$(echo ${QT_VERSION} | tr . _)_for_iOS-${DEBUGRELEASE}
|
if [ "$DEBUGRELEASE" = "All" ] ; then
|
||||||
mkdir -p ${BUILDX}
|
BUILD_LOOP="Debug Release"
|
||||||
cd ${BUILDX}
|
else
|
||||||
${IOS_QT}/${QT_VERSION}/ios/bin/qmake ../Subsurface-mobile.pro \
|
BUILD_LOOP=$DEBUGRELEASE
|
||||||
-spec macx-ios-clang CONFIG+=$TARGET CONFIG+=$TARGET2 CONFIG+=$DRCONFIG
|
fi
|
||||||
|
for BUILD_NOW in $BUILD_LOOP; do
|
||||||
|
echo "Building for $BUILD_NOW"
|
||||||
|
if [ "$BUILD_NOW" == "Debug" ] ; then
|
||||||
|
DRCONFIG="qml_debug"
|
||||||
|
else
|
||||||
|
DRCONFIG="release"
|
||||||
|
fi
|
||||||
|
BUILDX=build-Subsurface-mobile-Qt_$(echo ${QT_VERSION} | tr . _)_for_iOS-${BUILD_NOW}
|
||||||
|
mkdir -p ${BUILDX}
|
||||||
|
pushd ${BUILDX}
|
||||||
|
${IOS_QT}/${QT_VERSION}/ios/bin/qmake ../Subsurface-mobile.pro \
|
||||||
|
-spec macx-ios-clang CONFIG+=$TARGET CONFIG+=$TARGET2 CONFIG+=$DRCONFIG
|
||||||
|
|
||||||
make qmake_all
|
make qmake_all
|
||||||
|
popd
|
||||||
|
done
|
||||||
|
|
Loading…
Add table
Reference in a new issue