File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3737 run : swift build -c ${{ matrix.config }}
3838 - name : Test
3939 run : swift test -c ${{ matrix.config }}
40+
41+ android :
42+ name : Android
43+ runs-on : macos-15
44+ strategy :
45+ fail-fast : false
46+ matrix :
47+ config : ["debug", "release"]
48+ env :
49+ SWIFT_VERSION : " 6.3.2"
50+ ANDROID_NDK_VERSION : " 27.2.12479018"
51+ steps :
52+ - name : Checkout
53+ uses : actions/checkout@v4
54+ - name : Install Swift
55+ uses : swift-actions/setup-swift@v2
56+ with :
57+ swift-version : ${{ env.SWIFT_VERSION }}
58+ - name : Install Android NDK
59+ run : $ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager --install "ndk;${{ env.ANDROID_NDK_VERSION }}"
60+ - name : Install Swift SDK for Android
61+ run : |
62+ curl -L -o android-sdk.artifactbundle.tar.gz "https://download.swift.org/swift-${{ env.SWIFT_VERSION }}-release/android-sdk/swift-${{ env.SWIFT_VERSION }}-RELEASE/swift-${{ env.SWIFT_VERSION }}-RELEASE_android.artifactbundle.tar.gz"
63+ CHECKSUM=$(swift package compute-checksum android-sdk.artifactbundle.tar.gz)
64+ swift sdk install android-sdk.artifactbundle.tar.gz --checksum "$CHECKSUM"
65+ ANDROID_NDK_HOME="$ANDROID_HOME/ndk/${{ env.ANDROID_NDK_VERSION }}" \
66+ bash "$HOME/Library/org.swift.swiftpm/swift-sdks/swift-${{ env.SWIFT_VERSION }}-RELEASE_android.artifactbundle/swift-android/scripts/setup-android-sdk.sh"
67+ - name : Build
68+ run : swift build --swift-sdk aarch64-unknown-linux-android28 -c ${{ matrix.config }}
You can’t perform that action at this time.
0 commit comments