Skip to content

macOS dylib

macOS dylib #70

Workflow file for this run

name: Build Android
on:
workflow_dispatch:
inputs:
version:
description: Version Overwrite
required: false
push:
tags:
- "v*"
pull_request:
env:
VERSION: ${{ github.event.inputs.version || (startsWith(github.ref, 'refs/tags/') && github.ref || '') }}
jobs:
binding:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
- uses: android-actions/setup-android@v2
- uses: nttld/setup-ndk@v1
id: setup-ndk
with:
ndk-version: r21d
- uses: actions/setup-go@v3
with:
go-version: '^1.21'
- name: Build
run: make binding_android
env:
ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}
ANDROID_NDK_TOOLCHAIN: ${{ steps.setup-ndk.outputs.ndk-path }}/toolchains/llvm/prebuilt/linux-x86_64/bin
- name: Compress
run: tar -czvf output.tar.gz -C output/binding/android .
- if: ${{ env.VERSION!='' }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
asset_name: libopenpgp_bridge_android_$tag.tar.gz
file: output.tar.gz
tag: ${{ env.VERSION }}
overwrite: true
- if: ${{ env.VERSION=='' }}
uses: actions/upload-artifact@v3
with:
name: libopenpgp_bridge_android
path: output.tar.gz