/
githubmirror
/
libusb
Обзор
Документация
Войти
/
githubmirror
/
libusb
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
.github/workflows/android.yml
70 строк
2 KB
Ihor Dutchak
ci: avoid duplicate feature-branch workflow runs (#1880)
17 июл 2026, 11:19
Не верифицирован
17 июл 2026, 11:19
ff6e41e
Код
Авторство
О чём код?
name: Android on: push: branches: - master tags: - '**' pull_request: concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: ${{ github.event_name == 'pull_request' }} jobs: build: runs-on: ubuntu-latest timeout-minutes: 60 strategy: fail-fast: false matrix: abi: [arm64-v8a, armeabi-v7a, x86_64] api: [21] env: ANDROID_ABI: ${{ matrix.abi }} ANDROID_API: ${{ matrix.api }} NDK_OUT_DIR: ${{ github.workspace }}/out/${{ matrix.abi }} NDK_LIBS_DIR: ${{ github.workspace }}/libs/${{ matrix.abi }} steps: - name: Checkout uses: actions/checkout@v6 with: # Full history + tags so build-aux/gen-describe.sh can produce a # tag-prefixed describe string. fetch-depth: 0 - name: Show ANDROID_NDK_ROOT run: | echo "ANDROID_NDK_ROOT=${ANDROID_NDK_ROOT}" test -d "${ANDROID_NDK_ROOT}" || (echo "ANDROID_NDK_ROOT not set or invalid" && exit 1) - name: Install dependencies run: | sudo apt update sudo apt install -y file - name: Build with ndk-build working-directory: android/jni run: | mkdir -p "${NDK_OUT_DIR}" "${NDK_LIBS_DIR}" "${ANDROID_NDK_ROOT}/ndk-build" -j \ APP_ABI="${ANDROID_ABI}" \ APP_PLATFORM="android-${ANDROID_API}" \ NDK_OUT="${NDK_OUT_DIR}" \ NDK_LIBS_OUT="${NDK_LIBS_DIR}" - name: Show outputs run: | set -euxo pipefail find "${NDK_LIBS_DIR}" -maxdepth 2 -type f -print0 | xargs -0 ls -lh || true file "${NDK_LIBS_DIR}/"* || true - name: Upload artifacts uses: actions/upload-artifact@v7 with: name: libusb-android-${{ matrix.abi }}-api${{ matrix.api }} path: | libs/${{ matrix.abi }}/ if-no-files-found: error