Add Fedora and Arch package recipes (#24)
* Package Ferese for Fedora and Arch releases * Build release packages alongside workspace checks * Include dependency licenses and software GPU test drivers * Limit package checks to release PRs and fix Arch Cargo dependency * Prepare Ferese 0.1.0-beta * Release config locks before closing inherited file descriptions * Install the lock PAM policy for native release checks * Include xauth in distribution package test dependencies * Regenerate Arch Git package metadata * Run package checks with an explicit UTC timezone * Remove unused bundled fonts and accept installed license receipts * Format the system font test helper * Load an installed font for headless text rendering checks * Isolate package test runtimes and reap container child processes
This commit is contained in:
1 parent
587602b493
commit
1b9fabbbe4
25 files changed
+1019
-170
No files matched your search
@@ -0,0 +1,49 @@
|
||||
pkgname=ferese
|
||||
pkgver=@VERSION@
|
||||
pkgrel=1
|
||||
pkgdesc='Scrolling Wayland desktop with its shell, Settings and desktop portal'
|
||||
arch=('x86_64')
|
||||
url='https://github.com/ferese-wm/ferese'
|
||||
license=('MIT' 'Apache-2.0' 'BSD-2-Clause' 'BSD-3-Clause' 'BSL-1.0' 'CC0-1.0' 'CDLA-Permissive-2.0' 'ISC' 'MPL-2.0' 'Unicode-3.0' 'Unlicense' 'Zlib' 'OFL-1.1' 'Apache-2.0 WITH LLVM-exception')
|
||||
depends=('wayland' 'libxkbcommon' 'libinput' 'systemd-libs' 'seatd' 'mesa' 'libdrm'
|
||||
'fontconfig' 'freetype2' 'expat' 'dbus' 'python' 'bash' 'util-linux' 'systemd' 'pam' 'polkit' 'foot' 'pipewire'
|
||||
'wireplumber' 'libpipewire' 'gstreamer' 'xdg-desktop-portal' 'xdg-desktop-portal-gtk')
|
||||
makedepends=('cargo' 'cmake' 'clang' 'pkgconf' 'python' 'desktop-file-utils')
|
||||
checkdepends=('dbus' 'vulkan-swrast' 'xorg-xauth')
|
||||
optdepends=('brightnessctl: brightness controls' 'slurp: screenshot region selection'
|
||||
'satty: screenshot editing' 'wl-clipboard: screenshot clipboard'
|
||||
'gst-plugins-base: recording codecs' 'gst-plugins-good: recording codecs'
|
||||
'gst-plugin-pipewire: PipeWire recording'
|
||||
'xorg-xwayland: X11 applications' 'xwayland-satellite: X11 application integration (requires readiness support)')
|
||||
# GCC LTO objects from the SPA C wrappers cannot be linked by Rust's lld.
|
||||
options=('!lto')
|
||||
backup=('etc/pam.d/ferese-lock')
|
||||
conflicts=('ferese-git')
|
||||
_source_version=@UPSTREAM_VERSION@
|
||||
source=("$url/releases/download/v$_source_version/ferese-$_source_version.tar.gz")
|
||||
sha256sums=('@SHA256@')
|
||||
|
||||
build() {
|
||||
cd "$srcdir/ferese-$_source_version"
|
||||
export CARGO_HOME="$PWD/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
cargo build --release --frozen --offline --workspace
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "$srcdir/ferese-$_source_version"
|
||||
export CARGO_HOME="$PWD/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
export TZ=UTC
|
||||
export XDG_RUNTIME_DIR="$(mktemp -d)"
|
||||
trap 'rm -r -- "$XDG_RUNTIME_DIR"' EXIT
|
||||
python -m unittest discover -s scripts/tests -p test_package.py
|
||||
dbus-run-session -- cargo test --release --frozen --offline --workspace
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir/ferese-$_source_version"
|
||||
python scripts/package.py stage --destdir "$pkgdir" --pam arch
|
||||
desktop-file-validate "$pkgdir/usr/share/wayland-sessions/ferese.desktop"
|
||||
desktop-file-validate "$pkgdir/usr/share/applications/dev.ferese.Settings.desktop"
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
pkgbase = ferese-git
|
||||
pkgdesc = Scrolling Wayland desktop with its shell, Settings and desktop portal (Git)
|
||||
pkgver = 0.1.0beta.r0.g0000000
|
||||
pkgrel = 1
|
||||
url = https://github.com/ferese-wm/ferese
|
||||
arch = x86_64
|
||||
license = MIT
|
||||
license = Apache-2.0
|
||||
license = BSD-2-Clause
|
||||
license = BSD-3-Clause
|
||||
license = BSL-1.0
|
||||
license = CC0-1.0
|
||||
license = CDLA-Permissive-2.0
|
||||
license = ISC
|
||||
license = MPL-2.0
|
||||
license = Unicode-3.0
|
||||
license = Unlicense
|
||||
license = Zlib
|
||||
license = OFL-1.1
|
||||
license = Apache-2.0 WITH LLVM-exception
|
||||
checkdepends = dbus
|
||||
checkdepends = vulkan-swrast
|
||||
checkdepends = xorg-xauth
|
||||
makedepends = cargo
|
||||
makedepends = cmake
|
||||
makedepends = clang
|
||||
makedepends = pkgconf
|
||||
makedepends = python
|
||||
makedepends = git
|
||||
makedepends = desktop-file-utils
|
||||
depends = wayland
|
||||
depends = libxkbcommon
|
||||
depends = libinput
|
||||
depends = systemd-libs
|
||||
depends = seatd
|
||||
depends = mesa
|
||||
depends = libdrm
|
||||
depends = fontconfig
|
||||
depends = freetype2
|
||||
depends = expat
|
||||
depends = dbus
|
||||
depends = python
|
||||
depends = bash
|
||||
depends = util-linux
|
||||
depends = systemd
|
||||
depends = pam
|
||||
depends = polkit
|
||||
depends = foot
|
||||
depends = pipewire
|
||||
depends = wireplumber
|
||||
depends = libpipewire
|
||||
depends = gstreamer
|
||||
depends = xdg-desktop-portal
|
||||
depends = xdg-desktop-portal-gtk
|
||||
optdepends = brightnessctl: brightness controls
|
||||
optdepends = slurp: screenshot region selection
|
||||
optdepends = satty: screenshot editing
|
||||
optdepends = wl-clipboard: screenshot clipboard
|
||||
optdepends = gst-plugins-base: recording codecs
|
||||
optdepends = gst-plugins-good: recording codecs
|
||||
optdepends = gst-plugin-pipewire: PipeWire recording
|
||||
optdepends = xorg-xwayland: X11 applications
|
||||
optdepends = xwayland-satellite: X11 application integration (requires readiness support)
|
||||
provides = ferese
|
||||
conflicts = ferese
|
||||
options = !lto
|
||||
backup = etc/pam.d/ferese-lock
|
||||
source = ferese::git+https://github.com/ferese-wm/ferese.git#branch=main
|
||||
sha256sums = SKIP
|
||||
|
||||
pkgname = ferese-git
|
||||
@@ -0,0 +1,63 @@
|
||||
pkgname=ferese-git
|
||||
pkgver=0.1.0beta.r0.g0000000
|
||||
pkgrel=1
|
||||
pkgdesc='Scrolling Wayland desktop with its shell, Settings and desktop portal (Git)'
|
||||
arch=('x86_64')
|
||||
url='https://github.com/ferese-wm/ferese'
|
||||
license=('MIT' 'Apache-2.0' 'BSD-2-Clause' 'BSD-3-Clause' 'BSL-1.0' 'CC0-1.0' 'CDLA-Permissive-2.0' 'ISC' 'MPL-2.0' 'Unicode-3.0' 'Unlicense' 'Zlib' 'OFL-1.1' 'Apache-2.0 WITH LLVM-exception')
|
||||
depends=('wayland' 'libxkbcommon' 'libinput' 'systemd-libs' 'seatd' 'mesa' 'libdrm'
|
||||
'fontconfig' 'freetype2' 'expat' 'dbus' 'python' 'bash' 'util-linux' 'systemd' 'pam' 'polkit' 'foot' 'pipewire'
|
||||
'wireplumber' 'libpipewire' 'gstreamer' 'xdg-desktop-portal' 'xdg-desktop-portal-gtk')
|
||||
makedepends=('cargo' 'cmake' 'clang' 'pkgconf' 'python' 'git' 'desktop-file-utils')
|
||||
checkdepends=('dbus' 'vulkan-swrast' 'xorg-xauth')
|
||||
optdepends=('brightnessctl: brightness controls' 'slurp: screenshot region selection'
|
||||
'satty: screenshot editing' 'wl-clipboard: screenshot clipboard'
|
||||
'gst-plugins-base: recording codecs' 'gst-plugins-good: recording codecs'
|
||||
'gst-plugin-pipewire: PipeWire recording'
|
||||
'xorg-xwayland: X11 applications' 'xwayland-satellite: X11 application integration (requires readiness support)')
|
||||
provides=('ferese')
|
||||
conflicts=('ferese')
|
||||
# GCC LTO objects from the SPA C wrappers cannot be linked by Rust's lld.
|
||||
options=('!lto')
|
||||
backup=('etc/pam.d/ferese-lock')
|
||||
source=('ferese::git+https://github.com/ferese-wm/ferese.git#branch=main')
|
||||
sha256sums=('SKIP')
|
||||
|
||||
pkgver() {
|
||||
cd "$srcdir/ferese"
|
||||
local version
|
||||
version=$(python -c 'import tomllib; print(tomllib.load(open("Cargo.toml", "rb"))["workspace"]["package"]["version"])')
|
||||
printf '%s.r%s.g%s' "${version//-/}" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
|
||||
}
|
||||
|
||||
prepare() {
|
||||
cd "$srcdir/ferese"
|
||||
export CARGO_HOME="$srcdir/cargo-home"
|
||||
cargo fetch --locked
|
||||
}
|
||||
|
||||
build() {
|
||||
cd "$srcdir/ferese"
|
||||
export CARGO_HOME="$srcdir/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
cargo build --release --frozen --offline --workspace
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "$srcdir/ferese"
|
||||
export CARGO_HOME="$srcdir/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
export TZ=UTC
|
||||
export XDG_RUNTIME_DIR="$(mktemp -d)"
|
||||
trap 'rm -r -- "$XDG_RUNTIME_DIR"' EXIT
|
||||
python -m unittest discover -s scripts/tests -p test_package.py
|
||||
dbus-run-session -- cargo test --release --frozen --offline --workspace
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir/ferese"
|
||||
export CARGO_HOME="$srcdir/cargo-home"
|
||||
python scripts/package.py stage --destdir "$pkgdir" --pam arch
|
||||
desktop-file-validate "$pkgdir/usr/share/wayland-sessions/ferese.desktop"
|
||||
desktop-file-validate "$pkgdir/usr/share/applications/dev.ferese.Settings.desktop"
|
||||
}
|
||||
@@ -0,0 +1,78 @@
|
||||
# dwz cannot compress the DWARF 5 sections emitted by Rust. Keep debug files
|
||||
# without the optional DWARF compression pass.
|
||||
%global _find_debuginfo_dwz_opts %{nil}
|
||||
%global upstream_version @UPSTREAM_VERSION@
|
||||
%bcond resize_metrics 0
|
||||
|
||||
Name: ferese
|
||||
Version: @VERSION@
|
||||
Release: 1%{?dist}
|
||||
Summary: Scrolling Wayland desktop
|
||||
# Includes vendored Rust libraries and theme palettes. Full notices ship
|
||||
# under /usr/share/licenses/ferese, including per-dependency SPDX metadata.
|
||||
License: MIT AND Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND BSL-1.0 AND CC0-1.0 AND CDLA-Permissive-2.0 AND ISC AND MPL-2.0 AND Unicode-3.0 AND Unlicense AND Zlib AND OFL-1.1 AND (Apache-2.0 WITH LLVM-exception)
|
||||
URL: https://github.com/ferese-wm/ferese
|
||||
Source0: %{url}/releases/download/v%{upstream_version}/ferese-%{upstream_version}.tar.gz
|
||||
|
||||
BuildRequires: cargo >= 1.95
|
||||
BuildRequires: rust >= 1.95
|
||||
BuildRequires: gcc-c++ cmake make clang clang-devel python3 pkgconf-pkg-config
|
||||
BuildRequires: wayland-devel libxkbcommon-devel libinput-devel systemd-devel libseat-devel
|
||||
BuildRequires: mesa-libgbm-devel mesa-libEGL-devel libdrm-devel fontconfig-devel freetype-devel expat-devel
|
||||
BuildRequires: mesa-dri-drivers mesa-vulkan-drivers
|
||||
BuildRequires: pipewire-devel gstreamer1-devel dbus-daemon desktop-file-utils polkit-libs pam
|
||||
BuildRequires: xorg-x11-xauth
|
||||
Requires: pam polkit polkit-libs foot pipewire wireplumber python3 bash util-linux dbus-daemon dbus-tools systemd
|
||||
Requires: xdg-desktop-portal xdg-desktop-portal-gtk
|
||||
# Loaded at runtime, so ELF dependency detection does not find these libraries.
|
||||
Requires: libEGL.so.1()(64bit) fontconfig freetype
|
||||
Recommends: brightnessctl slurp wl-clipboard satty
|
||||
Recommends: gstreamer1-plugins-base gstreamer1-plugins-good pipewire-gstreamer
|
||||
|
||||
%description
|
||||
Ferese includes a scrolling Wayland compositor, desktop shell, Settings,
|
||||
lock screen, authentication agent and desktop portal in one package.
|
||||
|
||||
%prep
|
||||
%autosetup -n ferese-%{upstream_version}
|
||||
|
||||
%build
|
||||
export CARGO_HOME="$PWD/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
%if %{with resize_metrics}
|
||||
cargo build --release --frozen --offline --workspace --features ferese/resize-metrics
|
||||
%else
|
||||
cargo build --release --frozen --offline --workspace
|
||||
%endif
|
||||
|
||||
%install
|
||||
python3 scripts/package.py stage --destdir "%{buildroot}" --pam fedora
|
||||
desktop-file-validate "%{buildroot}%{_datadir}/wayland-sessions/ferese.desktop"
|
||||
desktop-file-validate "%{buildroot}%{_datadir}/applications/dev.ferese.Settings.desktop"
|
||||
|
||||
%check
|
||||
export CARGO_HOME="$PWD/cargo-home"
|
||||
export CARGO_PROFILE_RELEASE_DEBUG=0
|
||||
export TZ=UTC
|
||||
export XDG_RUNTIME_DIR="$(mktemp -d)"
|
||||
trap 'rm -r -- "$XDG_RUNTIME_DIR"' EXIT
|
||||
python3 -m unittest discover -s scripts/tests -p test_package.py
|
||||
dbus-run-session -- cargo test --release --frozen --offline --workspace
|
||||
|
||||
%files
|
||||
%{_bindir}/ferese*
|
||||
%{_bindir}/xdg-desktop-portal-ferese
|
||||
%{_libexecdir}/ferese/
|
||||
%{_datadir}/ferese/
|
||||
%{_datadir}/wayland-sessions/ferese.desktop
|
||||
%{_datadir}/applications/dev.ferese.Settings.desktop
|
||||
%{_datadir}/icons/hicolor/scalable/apps/ferese.svg
|
||||
%{_datadir}/icons/hicolor/scalable/apps/dev.ferese.Settings.svg
|
||||
%{_datadir}/xdg-desktop-portal/portals/ferese.portal
|
||||
%{_datadir}/xdg-desktop-portal/ferese-portals.conf
|
||||
%{_datadir}/dbus-1/services/org.freedesktop.impl.portal.desktop.ferese.service
|
||||
/usr/lib/systemd/user/ferese-session.target
|
||||
/usr/lib/systemd/user/xdg-desktop-portal-ferese.service
|
||||
%config(noreplace) %{_sysconfdir}/pam.d/ferese-lock
|
||||
%license %{_datadir}/licenses/ferese/
|
||||
%doc %{_datadir}/doc/ferese/
|
||||
@@ -0,0 +1,4 @@
|
||||
#%PAM-1.0
|
||||
# Authenticate the session owner without opening another PAM session.
|
||||
auth include system-auth
|
||||
account include system-auth
|
||||
Reference in new issue
Block a user