From 0941096d9065fa072c99be0a2dd2c76e3e863806 Mon Sep 17 00:00:00 2001 From: Maksim Belov <45949002+artdeell@users.noreply.github.com> Date: Sat, 13 Jul 2024 21:45:20 +0300 Subject: [PATCH] Feat[freetype]: add freetype into build script --- ci_build_android.bash | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/ci_build_android.bash b/ci_build_android.bash index 0eac9de5d2..cb453dd206 100644 --- a/ci_build_android.bash +++ b/ci_build_android.bash @@ -42,6 +42,37 @@ if [ "$SKIP_LIBFFI" != "1" ]; then cp libffi/$NDK_TARGET-linux-android$NDK_SUFFIX/.libs/libffi.a $LWJGL_NATIVE/ fi +if [ "$SKIP_FREETYPE" != "1" ]; then + #!/bin/bash + export BUILD_FREETYPE_VERSION=2.13.2 + wget https://downloads.sourceforge.net/project/freetype/freetype2/$BUILD_FREETYPE_VERSION/freetype-$BUILD_FREETYPE_VERSION.tar.gz + tar xf freetype-$BUILD_FREETYPE_VERSION.tar.gz + rm freetype-$BUILD_FREETYPE_VERSION.tar.gz + cd freetype-$BUILD_FREETYPE_VERSION + + export CC=$NDK_TARGET-linux-android${NDK_SUFFIX}21-clang + + ./configure \ + --host=$TARGET \ + --prefix=`pwd`/build_android-$LWJGL_BUILD_ARCH \ + --without-zlib \ + --with-brotli=no \ + --with-png=no \ + --with-harfbuzz=no \ + --enable-static=no \ + --enable-shared=yes + + make -j4 + make install + + llvm-strip ./build_android-$LWJGL_BUILD_ARCH/lib/libfreetype.so + cp ./build_android-$LWJGL_BUILD_ARCH/lib/libfreetype.so $LWJGL_NATIVE + cd .. + rm -rf freetype-$BUILD_FREETYPE_VERSION + unset BUILD_FREETYPE_VERSION + unset CC +fi + # Download libraries POJAV_NATIVES="https://github.com/PojavLauncherTeam/PojavLauncher/raw/v3_openjdk/app_pojavlauncher/src/main/jniLibs/$NDK_ABI" wget -nc $POJAV_NATIVES/libopenal.so -P $LWJGL_NATIVE/openal