summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Turner <mattst88@gentoo.org>2022-05-19 10:28:37 -0400
committerMatt Turner <mattst88@gentoo.org>2022-05-19 10:29:01 -0400
commit6e70941d734c679917ccc15134f5e0e9e0dcda5a (patch)
tree54f705af5eade79b0593cfd598d6c73c02d77163 /dev-util/umockdev
parentapp-backup/duplicity: stabilize 0.8.22 for amd64 (diff)
downloadgentoo-6e70941d734c679917ccc15134f5e0e9e0dcda5a.tar.gz
gentoo-6e70941d734c679917ccc15134f5e0e9e0dcda5a.tar.bz2
gentoo-6e70941d734c679917ccc15134f5e0e9e0dcda5a.zip
dev-util/umockdev: Add a live ebuild
To make upstream testing easier. See https://github.com/martinpitt/umockdev/issues/182 Signed-off-by: Matt Turner <mattst88@gentoo.org>
Diffstat (limited to 'dev-util/umockdev')
-rw-r--r--dev-util/umockdev/umockdev-9999.ebuild59
1 files changed, 59 insertions, 0 deletions
diff --git a/dev-util/umockdev/umockdev-9999.ebuild b/dev-util/umockdev/umockdev-9999.ebuild
new file mode 100644
index 000000000000..b640c8cd11af
--- /dev/null
+++ b/dev-util/umockdev/umockdev-9999.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit meson-multilib python-any-r1 vala
+
+if [[ ${PV} = 9999* ]]; then
+ EGIT_REPO_URI="https://github.com/martinpitt/${PN}.git"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/martinpitt/umockdev/releases/download/${PV}/${P}.tar.xz"
+ KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+fi
+
+DESCRIPTION="Mock hardware devices for creating unit tests"
+HOMEPAGE="https://github.com/martinpitt/umockdev/"
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ net-libs/libpcap[${MULTILIB_USEDEP}]
+ virtual/libudev:=[${MULTILIB_USEDEP}]
+ >=dev-libs/glib-2.32:2[${MULTILIB_USEDEP}]
+ >=dev-libs/gobject-introspection-1.32:=
+"
+DEPEND="${RDEPEND}
+ test? (
+ ${PYTHON_DEPS}
+ dev-libs/libgudev:=[${MULTILIB_USEDEP}]
+ )
+"
+BDEPEND="
+ $(vala_depend)
+ app-arch/xz-utils
+ virtual/pkgconfig
+"
+
+pkg_setup() {
+ use test && python-any-r1_pkg_setup
+}
+
+src_prepare() {
+ default
+ vala_setup
+}
+
+multilib_src_configure() {
+ export VALAC="$(type -P valac-$(vala_best_api_version))"
+ meson_src_configure
+}
+
+multilib_src_test() {
+ meson_src_test --no-suite fails-valgrind
+}