Skip to content

Commit

Permalink
Dev: remove ICU Android from toolchain
Browse files Browse the repository at this point in the history
  • Loading branch information
andriydruk committed Dec 23, 2024
1 parent 8c10bd5 commit bd0c916
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 65 deletions.
64 changes: 3 additions & 61 deletions .github/workflows/build-android-toolchain.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,52 +98,6 @@ jobs:
name: swift-android-x86_64
path: ~/out/swift-android/lib


build-icu-android:
runs-on: ubuntu-20.04
container: ubuntu:focal

steps:
- uses: actions/checkout@v1
- name: Cache ICU
id: cache-icu
uses: actions/cache@v2
with:
path: |
~/icu/build-aarch64-linux-android/lib
~/icu/build-armv7a-linux-androideabi/lib
~/icu/build-x86_64-linux-android/lib
~/icu/build-i686-linux-android/lib
key: icu-73-2-r5
- name: Install dependencies
if: steps.cache-icu.outputs.cache-hit != 'true'
run: ./build/Linux/000-install-dependencies.sh
- name: Install NDK
if: steps.cache-icu.outputs.cache-hit != 'true'
run: ./build/Linux/002-install-ndk.sh
- name: Define build folders
if: steps.cache-icu.outputs.cache-hit != 'true'
run: ./build/Linux/003-define-build-folders.sh
- name: Build ICU
if: steps.cache-icu.outputs.cache-hit != 'true'
run: ./build/Linux/040-build-icu.sh
- uses: actions/upload-artifact@v4
with:
name: icu-arm64-v8a
path: ~/icu/build-aarch64-linux-android/lib
- uses: actions/upload-artifact@v4
with:
name: icu-armeabi-v7a
path: ~/icu/build-armv7a-linux-androideabi/lib
- uses: actions/upload-artifact@v4
with:
name: icu-x86_64
path: ~/icu/build-x86_64-linux-android/lib
- uses: actions/upload-artifact@v4
with:
name: icu-x86
path: ~/icu/build-i686-linux-android/lib


build-openssl-android:
runs-on: ubuntu-20.04
Expand Down Expand Up @@ -305,7 +259,7 @@ jobs:


build-swift-corelibs-android-arm-64:
needs: [build-icu-android, build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-arm-64]
needs: [build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-arm-64]
runs-on: ubuntu-20.04
container: ubuntu:focal

Expand All @@ -317,10 +271,6 @@ jobs:
run: ./build/Linux/002-install-ndk.sh
- name: Define build folders
run: ./build/Linux/003-define-build-folders.sh
- uses: actions/download-artifact@v4
with:
name: icu-arm64-v8a
path: ~/icu/build-aarch64-linux-android
- uses: actions/download-artifact@v4
with:
name: openssl-arm64-v8a
Expand Down Expand Up @@ -355,7 +305,7 @@ jobs:
path: ~/swift-toolchain/usr/lib/swift-aarch64

build-swift-corelibs-android-armeabi-v7a:
needs: [build-icu-android, build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-armeabi-v7a]
needs: [build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-armeabi-v7a]
runs-on: ubuntu-20.04
container: ubuntu:focal

Expand All @@ -367,10 +317,6 @@ jobs:
run: ./build/Linux/002-install-ndk.sh
- name: Define build folders
run: ./build/Linux/003-define-build-folders.sh
- uses: actions/download-artifact@v4
with:
name: icu-armeabi-v7a
path: ~/icu/build-armv7a-linux-androideabi
- uses: actions/download-artifact@v4
with:
name: openssl-armeabi-v7a
Expand Down Expand Up @@ -401,7 +347,7 @@ jobs:
path: ~/swift-toolchain/usr/lib/swift-armv7

build-swift-corelibs-android-x86_64:
needs: [build-icu-android, build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-x86_64]
needs: [build-openssl-android, build-curl-android, build-libxml-android, build-swift-android-x86_64]
runs-on: ubuntu-20.04
container: ubuntu:focal

Expand All @@ -413,10 +359,6 @@ jobs:
run: ./build/Linux/002-install-ndk.sh
- name: Define build folders
run: ./build/Linux/003-define-build-folders.sh
- uses: actions/download-artifact@v4
with:
name: icu-x86_64
path: ~/icu/build-x86_64-linux-android
- uses: actions/download-artifact@v4
with:
name: openssl-x86_64
Expand Down
4 changes: 0 additions & 4 deletions build/Linux/052-build-corelibs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
set -ex

source $HOME/.build_env
export ICU_VERSION=73

self_dir=$(realpath $(dirname $0))

Expand All @@ -16,7 +15,6 @@ dispatch_build_dir=/tmp/swift-corelibs-libdispatch-$arch
foundation_build_dir=/tmp/foundation-$arch
xctest_build_dir=/tmp/xctest-$arch

icu_libs=$ICU_LIBS/build-$ndk_arch
openssl_libs=$OPENSSL_LIBS/$arch
curl_libs=$CURL_LIBS/$arch
libxml_libs=$LIBXML_LIBS/$arch
Expand Down Expand Up @@ -100,13 +98,11 @@ dst_libs=$HOME/swift-toolchain/usr/lib/swift-$swift_arch/android

rsync -av $ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/$clang_arch/libc++_shared.so $dst_libs

rsync -av $icu_libs/*$ICU_VERSION.so $dst_libs
rsync -av $openssl_libs/lib/libcrypto.a $dst_libs
rsync -av $openssl_libs/lib/libssl.a $dst_libs
rsync -av $curl_libs/lib/libcurl.* $dst_libs
rsync -av $libxml_libs/lib/libxml2.* $dst_libs

cp -r $icu_libs/include/unicode $swift_include
cp -r $openssl_libs/include/openssl $swift_include
cp -r $curl_libs/include/curl $swift_include
cp -r $libxml_libs/include/libxml2/libxml $swift_include

0 comments on commit bd0c916

Please sign in to comment.