Skip to content

Commit 44c9fc5

Browse files
committed
update
1 parent 12e1e10 commit 44c9fc5

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

.github/workflows/react_native.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -50,23 +50,23 @@ jobs:
5050
- name: Build Android AAR Packages
5151
run: |
5252
set -e -x
53-
NDK_HOME=$(realpath $ANDROID_NDK_HOME)
53+
ORT_VERSION=$(cat VERSION_NUMBER)
5454
mkdir -p ${{ runner.temp }}/.build_settings
55-
mkdir -p ${{ runner.temp }}/.artifacts
55+
mkdir -p ${{ runner.temp }}/artifacts
5656
cp ${{ github.workspace }}/tools/ci_build/github/js/react_native_e2e_full_aar_build_settings.json ${{ runner.temp }}/.build_settings/build_settings.json
57+
BUILD_SCRIPT="${{ github.workspace }}/tools/ci_build/github/android${{ runner.temp }}_aar_package.py"
58+
BUILD_SETTINGS="${{ runner.temp }}/.build_settings/build_settings.json"
5759
58-
docker run --rm \
59-
--volume ${{ github.workspace }}:/onnxruntime_src \
60-
--volume $ANDROID_HOME:/android_home \
61-
--volume $NDK_HOME:/ndk_home \
62-
--volume ${{ runner.temp }}/.artifacts:/home/onnxruntimedev/.artifacts \
63-
--volume ${{ runner.temp }}/.build_settings:/home/onnxruntimedev/.build_settings \
64-
-e BUILD_CONFIG=Release \
65-
-e ORT_VERSION=${{ env.OnnxRuntimeVersion }} \
66-
-e PUBLISH_EXECUTABLES=0 \
67-
-e PACKAGE_NAME=onnxruntime-android \
68-
${{ steps.build_docker_image_step.outputs.full-image-name }} \
69-
/bin/bash /onnxruntime_src/tools/ci_build/github/android/build_aar_and_copy_artifacts.sh 0
60+
61+
python3 -m pip install -r ${{ github.workspace }}/tools/ci_build/requirements/pybind/requirements.txt
62+
63+
python3 $BUILD_SCRIPT --build_dir ${{ runner.temp }} --config $BUILD_CONFIG --android_sdk_path $ANDROID_SDK_HOME --android_ndk_path $ANDROID_NDK_HOME $BUILD_SETTINGS
64+
65+
# Copy the built artifacts to give folder for publishing
66+
BASE_PATH=${{ runner.temp }}/aar_out/${BUILD_CONFIG}/com/microsoft/onnxruntime/${PACKAGE_NAME}/${ORT_VERSION}
67+
cp ${BASE_PATH}/*.jar ${{ runner.temp }}/artifacts
68+
cp ${BASE_PATH}/*.aar ${{ runner.temp }}/artifacts
69+
cp ${BASE_PATH}/*.pom ${{ runner.temp }}/artifacts
7070
7171
- name: Upload Android AAR Artifact
7272
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)