Skip to content

ci: build for Windows #11

ci: build for Windows

ci: build for Windows #11

Workflow file for this run

name: build-aar-test
on:
push: {}
jobs:
android-build:
runs-on: macos-12
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install NumPy
run: pip install --no-cache-dir --user numpy
- name: echo
run: |
echo $ANDROID_HOME
echo $ANDROID_NDK_HOME
- uses: nttld/setup-ndk@v1
id: setup-ndk
with:
ndk-version: r21e
add-to-path: false
- name: Build
run: |
# make a dummy OpenCV dir
mkdir -p /usr/local/opt/opencv@3
make android_arm64
make install
env:
ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}
- name: Upload mediapipe_android.aar
uses: actions/upload-artifact@v3
with:
name: mediapipe_android.aar
path: Assets/MediaPipe/SDK/Plugins/Android/mediapipe_android.aar
windows-build:
runs-on: windows-2019
steps:
- uses: actions/checkout@v4
# Setup build tools
- uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: git patch unzip zip
# Setup Python
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: echo
run: |
which python
shell: bash
- name: Install NumPy
run: pip install --no-cache-dir --user numpy
- name: Install OpenCV
run: |
curl -L --retry 4 --connect-timeout 10 https://github.com/opencv/opencv/releases/download/3.4.10/opencv-3.4.10-vc14_vc15.exe -o opencv-installer.exe
start /wait opencv-installer.exe -gm2 -y -oC:\
del opencv-installer.exe
shell: cmd
- name: Build
run: |
set ANDROID_NDK_HOME=
make cpu
make install
shell: cmd