Skip to content

Commit

Permalink
workaround compatibility of CMake 3.25 and later with ancient CMake
Browse files Browse the repository at this point in the history
  • Loading branch information
Fsu0413 committed Jan 30, 2024
1 parent b2ebb22 commit 5eb56dd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -315,15 +315,19 @@ jobs:
- arch: "armeabi-v7a"
platform: "16"
OPENSSL_BUILD_PLATFORM: android-armeabi
CMAKE_25_LATER_WORKAROUND:
- arch: "x86"
platform: "16"
OPENSSL_BUILD_PLATFORM: android-x86
CMAKE_25_LATER_WORKAROUND:
- arch: "arm64-v8a"
platform: "21"
OPENSSL_BUILD_PLATFORM: android64-aarch64
CMAKE_25_LATER_WORKAROUND:
- arch: "x86_64"
platform: "21"
OPENSSL_BUILD_PLATFORM: linux-x86_64
CMAKE_25_LATER_WORKAROUND: -DCMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX=64
continue-on-error: true
runs-on: ubuntu-latest
name: "build-Android-${{ matrix.toolchain.arch }}"
Expand Down Expand Up @@ -352,7 +356,7 @@ jobs:
unset ANDROID_HOME ANDROID_NDK ANDROID_NDK_HOME ANDROID_NDK_LATEST_HOME ANDROID_NDK_ROOT ANDROID_SDK_ROOT || :
mkdir -p "build"
cd "build"
cmake -GNinja -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/android-ndk-r17c/build/cmake/android.toolchain.cmake" -DANDROID_ABI=${{ matrix.toolchain.arch }} -DANDROID_PLATFORM=android-${{ matrix.toolchain.platform }} -DANDROID_TOOLCHAIN=gcc -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="${{ github.workspace }}/openssl${{ env.FS_OPENSSL_VERSION_STR }}-${{ env.FS_OPENSSL_PACKAGE_STR }}" -DOPENSSL_ASM=ON -DOPENSSL_ZLIB=ON -DOPENSSL_THREADS=ON "${{ github.workspace }}/openssl-externalCMake"
cmake -GNinja -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}/android-ndk-r17c/build/cmake/android.toolchain.cmake" ${{ matrix.toolchain.CMAKE_25_LATER_WORKAROUND }} -DANDROID_ABI=${{ matrix.toolchain.arch }} -DANDROID_PLATFORM=android-${{ matrix.toolchain.platform }} -DANDROID_TOOLCHAIN=gcc -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX="${{ github.workspace }}/openssl${{ env.FS_OPENSSL_VERSION_STR }}-${{ env.FS_OPENSSL_PACKAGE_STR }}" -DOPENSSL_ASM=ON -DOPENSSL_ZLIB=ON -DOPENSSL_THREADS=ON "${{ github.workspace }}/openssl-externalCMake"
cmake --build . --parallel
cmake --build . --parallel -t package
- uses: actions/upload-artifact@v4
Expand Down

0 comments on commit 5eb56dd

Please sign in to comment.