diff options
-rw-r--r-- | dev-util/umockdev/Manifest | 1 | ||||
-rw-r--r-- | dev-util/umockdev/files/0.17.12-tests-Skip-umockdev-run-umockdev-record-null-roundtr.patch | 35 | ||||
-rw-r--r-- | dev-util/umockdev/umockdev-0.17.12.ebuild | 57 |
3 files changed, 93 insertions, 0 deletions
diff --git a/dev-util/umockdev/Manifest b/dev-util/umockdev/Manifest index 0a50ce13e851..245b0e55e850 100644 --- a/dev-util/umockdev/Manifest +++ b/dev-util/umockdev/Manifest @@ -1,4 +1,5 @@ DIST umockdev-0.17.10.tar.xz 489200 BLAKE2B 9dcdc2564398ecfb92f6ba7f164b1cced6e0cdb20025025a61d69c654fa1f709c42ec543c313b37961d87d567ce7f287daea82141a7365f7804069e74d55b5ac SHA512 9baad9a6b4ee010ad7b5502da5ba69a23dbdd60164fed7227181607ea12d585936616870962e552a358c4043aea532e6757213c13a7caa9c9fd5979c9b6fef1a +DIST umockdev-0.17.12.tar.xz 489400 BLAKE2B 442887e8a62f8320d544039d87d77b9bff78aa5b0d7639320ed5b40973c21d8e2cc7f9492a96cda7edc3fec50af29b017c1d1be4a85cb99a19599780ba790372 SHA512 034be0705b0990e68dff9741d40012a53064bf3f1be0f414d478d36ed03ca0b0ca08e482e1902e6d424b87471a482d3f2166d811d0f558391ca0a58e1e9e4336 DIST umockdev-0.17.6.tar.xz 486668 BLAKE2B 973c195b8fccd1c080665b65ffd47f8fe110118de9c541d5dda383e51e4dbcc36f77eeda6af5c774f4570a7b839190130fe95559fb3148e9937dae19dace6331 SHA512 05a86e2a583972d02fb3cfa26b017d44600831b6ed1415769d7cc7344357f484d34228b1593de2cfbfcce302611c0c22f045ee9fbd7fea76d8ae0b4ccd28d6ef DIST umockdev-0.17.7.tar.xz 486964 BLAKE2B f3c4021198c8adea47383f3d0c111f921c35550ca9b70c0711e71799ba89a44031356a687b88cc80aa51b1bf4606cfcf48a1d24d16501b0ea08f805e4e30cf83 SHA512 6fc611787c9679f450ce7cdf7dccb93a5d7435470b0b5f5cb1803036cf3c8ce73521af9e7777bec68485834cddfddba0ed9379a0818bfb072bb643cf6419c17d DIST umockdev-0.17.8.tar.xz 487220 BLAKE2B 6a5cb31462ef5836f6a4329fe0e612dd6bb6f00ecc899cb3d1b093771727361bfbc952c7cf7acb7943b78989cacb1faa2d7a2ee62d9c752ed959ac7b1931333c SHA512 e5e6ba2934e1df9323a4e64ee1fc066ab4abeaf75ad0d7f1f6d387b06315f30877f48664e5992f4b138fe1b76d08860359599249d5b9de516777cf8bdb1b228f diff --git a/dev-util/umockdev/files/0.17.12-tests-Skip-umockdev-run-umockdev-record-null-roundtr.patch b/dev-util/umockdev/files/0.17.12-tests-Skip-umockdev-run-umockdev-record-null-roundtr.patch new file mode 100644 index 000000000000..22c8ebc7fb75 --- /dev/null +++ b/dev-util/umockdev/files/0.17.12-tests-Skip-umockdev-run-umockdev-record-null-roundtr.patch @@ -0,0 +1,35 @@ +From 9396f753179ae68bb275072021db95a994bd7273 Mon Sep 17 00:00:00 2001 +From: Martin Pitt <martin@piware.de> +Date: Fri, 20 May 2022 20:19:59 +0200 +Subject: [PATCH] tests: Skip /umockdev-run/umockdev-record-null-roundtrip + +Running stat or any other program crashes in Gentoo's sandbox when +running umockdev-run. Skip this new test for the time being, to avoid a +package build failure. + +Fixes #182 +--- + tests/test-umockdev-run.vala | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/tests/test-umockdev-run.vala b/tests/test-umockdev-run.vala +index 9407ce9..cc9d03d 100644 +--- a/tests/test-umockdev-run.vala ++++ b/tests/test-umockdev-run.vala +@@ -317,6 +317,13 @@ t_run_record_null () + return; + } + ++ // stat or other programs segfault under Gentoo's sandbox in umockdev ++ if (Environ.get_variable(Environ.get(), "SANDBOX_ON") == "1") { ++ stdout.printf ("[SKIP: crashes in Gentoo's sandbox] "); ++ stdout.flush (); ++ return; ++ } ++ + Posix.close (checked_open_tmp ("null.XXXXXX.umockdev", out umockdev_file)); + assert (get_program_out ("true", umockdev_record_command + "/dev/null", out sout, out serr, out exit)); + assert_cmpstr (serr, CompareOperator.EQ, ""); +-- +2.35.1 + diff --git a/dev-util/umockdev/umockdev-0.17.12.ebuild b/dev-util/umockdev/umockdev-0.17.12.ebuild new file mode 100644 index 000000000000..5aa4330d732c --- /dev/null +++ b/dev-util/umockdev/umockdev-0.17.12.ebuild @@ -0,0 +1,57 @@ +# 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 + +DESCRIPTION="Mock hardware devices for creating unit tests" +HOMEPAGE="https://github.com/martinpitt/umockdev/" +SRC_URI="https://github.com/martinpitt/umockdev/releases/download/${PV}/${P}.tar.xz" + +LICENSE="LGPL-2.1+" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +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 +" + +PATCHES=( + "${FILESDIR}"/${PV}-tests-Skip-umockdev-run-umockdev-record-null-roundtr.patch +) + +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 +} |