Path: blob/buildjre8/buildlibs.sh
861 views
#!/bin/bash1set -e2. setdevkitpath.sh3cd freetype-$BUILD_FREETYPE_VERSION45echo "Building Freetype"67if [[ "$BUILD_IOS" == "1" ]]; then8LDFLAGS=-"arch arm64 -isysroot $thesysroot -miphoneos-version-min=12.0"9export CC=$thecc10export CXX=$thecxx11./configure \12--host=$TARGET \13--prefix=${PWD}/build_android-${TARGET_SHORT} \14--enable-shared=no --enable-static=yes \15--without-zlib \16--with-brotli=no \17--with-png=no \18--with-harfbuzz=no \19"CFLAGS=-arch arm64 -pipe -std=c99 -Wno-trigraphs -fpascal-strings -Os -Wreturn-type -Wunused-variable -fmessage-length=0 -fvisibility=hidden -miphoneos-version-min=12.0 -I$thesysroot/usr/include/libxml2/ -isysroot $thesysroot -DByte=uint8_t" \20AR=/usr/bin/ar \21"LDFLAGS=$LDFLAGS" \22|| error_code=$?23namefreetype=build_android-${TARGET_SHORT}/lib/libfreetype24else25export PATH=$TOOLCHAIN/bin:$PATH26./configure \27--host=$TARGET \28--prefix=`pwd`/build_android-${TARGET_SHORT} \29--without-zlib \30--with-brotli=no \31--with-png=no \32--with-harfbuzz=no $EXTRA_ARGS \33|| error_code=$?34if [[ "$error_code" -ne 0 ]]; then35echo "\n\nCONFIGURE ERROR $error_code , config.log:"36cat config.log37exit $error_code38fi39fi4041CFLAGS=-fno-rtti CXXFLAGS=-fno-rtti make -j442make install4344if [[ -f "${namefreetype}.a" ]]; then45clang -fPIC -shared $LDFLAGS -lbz2 -Wl,-all_load ${namefreetype}.a -o ${namefreetype}.dylib46fi474849