mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-17 19:36:15 +00:00
iOS: fix handling of version option to build.sh
This makes it much more consistent and avoids a silly warning. Also some small README updates. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3a7b8d73d8
commit
6eca1b3ead
2 changed files with 10 additions and 6 deletions
|
@ -4,7 +4,7 @@ Tool repo to crosscompile subsurface for iOS
|
||||||
Dependencies:
|
Dependencies:
|
||||||
|
|
||||||
- This only works on a Mac
|
- This only works on a Mac
|
||||||
- XCode with iOS SDK and Qt5.9 or later
|
- XCode with iOS SDK and Qt5.13 or later
|
||||||
- cmake
|
- cmake
|
||||||
|
|
||||||
Follow the instruction in:
|
Follow the instruction in:
|
||||||
|
@ -19,7 +19,7 @@ note: this builds all dependencies and is only needed first time
|
||||||
it currently build for armv7 arm64 and x86_64 (simulator)
|
it currently build for armv7 arm64 and x86_64 (simulator)
|
||||||
|
|
||||||
1) cd <repo>/..
|
1) cd <repo>/..
|
||||||
2) Launch QtCreator and open subsurface/packaging/ios/Subsurface-mobile/Subsurface-mobile.pro
|
2) Launch QtCreator and open subsurface/packaging/ios/Subsurface-mobile.pro
|
||||||
3) Build Subsurface-mobile in QtCreator - you can build for the simulator and for
|
3) Build Subsurface-mobile in QtCreator - you can build for the simulator and for
|
||||||
a device and even deploy to a connected device.
|
a device and even deploy to a connected device.
|
||||||
|
|
||||||
|
@ -44,6 +44,6 @@ number, even though the sources have been recompiled which can be very
|
||||||
confusing.
|
confusing.
|
||||||
|
|
||||||
Do a simply version update by running:
|
Do a simply version update by running:
|
||||||
build.sh version
|
build.sh -version
|
||||||
and then rebuilding in Qt Creator
|
and then rebuilding in Qt Creator (or Xcode)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,6 @@
|
||||||
set -x
|
set -x
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
doVersion=$1
|
|
||||||
DEBUGRELEASE="Release"
|
DEBUGRELEASE="Release"
|
||||||
ARCHS="armv7 arm64 x86_64"
|
ARCHS="armv7 arm64 x86_64"
|
||||||
TARGET="iphoneos"
|
TARGET="iphoneos"
|
||||||
|
@ -13,6 +12,11 @@ TARGET2="Device"
|
||||||
while [[ $# -gt 0 ]] ; do
|
while [[ $# -gt 0 ]] ; do
|
||||||
arg="$1"
|
arg="$1"
|
||||||
case $arg in
|
case $arg in
|
||||||
|
-version)
|
||||||
|
# only update the version info without rebuilding
|
||||||
|
# this is useful when working with Xcode
|
||||||
|
versionOnly="1"
|
||||||
|
;;
|
||||||
-debug)
|
-debug)
|
||||||
# build for debugging
|
# build for debugging
|
||||||
DEBUGRELEASE="Debug"
|
DEBUGRELEASE="Debug"
|
||||||
|
@ -68,7 +72,7 @@ fi
|
||||||
# create Info.plist with the correct versions
|
# create Info.plist with the correct versions
|
||||||
cat Info.plist.in | sed "s/@MOBILE_VERSION@/$MOBILEVERSION/;s/@CANONICAL_VERSION@/$CANONICALVERSION/;s/@PRODUCT_BUNDLE_IDENTIFIER@/$BUNDLE/" > Info.plist
|
cat Info.plist.in | sed "s/@MOBILE_VERSION@/$MOBILEVERSION/;s/@CANONICAL_VERSION@/$CANONICALVERSION/;s/@PRODUCT_BUNDLE_IDENTIFIER@/$BUNDLE/" > Info.plist
|
||||||
|
|
||||||
if [ "$doVersion" = "version" ] ; then
|
if [ "$versionOnly" = "1" ] ; then
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue