Skip to content
This repository has been archived by the owner on Nov 25, 2022. It is now read-only.

Commit

Permalink
[ci] Fix build android rpc failure (apache#12216)
Browse files Browse the repository at this point in the history
android_rpc build problem: apache#12191

The problem with the build appeared due to the fact that the `ANDROID_NDK_HOME` environment variable was removed in the current version of github actions. 
https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md

But this variable is used here:

https://github.com/apache/tvm/blob/ee319d9d23c80091da9c4fb764b1e6d49d462714/.github/workflows/main.yml#L122-L127

Now only `ANDROID_NDK_LATEST_HOME` is available for ndk.
  • Loading branch information
valmat07 authored and xinetzone committed Nov 25, 2022
1 parent e255843 commit 558e821
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,8 @@ jobs:
working-directory: apps/android_rpc
continue-on-error: true
run: |
export PATH="${ANDROID_NDK_HOME}:$PATH"
set -eux
export PATH="${ANDROID_NDK_LATEST_HOME}:$PATH"
gradle clean build
- name: Upload android_rpc APK
uses: actions/upload-artifact@v2
Expand All @@ -135,7 +136,8 @@ jobs:
working-directory: apps/android_deploy
continue-on-error: true
run: |
export PATH="${ANDROID_NDK_HOME}:$PATH"
set -eux
export PATH="${ANDROID_NDK_LATEST_HOME}:$PATH"
gradle clean build
- name: Upload android_deploy APK
uses: actions/upload-artifact@v2
Expand All @@ -147,8 +149,9 @@ jobs:
working-directory: apps/android_camera
continue-on-error: true
run: |
set -eux
mkdir -p app/src/main/assets/models/
export TVM_NDK_CC=${ANDROID_NDK_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android30-clang++
export TVM_NDK_CC=${ANDROID_NDK_LATEST_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android30-clang++
export TVM_HOME=~/work/tvm/tvm
export PYTHONPATH=$TVM_HOME/python:${PYTHONPATH}
python3 ${TVM_HOME}/python/gen_requirements.py
Expand All @@ -157,7 +160,7 @@ jobs:
pip3 install -r requirements.txt
python3 prepare_model.py
cd ..
export PATH="${ANDROID_NDK_HOME}:$PATH"
export PATH="${ANDROID_NDK_LATEST_HOME}:$PATH"
gradle clean build
- name: Upload android_camera APK
uses: actions/upload-artifact@v2
Expand Down

0 comments on commit 558e821

Please sign in to comment.