Files
xf86-video-r128/.github/actions/build-driver/action.yaml
Enrico Weigelt, metux IT consult ef11b52501 .github: add CI pipeline
This pipeline builds the driver against the latest Xserver stable
release as well as current master.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-07-28 20:30:45 +02:00

70 lines
2.3 KiB
YAML

name: 'build driver'
description: 'build driver against specific Xserver'
inputs:
xserver-version:
required: true
runs:
using: "composite"
steps:
- name: check out driver repo
uses: actions/checkout@v4
- name: prepare build environment
shell: bash
run: |
MACHINE=`gcc -dumpmachine`
echo "MACHINE=$MACHINE" >> "$GITHUB_ENV"
echo "PKG_CONFIG_PATH=$X11_PREFIX/share/pkgconfig:$X11_PREFIX/lib/$MACHINE/pkgconfig:$X11_PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH" >> "$GITHUB_ENV"
sudo chown root /bin/tar && sudo chmod u+s /bin/tar
- name: apt cache
uses: actions/cache@v4
with:
path: /var/cache/apt
key: apt-cache-${{ hashFiles('.github/scripts/ubuntu/install-pkg.sh') }}
restore-keys: apt-cache-
- name: pkg install
shell: bash
run: sudo .github/scripts/ubuntu/install-pkg.sh
- name: X11 prereq cache
uses: actions/cache@v4
with:
path: |
${{ env.X11_PREFIX }}
key: ${{ runner.name }}-x11-deps-${{ hashFiles('.github/scripts/install-prereq.sh') }}
restore-keys: ${{ runner.name }}-x11-deps-
- name: generic prereq
shell: bash
run: .github/scripts/install-prereq.sh
- name: check out xserver repo
uses: actions/checkout@v4
with:
repository: X11Libre/xserver
path: xserver-sdk
ref: ${{ inputs.xserver-version }}
- name: build xserver sdk
shell: bash
env:
MESON_ARGS: -Dc_args="-fno-common" -Dprefix=/usr -Dnamespace=false -Dxselinux=false -Dxephyr=false -Dwerror=false -Dxcsecurity=false -Dxorg=true -Dxvfb=false -Dxnest=false -Ddocs=false
run: |
cd xserver-sdk
echo -n > .meson_environment
echo "export MESON_BUILDDIR=$MESON_BUILDDIR" >> .meson_environment
echo "export PKG_CONFIG_PATH=$PKG_CONFIG_PATH" >> .meson_environment
.gitlab-ci/meson-build.sh --skip-test
sudo meson install --no-rebuild -C "$MESON_BUILDDIR"
sudo mkdir -p /usr/local/lib/$MACHINE/xorg/modules # /home/runner/x11/lib/xorg/modules
sudo chown -R runner /usr/local/lib/$MACHINE/xorg/modules # /home/runner/x11/lib/xorg/modules
- name: compile driver
shell: bash
run: |
CFLAGS="-Wall" ./autogen.sh # --prefix=$X11_PREFIX
CFLAGS="-Wall" make -j # install