Install this version:
emerge -a =gui-apps/espanso-2.4.0
If this version is masked, you can unmask it using the autounmask tool or standard emerge options:
autounmask =gui-apps/espanso-2.4.0
Or alternatively:
emerge --autounmask-write -a =gui-apps/espanso-2.4.0
| Version | EAPI | Keywords | Slot |
|---|---|---|---|
| 2.4.0 | 8 | ~amd64 | 0 |
# Copyright 2023-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
RUST_MIN_VER="1.85.0"
inherit cargo desktop fcaps linux-info systemd xdg
DESCRIPTION="Cross-platform Text Expander written in Rust"
HOMEPAGE="https://espanso.org"
SRC_URI="https://github.com/espanso/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
DEPS_URI="https://github.com/gentoo-crate-dist/${PN}/releases/download/v${PV}/${P}-crates.tar.xz"
SRC_URI+=" ${DEPS_URI}"
LICENSE="GPL-3"
# Dependent crate licenses
LICENSE+=" Apache-2.0 BSD-2 BSD CC0-1.0 ISC MIT MPL-2.0 ZLIB"
SLOT="0"
KEYWORDS="~amd64"
IUSE="wayland"
DEPEND="
acct-group/input
dev-libs/openssl
sys-apps/dbus
x11-libs/wxGTK
wayland? (
x11-libs/libxkbcommon[wayland]
)
!wayland? (
x11-libs/libX11
x11-libs/libxcb
x11-libs/libXtst
x11-libs/libxkbcommon[X]
)
"
RDEPEND="${DEPEND}"
QA_FLAGS_IGNORED="usr/bin/${PN}"
pkg_setup() {
CONFIG_CHECK="~INPUT_UINPUT"
ERROR_INPUT_UINPUT="Espanso with Wayland needs the UINPUT"
ERROR_INPUT_UINPUT+=" input device driver to detect user inputs. Without it,"
ERROR_INPUT_UINPUT+=" Espanso will not work as intended"
# Now do the actual checks setup above, but only when using wayland
use wayland && linux-info_pkg_setup
rust_pkg_setup
}
src_configure() {
local myfeatures=(
modulo
native-tls
$(usev wayland)
)
cargo_src_configure --verbose --no-default-features
}
src_compile() {
cargo_src_compile -p "${PN}"
}
src_install() {
cargo_src_install --path "${PN}"
newicon -s 128 "espanso/src/res/linux/icon.png" "${PN}.png"
domenu "espanso/src/res/linux/${PN}.desktop"
# install the systemd-service (user level)
sed -i "s|{{{espanso_path}}}|/usr/bin/espanso|g" "espanso/src/res/linux/systemd.service" || die
systemd_newuserunit "espanso/src/res/linux/systemd.service" "${PN}.service"
}
pkg_postinst() {
# See https://espanso.org/docs/install/linux/#adding-the-required-capabilities
use wayland && fcaps cap_dac_override "usr/bin/${PN}"
}
Manage flags for this package:
euse -i <flag> -p gui-apps/espanso |
euse -E <flag> -p gui-apps/espanso |
euse -D <flag> -p gui-apps/espanso
acct-group/input dev-libs/openssl sys-apps/dbus x11-libs/wxGTK wayland? ( x11-libs/libxkbcommon[wayland] ) !wayland? ( x11-libs/libX11 x11-libs/libxcb x11-libs/libXtst x11-libs/libxkbcommon[X] )
acct-group/input dev-libs/openssl sys-apps/dbus x11-libs/wxGTK wayland? ( x11-libs/libxkbcommon[wayland] ) !wayland? ( x11-libs/libX11 x11-libs/libxcb x11-libs/libXtst x11-libs/libxkbcommon[X] )
| Type | File | Size | Source URLs |
|---|---|---|---|
| DIST | espanso-2.4.0-crates.tar.xz | 36958564 bytes | https://github.com/gentoo-crate-dist/espanso/releases/download/v2.4.0/espanso-2.4.0-crates.tar.xz |
| DIST | espanso-2.4.0.tar.gz | 73127300 bytes | https://github.com/espanso/espanso/archive/refs/tags/v2.4.0.tar.gz |