diff --git a/phases/16-libxml2.sh b/phases/16-libxml2.sh index 8a4c315..16af02d 100755 --- a/phases/16-libxml2.sh +++ b/phases/16-libxml2.sh @@ -15,19 +15,19 @@ fi . "$ROOT_DIR"/scripts/toolchain.sh -echo -e "\n### Running autogen" -NOCONFIGURE=1 ./autogen.sh - -echo -e "\n### Running configure" -./configure \ - --host=${ANDROID_TARGET} \ - --prefix="${INSTALL_PREFIX}" \ - --without-python \ - --without-lzma \ - --with-icu \ - --disable-shared \ - `# specify include dir to enable finding libiconv and ICU` \ - CFLAGS="${CFLAGS} -I${INSTALL_PREFIX}/include" \ +echo -e "\n### Running cmake" +mkdir -p build-${ABI_NAME} +cd build-${ABI_NAME} + +${CMAKE} .. \ + ${CMAKE_OPTIONS} \ + -DBUILD_SHARED_LIBS=NO \ + -DLIBXML2_WITH_LZMA=NO \ + -DLIBXML2_WITH_PYTHON=NO \ + -DLIBXML2_WITH_ZLIB=NO \ + -DLIBXML2_WITH_TESTS=NO \ + -DLIBXML2_WITH_PROGRAMS=NO \ + -DLIBXML2_WITH_ICU=YES \ echo -e "\n### Building" make -j${MAKE_JOBS} diff --git a/phases/17-libxslt.sh b/phases/17-libxslt.sh index d95b8e4..75409b5 100755 --- a/phases/17-libxslt.sh +++ b/phases/17-libxslt.sh @@ -15,18 +15,16 @@ fi . "$ROOT_DIR"/scripts/toolchain.sh -echo -e "\n### Running autogen" -NOCONFIGURE=1 ./autogen.sh - -echo -e "\n### Running configure" -./configure \ - --host=${ANDROID_TARGET} \ - --prefix="${INSTALL_PREFIX}" \ - --without-python \ - --without-crypto \ - --disable-shared \ - `# specify include dir to enable finding libiconv and ICU (from libxml headers)` \ - CFLAGS="${CFLAGS} -I${INSTALL_PREFIX}/include" \ +echo -e "\n### Running cmake" +mkdir -p build-${ABI_NAME} +cd build-${ABI_NAME} + +${CMAKE} .. \ + ${CMAKE_OPTIONS} \ + -DBUILD_SHARED_LIBS=NO \ + -DLIBXSLT_WITH_PYTHON=NO \ + -DLIBXSLT_WITH_TESTS=NO \ + -DLIBXSLT_WITH_PROGRAMS=NO \ echo -e "\n### Building" make -j${MAKE_JOBS} diff --git a/phases/19-libcurl.sh b/phases/19-libcurl.sh index 2efb180..debbc7b 100755 --- a/phases/19-libcurl.sh +++ b/phases/19-libcurl.sh @@ -24,7 +24,6 @@ ${CMAKE} .. \ -DBUILD_SHARED_LIBS=YES \ -DBUILD_CURL_EXE=NO \ -DCURL_CA_BUNDLE=NONE `# disable CA bundle path, needs to be read at runtime from app bundle` \ - -DCMAKE_FIND_ROOT_PATH=${INSTALL_PREFIX} `# make CMake look for OpenSSL in installation directory` \ -DUSE_LIBIDN2=NO `# Prevent accidental detection of an idn2 installation` \ -DBUILD_LIBCURL_DOCS=NO \ -DBUILD_MISC_DOCS=NO \ diff --git a/scripts/toolchain.sh b/scripts/toolchain.sh index 0833f8a..78bf9cd 100755 --- a/scripts/toolchain.sh +++ b/scripts/toolchain.sh @@ -67,6 +67,7 @@ CMAKE_OPTIONS=" \ -DCMAKE_BUILD_TYPE=${BUILD_TYPE} \ -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE} \ -DCMAKE_FIND_USE_CMAKE_PATH=false \ + -DCMAKE_FIND_ROOT_PATH=${INSTALL_PREFIX} \ -DANDROID_ABI=${ABI_NAME} \ -DANDROID_NDK=${ANDROID_NDK_ROOT} \ -DANDROID_PLATFORM=android-${ANDROID_API_LEVEL} \