diff options
author | Riza Sulistyo <riza@teluu.com> | 2014-04-30 02:37:00 +0000 |
---|---|---|
committer | Riza Sulistyo <riza@teluu.com> | 2014-04-30 02:37:00 +0000 |
commit | 2e343a7b0b115a3ec1b45a36ffad46ac64ea72a9 (patch) | |
tree | edb92925c914b468bf1926dbdb3b315925241149 | |
parent | 512018a09d47866fe408290199338dda9000f11b (diff) |
Re #1749: Update configure-android to support intel build.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@4828 74dad513-b988-da41-8d7b-12977e46ad98
-rwxr-xr-x | configure-android | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/configure-android b/configure-android index 02298a97..37432477 100755 --- a/configure-android +++ b/configure-android @@ -8,7 +8,8 @@ if test "$*" = "--help" -o "$*" = "-h"; then echo "" echo "where:" echo " --use-ndk-cflags Optional parameter to use the same compilation flags" - echo " as the one used by ndk-build" + echo " as the one used by ndk-build. Android NDK r9 or later" + echo " is required when using this option." echo " OPTIONS Other options that will be passed directly to" echo " ./aconfigure script. Run ./aconfigure --help" echo " for more info." @@ -63,7 +64,7 @@ if test "$1" = "--use-ndk-cflags"; then if test "x${IGNORE_CFLAGS}" = "x"; then IGNORE_CFLAGS="\-M\|\-f*stack\|\-f*alias" fi - for i in `${ANDROID_NDK_ROOT}/ndk-build -n -C ${ANDROID_NDK_ROOT}/samples/hello-jni NDK_LOG=1 APP_PLATFORM=${APP_PLATFORM} APP_ABI=${TARGET_ABI}`; do + for i in `${ANDROID_NDK_ROOT}/ndk-build -n -C ${ANDROID_NDK_ROOT}/samples/hello-jni NDK_TOOLCHAIN_VERSION=4.8 NDK_LOG=1 APP_PLATFORM=${APP_PLATFORM} APP_ABI=${TARGET_ABI}`; do if test "x${NDK_CXX}" != "x" -a "$i" = "-o"; then break; fi # Parse NDK CXXFLAGS @@ -99,7 +100,7 @@ if test "$1" = "--use-ndk-cflags"; then export RANLIB=`echo ${NDK_CXX}|sed 's/-g++/-ranlib/'`; export LDFLAGS="${LDFLAGS} -nostdlib -L${ANDROID_SYSROOT}/usr/lib/" - export LIBS="${LIBS} -lc -lgcc" + export LIBS="${LIBS} -lc -lgcc -ldl" export CFLAGS="${NDK_CFLAGS} ${CFLAGS}" export CPPFLAGS="${CFLAGS} -fexceptions -frtti" export CXXFLAGS="${NDK_CXXFLAGS} -fexceptions -frtti" @@ -137,14 +138,14 @@ fi # gnustl STDCPP_TC_VER=`ls -d ${ANDROID_NDK_ROOT}/sources/cxx-stl/gnu-libstdc++/[0-9]* | sort -gr | head -1` -STDCPP_CFLAGS="-I${STDCPP_TC_VER}/include -I${STDCPP_TC_VER}/libs/armeabi/include" +STDCPP_CFLAGS="-I${STDCPP_TC_VER}/include -I${STDCPP_TC_VER}/libs/${TARGET_ABI}/include" STDCPP_LIBS="${ANDROID_SYSROOT}/usr/lib/crtbegin_so.o -lgnustl_static" -STDCPP_LDFLAGS="-L${STDCPP_TC_VER}/libs/armeabi" +STDCPP_LDFLAGS="-L${STDCPP_TC_VER}/libs/${TARGET_ABI}/" # stlport #STDCPP_CFLAGS="-I${ANDROID_NDK_ROOT}/sources/cxx-stl/stlport/stlport" #STDCPP_LIBS="${ANDROID_SYSROOT}/usr/lib/crtbegin_so.o -lstlport_static -ldl" -#STDCPP_LDFLAGS="-L${ANDROID_NDK_ROOT}/sources/cxx-stl/stlport/libs/armeabi" +#STDCPP_LDFLAGS="-L${ANDROID_NDK_ROOT}/sources/cxx-stl/stlport/libs/${TARGET_ABI}" export CFLAGS="${CFLAGS} ${STDCPP_CFLAGS}" export LIBS="${STDCPP_LIBS} ${LIBS}" |