# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

# Autogenerated by pycargoebuild 0.17.1

EAPI=8

CRATES="
	aho-corasick@1.1.4
	bitflags@2.10.0
	cc@1.2.54
	cfg-if@1.0.4
	downcast-rs@1.2.1
	equivalent@1.0.2
	errno@0.3.14
	fastrand@2.3.0
	find-msvc-tools@0.1.8
	getrandom@0.3.4
	hashbrown@0.16.1
	indexmap@2.13.0
	itoa@1.0.17
	lazy_static@1.5.0
	libc@0.2.180
	linux-raw-sys@0.11.0
	log@0.4.29
	matchers@0.2.0
	memchr@2.7.6
	memmap2@0.8.0
	nu-ansi-term@0.50.3
	once_cell@1.21.3
	pin-project-lite@0.2.16
	pkg-config@0.3.32
	proc-macro2@1.0.106
	quick-xml@0.38.4
	quote@1.0.44
	r-efi@5.3.0
	regex-automata@0.4.14
	regex-lite@0.1.9
	regex-syntax@0.8.9
	rustix@1.1.3
	serde@1.0.228
	serde_core@1.0.228
	serde_derive@1.0.228
	serde_json@1.0.149
	serde_spanned@0.6.9
	sharded-slab@0.1.7
	shlex@1.3.0
	smallvec@1.15.1
	syn@2.0.114
	tempfile@3.24.0
	thread_local@1.1.9
	toml@0.8.23
	toml_datetime@0.6.11
	toml_edit@0.22.27
	toml_write@0.1.2
	tracing-attributes@0.1.31
	tracing-core@0.1.36
	tracing-log@0.2.0
	tracing-subscriber@0.3.22
	tracing@0.1.44
	unicode-ident@1.0.22
	valuable@0.1.1
	wasip2@1.0.2+wasi-0.2.9
	wayland-backend@0.3.12
	wayland-client@0.31.12
	wayland-scanner@0.31.8
	wayland-sys@0.31.8
	windows-link@0.2.1
	windows-sys@0.61.2
	winnow@0.7.14
	wit-bindgen@0.51.0
	xkbcommon@0.7.0
	xkeysym@0.2.1
	zmij@1.0.18
"

RUST_MIN_VER="1.87.0"

inherit cargo optfeature

DESCRIPTION="Tiling window manager with COSMIC/BSPWM layout for River written in Rust"
HOMEPAGE="https://github.com/cap153/rrwm"
SRC_URI="
	https://github.com/cap153/rrwm/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
	${CARGO_CRATE_URIS}
"

LICENSE="MIT"
# Dependent crate licenses
LICENSE+=" MIT Unicode-3.0"
SLOT="0"
KEYWORDS="amd64"

# Rust does not use *FLAGS from make.conf, silence portage warning
# update with proper path to binaries this crate installs, omit leading /
QA_FLAGS_IGNORED="usr/bin/${PN}"
QA_PRESTRIPPED="usr/bin/${PN}"

RDEPEND=">=gui-wm/river-0.4.0"

pkg_postinst() {
	elog ""
	elog "To start RRWM, you can either:"
	elog "'river -c rrwm'"
	elog "or edit '~/.config/river/init' and add 'rrwm &' to start RRWM"
	elog "You can check https://github.com/cap153/rrwm#configuration-example to see conf example."
	elog "Configuration should be located in ~/.config/river and file name should be named as 'rrvm.toml'!"
	elog ""

	optfeature "keyring" gnome-base/gnome-keyring
	optfeature "polkit authentication popup" gnome-extra/polkit-gnome
	optfeature "application launcher" x11-misc/rofi
	optfeature "status bar" gui-apps/waybar
	optfeature "wallpaper utility" gui-apps/swaybg
	optfeature "terminal emulator" x11-terms/kitty
}