Something went wrong. Try again.
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173%bcond_without check
%global cargo_install_lib 0
# We want panic backtraces to work without installing the debuginfo package,# so we leave the debuginfo in the main binary.%global debug_package %{nil}%global __strip /bin/true
# To reduce the file size, do some convincing of rust-srpm-macros# to leave alone the chosen debug settings from Cargo.toml.%global rustflags_debuginfo please-remove-me%global build_rustflags %{shrink: -Copt-level=%rustflags_opt_level -Ccodegen-units=%rustflags_codegen_units -Cstrip=none %{expr:0%{?_include_frame_pointers} && ("%{_arch}" != "ppc64le" && "%{_arch}" != "s390x" && "%{_arch}" != "i386") ? "-Cforce-frame-pointers=yes" : ""} -Clink-arg=-Wl,-z,relro -Clink-arg=-Wl,-z,now %[0%{?_package_note_status} ? "-Clink-arg=%_package_note_flags" : ""] --cap-lints=warn}
# Convince rust-srpm-macros to use Cargo.lock with the Smithay commit.%global __cargo_common_opts %{?_smp_mflags} -Z avoid-dev-deps --locked
%global version {{{ git_dir_version }}}
Name: niriVersion: %{version}Release: 1%{?dist}Summary: Scrollable-tiling Wayland compositor
SourceLicense: GPL-3.0-or-later
# (MIT OR Apache-2.0) AND BSD-3-Clause# (MIT OR Apache-2.0) AND Unicode-3.0# 0BSD OR MIT OR Apache-2.0# Apache-2.0# Apache-2.0 AND MIT# Apache-2.0 OR MIT# Apache-2.0 OR MIT OR Unlicense# Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT# BSD-2-Clause# BSD-2-Clause OR Apache-2.0 OR MIT# BSD-3-Clause OR MIT OR Apache-2.0# GPL-3.0-or-later# ISC# MIT# MIT OR Apache-2.0# MIT OR Apache-2.0 OR LGPL-2.1-or-later# MIT OR Apache-2.0 OR Zlib# MIT OR Zlib OR Apache-2.0# MPL-2.0# Unlicense OR MIT# Zlib# Zlib OR Apache-2.0 OR MITLicense: ((MIT OR Apache-2.0) AND BSD-3-Clause) AND ((MIT OR Apache-2.0) AND Unicode-3.0) AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 AND MIT) AND (Apache-2.0 OR MIT) AND (Apache-2.0 OR MIT OR Unlicense) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-2-Clause AND (BSD-2-Clause OR Apache-2.0 OR MIT) AND (BSD-3-Clause OR MIT OR Apache-2.0) AND GPL-3.0-or-later AND ISC AND MIT AND (MIT OR Apache-2.0) AND (MIT OR Apache-2.0 OR LGPL-2.1-or-later) AND (MIT OR Apache-2.0 OR Zlib) AND (MIT OR Zlib OR Apache-2.0) AND MPL-2.0 AND (Unlicense OR MIT) AND Zlib AND (Zlib OR Apache-2.0 OR MIT)# LICENSE.dependencies contains a full license breakdown
URL: https://github.com/niri-wm/niriVCS: {{{ git_dir_vcs }}}Source: {{{ git_dir_pack }}}
BuildRequires: cargo-rpm-macros >= 26BuildRequires: pkgconfig(udev)BuildRequires: pkgconfig(gbm)BuildRequires: pkgconfig(xkbcommon)BuildRequires: wayland-develBuildRequires: pkgconfig(libinput)BuildRequires: pkgconfig(dbus-1)BuildRequires: pkgconfig(systemd)BuildRequires: pkgconfig(libseat)BuildRequires: pkgconfig(libdisplay-info)BuildRequires: pipewire-develBuildRequires: pango-develBuildRequires: cairo-gobject-devel# Needed for pipewire-rsBuildRequires: clang# Needed for some tests with a surfaceless EGL rendererBuildRequires: mesa-libEGL
Requires: mesa-dri-driversRequires: mesa-libEGL
# Loaded through dlopenRequires: libwayland-server
# Integrated Xwayland support. Not packaged on EPEL%if 0%{?fedora}Requires: xwayland-satellite >= 0.7%endif
# Portal implementations used by niriRecommends: xdg-desktop-portal-gtkRecommends: xdg-desktop-portal-gnomeRecommends: gnome-keyring
# Suggested utilities, bound in the default configRecommends: alacrittyRecommends: fuzzelRecommends: swaylockRecommends: waybar# Suggested utilitiesRecommends: swaybgRecommends: makoRecommends: swayidle
%descriptionA scrollable-tiling Wayland compositor.
Windows are arranged in columns on an infinite strip going to the right.Opening a new window never causes existing windows to resize.
%prep{{{ git_dir_setup_macro }}}
%cargo_prep -N
# We're doing an online build.sed -i 's/^offline = true$//' .cargo/config.toml
# Final step in leaving alone our debug settings.sed -i 's/.*please-remove-me$//' .cargo/config.toml
# Set the commit string.sed -i 's/\[env\]/[env]\nNIRI_BUILD_COMMIT="%{version}"/' .cargo/config.toml
%build%cargo_build
target/rpm/niri completions bash > ./niritarget/rpm/niri completions fish > ./niri.fishtarget/rpm/niri completions zsh > ./_niri
%install%cargo_install
install -Dm755 -t %{buildroot}%{_bindir} ./resources/niri-sessioninstall -Dm644 -t %{buildroot}%{_datadir}/wayland-sessions ./resources/niri.desktopinstall -Dm644 -t %{buildroot}%{_datadir}/xdg-desktop-portal ./resources/niri-portals.confinstall -Dm644 -t %{buildroot}%{_userunitdir} ./resources/niri.serviceinstall -Dm644 -t %{buildroot}%{_userunitdir} ./resources/niri-shutdown.target
install -Dm644 -t %{buildroot}%{bash_completions_dir} ./niriinstall -Dm644 -t %{buildroot}%{fish_completions_dir} ./niri.fishinstall -Dm644 -t %{buildroot}%{zsh_completions_dir} ./_niri
%if %{with check}%check%cargo_test -- --workspace --exclude niri-visual-tests%endif
%files%license LICENSE%doc README.md%doc resources/default-config.kdl%doc docs/wiki%{_bindir}/niri%{_bindir}/niri-session%{_datadir}/wayland-sessions/niri.desktop%dir %{_datadir}/xdg-desktop-portal%{_datadir}/xdg-desktop-portal/niri-portals.conf%{_userunitdir}/niri.service%{_userunitdir}/niri-shutdown.target%{bash_completions_dir}/niri%{fish_completions_dir}/niri.fish%{zsh_completions_dir}/_niri
%changelog{{{ git_dir_changelog }}}