Skip to content

0.3.26

0.3.26 #420

Workflow file for this run

name: rust / build
on:
push:
branches: [main]
pull_request:
env:
CARGO_TERM_COLOR: always
RUSTFLAGS: -Awarnings
jobs:
build:
name: ${{ matrix.os }} / ${{ matrix.target }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
cross: false
cross_compile: false
- os: ubuntu-latest
target: aarch64-unknown-linux-gnu
cross: true
cross_compile: true
# - os: ubuntu-latest
# target: aarch64-linux-android
# cross: true
# cross_compile: true
- os: windows-latest
target: x86_64-pc-windows-msvc
cross: false
cross_compile: false
- os: macos-latest
target: x86_64-apple-darwin
cross: false
cross_compile: false
steps:
- name: Checkout repo
uses: actions/checkout@v2
- uses: dtolnay/rust-toolchain@stable
- name: Use Rust Cache
uses: Swatinem/rust-cache@v1
- name: Setup Cross Compilation Tools
if: matrix.cross == 'true' && contains(matrix.target, 'linux')
run: |
sudo apt update
sudo apt install -yq --no-install-suggests --no-install-recommends \
binfmt-support g++-10-aarch64-linux-gnu g++-10-multilib \
gcc-10-aarch64-linux-gnu libc6-arm64-cross qemu qemu-user \
qemu-user-binfmt
sudo ln -s /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.1 /lib/ld-linux-aarch64.so.1
echo "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=/usr/bin/aarch64-linux-gnu-gcc-10" >> $GITHUB_ENV
echo "QEMU_LD_PREFIX=/usr/aarch64-linux-gnu" >> $GITHUB_ENV
- name: Build
uses: actions-rs/cargo@v1
with:
command: build
args: --color always --release --target ${{ matrix.target }}
use-cross: ${{ matrix.cross }}
- name: Get Build Name
id: zip
run: echo "::set-output name=name::three_em-${{ matrix.target }}-${{ github.ref == 'refs/heads/main' && 'canary' || 'dev' }}-$(git rev-parse --short HEAD)"
- name: Upload ${{ github.ref == 'refs/heads/main' && 'Canary' || 'Dev' }} Builds
uses: actions/upload-artifact@v2
with:
name: ${{ steps.zip.outputs.name }}
path: |
README.md
LICENSE
target/${{ matrix.target }}/release/three_em
target/${{ matrix.target }}/release/three_em.exe
if-no-files-found: error
retention-days: 7