Skip to content

docs: update PHP wrapper installation instructions #4

docs: update PHP wrapper installation instructions

docs: update PHP wrapper installation instructions #4

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
build:
name: Build ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
artifact: libanvildb.so
dir: x86_64-linux
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
artifact: libanvildb.so
dir: aarch64-linux
- target: x86_64-apple-darwin
os: macos-15
artifact: libanvildb.dylib
dir: x86_64-darwin
- target: aarch64-apple-darwin
os: macos-14
artifact: libanvildb.dylib
dir: aarch64-darwin
- target: x86_64-pc-windows-msvc
os: windows-latest
artifact: anvildb.dll
dir: x86_64-windows
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Install cross-compilation tools (aarch64-linux)
if: matrix.target == 'aarch64-unknown-linux-gnu'
run: |
sudo apt-get update
sudo apt-get install -y gcc-aarch64-linux-gnu
- name: Build release binary
run: cargo build --release --target ${{ matrix.target }}
env:
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: aarch64-linux-gnu-gcc
- name: Package artifact (Unix)
if: runner.os != 'Windows'
run: |
mkdir -p dist/${{ matrix.dir }}
cp target/${{ matrix.target }}/release/${{ matrix.artifact }} dist/${{ matrix.dir }}/
tar -czf anvildb-${{ matrix.dir }}.tar.gz -C dist ${{ matrix.dir }}
- name: Package artifact (Windows)
if: runner.os == 'Windows'
shell: bash
run: |
mkdir -p dist/${{ matrix.dir }}
cp target/${{ matrix.target }}/release/${{ matrix.artifact }} dist/${{ matrix.dir }}/
tar -czf anvildb-${{ matrix.dir }}.tar.gz -C dist ${{ matrix.dir }}
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: anvildb-${{ matrix.dir }}
path: anvildb-${{ matrix.dir }}.tar.gz
release:
name: Create Release
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download all artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
files: artifacts/**/*.tar.gz