Skip to content

Commit

Permalink
app-misc/piper:drop 0.7, add 0.7-r1, 9999
Browse files Browse the repository at this point in the history
* add 9999 since piper is not update often

Signed-off-by: Gonçalo Negrier Duarte <gonegrier.duarte@gmail.com>
  • Loading branch information
MrDuartePT committed Mar 7, 2024
1 parent 9a47def commit e4872b8
Show file tree
Hide file tree
Showing 2 changed files with 77 additions and 2 deletions.
Expand Up @@ -9,11 +9,17 @@ inherit meson python-single-r1 xdg

DESCRIPTION="GTK application to configure gaming devices"
HOMEPAGE="https://github.com/libratbag/piper"
SRC_URI="https://github.com/libratbag/piper/archive/${PV}.tar.gz -> ${P}.tar.gz"

if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/libratbag/piper.git"
else
SRC_URI="https://github.com/libratbag/piper/archive/${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64"
fi

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64"
IUSE="test"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RESTRICT="!test? ( test )"
Expand Down
69 changes: 69 additions & 0 deletions app-misc/piper/piper-9999.ebuild
@@ -0,0 +1,69 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PYTHON_COMPAT=( python3_{9..11} )

inherit meson python-single-r1 xdg

DESCRIPTION="GTK application to configure gaming devices"
HOMEPAGE="https://github.com/libratbag/piper"

if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/libratbag/piper.git"
else
SRC_URI="https://github.com/libratbag/piper/archive/${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64"
fi

LICENSE="GPL-2"
SLOT="0"
IUSE="test"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RESTRICT="!test? ( test )"

BDEPEND="
${PYTHON_DEPS}
$(python_gen_cond_dep '
dev-python/lxml[${PYTHON_USEDEP}]
')
virtual/pkgconfig
test? (
$(python_gen_cond_dep '
dev-python/flake8[${PYTHON_USEDEP}]
')
dev-libs/appstream
)
"
RDEPEND="
${PYTHON_DEPS}
dev-libs/gobject-introspection
>=dev-libs/libratbag-0.14
gnome-base/librsvg[introspection]
x11-libs/gdk-pixbuf[introspection]
x11-libs/gtk+:3[introspection]
$(python_gen_cond_dep '
dev-python/evdev[${PYTHON_USEDEP}]
dev-python/lxml[${PYTHON_USEDEP}]
dev-python/pycairo[${PYTHON_USEDEP}]
dev-python/pygobject:3[cairo,${PYTHON_USEDEP}]
')
"
DEPEND="
${RDEPEND}
dev-libs/libevdev
virtual/libudev
"

src_configure() {
python_setup
meson_src_configure
}

src_install() {
meson_src_install
python_optimize
python_fix_shebang "${ED}"/usr/bin/
}

0 comments on commit e4872b8

Please sign in to comment.