summaryrefslogtreecommitdiff
path: root/platform/ios/build_libs.sh
diff options
context:
space:
mode:
authorfredrossperry <fredrossperry@gmail.com>2015-12-10 17:51:36 -0800
committerfredrossperry <fredrossperry@gmail.com>2015-12-15 17:26:23 -0800
commitbce2e182f1036ab2c438c48e0f499a2ae5d86800 (patch)
treedadf0ba40a9b44e1dd3eabba70cd2a63b8a81922 /platform/ios/build_libs.sh
parent7d60c7e05cb6cead6d91d938dfbb42a1e04438ee (diff)
downloadmupdf-bce2e182f1036ab2c438c48e0f499a2ae5d86800.tar.xz
muPDF iOS app: add bitcode and UIRequiresFullScreen
Starting with Xcode 7, bit code is enabled by default. This change enables it in the static libraries that are linked, by adding the appropriate compiler switch. Also added UIRequiresFullScreen to the plist; this seems to have no ill effect when uing XCode 6. <log></log>
Diffstat (limited to 'platform/ios/build_libs.sh')
-rw-r--r--platform/ios/build_libs.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/platform/ios/build_libs.sh b/platform/ios/build_libs.sh
index 77d1406a..cae76750 100644
--- a/platform/ios/build_libs.sh
+++ b/platform/ios/build_libs.sh
@@ -20,6 +20,17 @@ do
FLAGS="$FLAGS -arch $A"
done
+# add bitcode for Xcode 7 and up
+XCODE_VER=`xcodebuild -version | head -1`
+ARRAY=(${XCODE_VER// / })
+XCODE_VER_NUM=${ARRAY[1]}
+ARRAY=(${XCODE_VER_NUM//./ })
+MAJOR=${ARRAY[0]}
+if [ "$MAJOR" -ge "7" ]
+then
+ FLAGS="$FLAGS -fembed-bitcode"
+fi
+
OUT=build/$build-$OS-$(echo $ARCHS | tr ' ' '-')
echo Compiling libraries for $ARCHS.