maomaowm/.github/workflows/build.yml
copilot-swe-agent[bot] 6a209101a0 Switch CI to Arch Linux container for better package availability
Co-authored-by: squassina <8495707+squassina@users.noreply.github.com>
2026-02-18 13:03:59 +00:00

109 lines
2.6 KiB
YAML

name: Build
on:
push:
branches: [main, master]
paths:
- '**.c'
- '**.h'
- '**.cpp'
- '**.scm'
- 'meson.build'
- 'meson_options.txt'
- 'flake.nix'
- 'protocols/**'
- '.github/workflows/build.yml'
pull_request:
branches: [main, master]
paths:
- '**.c'
- '**.h'
- '**.cpp'
- '**.scm'
- 'meson.build'
- 'meson_options.txt'
- 'flake.nix'
- 'protocols/**'
- '.github/workflows/build.yml'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
container:
image: archlinux:latest
permissions:
contents: read
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Update system and install dependencies
run: |
# Update package database
pacman -Syu --noconfirm
# Install build tools and dependencies
pacman -S --noconfirm \
base-devel \
git \
meson \
ninja \
wayland \
wayland-protocols \
libinput \
libxkbcommon \
pcre2 \
pixman \
libdrm \
libxcb \
xcb-util-wm \
xorg-xwayland \
hwdata \
libliftoff \
libdisplay-info \
seatd \
mesa \
pkg-config
- name: Install wlroots 0.19.0
run: |
# Build wlroots 0.19.0 from source
git clone https://gitlab.freedesktop.org/wlroots/wlroots.git
cd wlroots
git checkout 0.19.0
# Download meson subprojects if needed
meson subprojects download || true
meson setup build/ --prefix=/usr
ninja -C build/ install
ldconfig
cd ..
- name: Install scenefx 0.4.1
run: |
# Build scenefx from source
git clone -b 0.4.1 https://github.com/wlrfx/scenefx.git
cd scenefx
# Download meson subprojects if needed
meson subprojects download || true
meson setup build/ --prefix=/usr
ninja -C build/ install
ldconfig
cd ..
- name: Configure meson
run: |
# Download meson subprojects if needed
meson subprojects download || true
meson setup build/ --prefix=/usr
- name: Build project
run: |
ninja -C build/
- name: Build summary
run: |
echo "✅ Build completed successfully!"
echo "Built executables:"
ls -lh build/mango build/mmsg