Repository navigation
meta: add github actions ci - #4
Merged
Merged
Conversation
Pin wlroots via .github/wlroots-version and build it from source in CI so master (wlroots.pc / 0.17.x) and stacked branches (e.g. wlroots-0.20) can share one workflow by bumping the pin.
Committed syms.go can target a newer libxkbcommon than ubuntu-latest ships. Generate against the runner headers before build.
wlroots 0.20 needs wayland-server >= 1.24; ubuntu-latest ships 1.22. Override the project's wrap_mode=nodownload so meson can pull the wayland wrap when the system package is too old.
ubuntu-latest ships meson 1.3.2; libxkbcommon's wrap (HEAD) requires >=1.4. Install a current meson via pip before building wlroots.
Wrap fallbacks (v4l via libdisplay-info) try to install udev keymaps under /usr. Stage into $HOME/wlroots-root so CI stays unprivileged.
Drop meson wraps: HEAD wraps need a newer meson, pull v4l into /usr, and leave .pc files pointing at the wrong prefix under DESTDIR. Build only packages ubuntu-latest is too old for into $HOME/deps, then build the pinned wlroots with wrap_mode=nodownload.
Public wlr headers include generated *-protocol.h with quotes, but meson leaves those as private build artifacts. Copy them into the versioned include dir after ninja install so go build can find them.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Coder created this PR.
Why
Add GitHub Actions CI that compiles the module with CGO against a pinned wlroots built from source, so master (
#cgo pkg-config: wlroots, ~0.17) and stacked API bumps (e.g.wlroots-0.20) share one workflow.Scope
.github/wlroots-version— pin currently 0.17.4 (last 0.17).github/workflows/ci.yml—ubuntu-latest, apt build deps, clone/build/install pinned wlroots under$HOME/wlroots, setPKG_CONFIG_PATH/LD_LIBRARY_PATH, Go matrix 1.26.x and 1.27.x,CGO_ENABLED=1 go build ./...+go vet ./...go.mod(go 1.25.7stays; newer toolchains via GOTOOLCHAIN)Child bump path
Stacked PRs bump
.github/wlroots-version(e.g. to0.20.2) so meson installswlroots-0.20.pcand the existing#cgo pkg-config: wlroots-0.20 …line resolves.Verification
Locally against a from-source 0.17.4 install (
$HOME/wlroots-0.17):pkg-config --modversion wlroots→0.17.4go build ./...on master currently fails inxkbagainst libxkbcommon 1.7 (stale generated keysyms referencing removed XF86_* symbols). That is fixed by the stackedxkb: regenerateon PR wlr: retarget to wlroots 0.20.2 #3 — expect CI green there after retarget; this CI-only PR may stay red on./...until that stacks or keysyms are regenerated on master.Tradeoffs
Building wlroots from source each run is slower than distro packages, but keeps the pin exact across 0.17 / 0.20 pc-name changes without Nix.