Install apt libopus-dev for arm #10
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: Build static ffmpeg | |
on: | |
push: | |
pull_request: | |
jobs: | |
package-linux: | |
continue-on-error: true | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
arch: | |
- x86_64 | |
- arm64 | |
env: | |
ARCH: ${{ matrix.arch }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies for x86_64 | |
if: env.ARCH == 'x86_64' | |
run: | | |
sudo apt-get update -y && \ | |
sudo apt-get install -y libopus-dev yasm | |
- name: Install dependencies for arm64 | |
if: env.ARCH == 'arm64' | |
run: | | |
sudo dpkg --add-architecture arm64 && \ | |
sudo apt-get update -y && \ | |
sudo apt-get install -y libopus-dev:arm64 yasm gcc-aarch64-linux-gnu | |
- name: Build | |
run: ./build-linux.sh | |
- name: Archive production artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
name: ffmpeg-linux-${{ env.ARCH }} | |
path: artifacts/ | |
package-windows: | |
continue-on-error: true | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
arch: | |
- x86_64 | |
env: | |
ARCH: ${{ matrix.arch }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update -y && \ | |
sudo apt-get install -y libopus-dev yasm mingw-w64 | |
- name: Build | |
run: ./build-windows.sh | |
- name: Archive production artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
name: ffmpeg-windows-${{ env.ARCH }} | |
path: artifacts/ | |
package-macos: | |
continue-on-error: true | |
runs-on: macos-latest | |
strategy: | |
matrix: | |
# https://developer.apple.com/documentation/apple-silicon/building-a-universal-macos-binary#Update-the-Architecture-List-of-Custom-Makefiles | |
target: | |
- x86_64-apple-macos10.9 | |
- arm64-apple-macos11 | |
env: | |
TARGET: ${{ matrix.target }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: brew install yasm | |
- name: Build | |
run: ./build-macos.sh | |
- name: Archive artifacts | |
uses: actions/upload-artifact@v1 | |
with: | |
name: ffmpeg-${{ matrix.target }} | |
path: artifacts/ | |
release: | |
runs-on: ubuntu-latest | |
needs: | |
- package-linux | |
- package-windows | |
- package-macos | |
steps: | |
- uses: actions/download-artifact@v2 | |
with: | |
path: artifacts/ | |
- name: Make tarballs | |
run: | | |
mkdir artifacts/release/ | |
cd artifacts/ | |
for dir in ffmpeg-*/ffmpeg-* | |
do | |
name=$(basename $dir) | |
tar czf release/$name.tar.gz -C $(dirname $dir) $name | |
done | |
ls -l release/ | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/v') | |
with: | |
files: artifacts/release/* | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |