summaryrefslogtreecommitdiff
path: root/configure-iphone
diff options
context:
space:
mode:
authorLiong Sauw Ming <ming@teluu.com>2011-10-17 07:22:45 +0000
committerLiong Sauw Ming <ming@teluu.com>2011-10-17 07:22:45 +0000
commit4f500d28bd2747925afb868755e0b4c8567dc5e0 (patch)
tree5f2bb6b200d1aa52a6d338ab5fce5a40a48064b5 /configure-iphone
parent8eee3eb1e69ace9d26463b843a932edfd6a16c12 (diff)
Closed #1389: Add support for iOS 5 build
git-svn-id: http://svn.pjsip.org/repos/pjproject/branches/1.x@3818 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'configure-iphone')
-rwxr-xr-xconfigure-iphone35
1 files changed, 22 insertions, 13 deletions
diff --git a/configure-iphone b/configure-iphone
index 6f7a281f..29dfcbc2 100755
--- a/configure-iphone
+++ b/configure-iphone
@@ -71,20 +71,29 @@ fi
# full path as it's not normally in user's PATH
if test "${CC}" = ""; then
- for archpath in `ls -d ${SDKPATH}/usr/lib/gcc/arm-apple-darwin*`; do
- archname=`basename ${archpath}`
- for gccver in `ls ${archpath}`; do
- gccpath="${DEVPATH}/usr/bin/${archname}-gcc-${gccver}"
- if test -e ${gccpath}; then
- export CC="${gccpath}"
-# break
- fi
- done
- if test ! "${CC}" = ""; then
- echo "$F: CC is not specified, choosing ${CC}"
- break
+ # Try to use llvm-gcc if available
+ gccpath="${DEVPATH}/usr/bin/llvm-gcc"
+ if test -e ${gccpath}; then
+ export CC="${gccpath}"
+
+ if test "${ARCH}" = ""; then
+ export ARCH="-arch armv7"
+ echo "$F: ARCH is not specified, choosing ${ARCH}"
fi
- done
+ else
+ for archpath in `ls -d ${SDKPATH}/usr/lib/gcc/arm-apple-darwin*`; do
+ archname=`basename ${archpath}`
+ for gccver in `ls ${archpath}`; do
+ gccpath="${DEVPATH}/usr/bin/${archname}-gcc-${gccver}"
+ if test -e ${gccpath}; then
+ export CC="${gccpath}"
+ fi
+ done
+ done
+ fi
+ if test ! "${CC}" = ""; then
+ echo "$F: CC is not specified, choosing ${CC}"
+ fi
fi
if test "${CC}" = ""; then