Multiarch CI #29
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Compile secp256k1 native library | |
on: | |
pull_request: | |
branches: | |
- master | |
push: | |
branches: | |
- trying | |
- staging | |
jobs: | |
compile: | |
name: Compile secp256k1 | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# Linux | |
- name: linux | |
os: ubuntu-22.04 | |
arch: amd64 | |
- name: linux | |
os: ubuntu-22.04 | |
arch: aarch64 | |
# MacOS | |
- name: macos | |
os: macos-13 | |
arch: amd64 | |
- name: macos | |
os: macos-13 | |
arch: aarch64 | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: 'recursive' | |
- name: Install dependencies ubuntu | |
if: matrix.name == 'linux' | |
run: | | |
uname -a | |
sudo apt-get update | |
sudo apt-get install -y build-essential libtool | |
sudo apt-get install -y gcc-aarch64-linux-gnu | |
export DEBIAN_FRONTEND=noninteractive | |
sudo apt-get install -y openjdk-17-jdk-headless | |
- name: Install dependencies macos | |
if: matrix.name == 'macos' | |
run: | | |
uname -a | |
brew install autoconf automake | |
brew install openjdk@17 | |
echo 'export JAVA_PATH="/usr/local/opt/openjdk@17/libexec/openjdk.jdk:$PATH"' >> /Users/runner/.bash_profile | |
export CFLAGS="-I$JAVA_PATH/include -I$JAVA_PATH/include/darwin" | |
- name: Build native code | |
run: | | |
./compile.sh | |
- name: Export artifacts linux | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ matrix.name }}-${{ matrix.arch }} | |
path: ./secp256k1-tmp/.libs/ | |
# Job to notify bors when run is successful. Skipped and cancelled job is considered | |
# as failure. More info https://github.com/bors-ng/bors-ng/issues/1115. | |
bors_success: | |
name: bors build finished | |
if: ${{ success() }} | |
needs: | |
- compile | |
runs-on: ubuntu-latest | |
steps: | |
- run: exit 0 |