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: Meson CI for Archlinux | |
on: | |
push: | |
branches: | |
- master | |
- feature | |
- cibuilds | |
paths-ignore: | |
- ".github/workflows/ci.yml" | |
pull_request: | |
branches: | |
- master | |
- feature | |
paths-ignore: | |
- ".github/workflows/ci.yml" | |
jobs: | |
build: | |
name: ${{ matrix.config.name }} | |
runs-on: ${{ matrix.config.os }} | |
container: | |
image: ${{ matrix.config.container }} | |
# options: --user 1001 | |
strategy: | |
fail-fast: false | |
matrix: | |
config: | |
- name: Archlinux Release | |
os: ubuntu-latest | |
container: archlinux:base-devel | |
buildtype: release | |
args: >- | |
--prefix=/usr | |
-Ddefault_audio_output=PulseAudio | |
-Davisynth=enabled | |
-Dbestsource=enabled | |
-Dffms2=enabled | |
-Dvapoursynth=enabled | |
steps: | |
- name: Prerequisites 1 | |
run: pacman --noconfirm -Syu cmake git | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Prerequisites 2 | |
run: git config --global --add safe.directory '/__w/Aegisub/Aegisub' | |
- name: Install dependencies | |
run: | | |
pacman --noconfirm -Syu wireplumber | |
pacman --noconfirm -Sy pipewire-jack | |
pacman --noconfirm -Sy avisynthplus boost ffmpeg \ | |
fontconfig hunspell libass libglvnd meson openal portaudio \ | |
python pulseaudio uchardet vapoursynth wxwidgets-gtk3 | |
- name: Compile ffms2 | |
run: | | |
git clone --depth=1 https://github.com/FFMS/ffms2.git | |
cd ffms2 | |
./autogen.sh --prefix=/usr --enable-shared --disable-static --enable-avisynth | |
make V=1 CXXFLAGS='-I/usr/include/avisynth' -j2 -k | |
make install | |
cd .. | |
rm -rf ffms2 | |
- name: Download some other dependencies | |
run: | | |
cd subprojects | |
git clone --depth=1 https://github.com/vapoursynth/bestsource.git | |
git clone --depth=1 https://github.com/LuaJIT/LuaJIT.git | |
mv LuaJIT luajit | |
mkdir packagecache | |
cd packagecache | |
curl -o gtest-1.14.0.tar.gz -L https://github.com/google/googletest/archive/refs/tags/v1.14.0.tar.gz | |
curl -o gtest_1.14.0-1_patch.zip -L https://wrapdb.mesonbuild.com/v2/gtest_1.14.0-1/get_patch | |
cd ../.. | |
meson subprojects packagefiles --apply bestsource | |
meson subprojects packagefiles --apply luajit | |
- name: Configure | |
run: C_FLAGS="-Wall -Wextra -Wpedantic" CXX_FLAGS="-Wall -Wextra -Wpedantic" meson setup build ${{ matrix.config.args }} -Dcpp_std=c++2a -Dbuildtype=${{ matrix.config.buildtype }} | |
- name: Build | |
run: meson compile -C build | |
# - name: Run test | |
# run: meson test -C build --verbose "gtest main" | |
- name: Generate Package | |
run: | | |
mkdir -p pkgdir | |
meson install -C build --destdir=../pkgdir | |
ls -Ral pkgdir |