mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-31 09:08:08 -07:00
```
* Checking whether python3_14 is suitable ...
* dev-lang/python:3.14 ... [ ok ]
* Using python3.14 to build (via PYTHON_COMPAT iteration)
[...]
meson.build:485: WARNING: Skipping integration test due to missing dependencies: No module named 'gi'
meson.build:485:2: ERROR: Fatal warnings enabled, aborting
```
By *default*, tests being skipped are merely a warning nobody notices,
resulting in 37 of 54 tests not being registered. This happened because:
- gen_any_dep takes a single arg, not many, that single arg is a
dependency block
- if we use gen_any_deps, we also need to check if we have them, so even
having them for PYTHON_COMPAT breaks if we *also* have python 3.14
installed
- python is only added as a dependency inside `test? ( ...)` so we
should never have unconditionally done pkg_setup?
The original bug report was likely caused by USE="-native-symlinks", so
the test lister script did not even execve() successfully, hence why
meson errored out at all. Usually it would successfully execve() so it
exiting with failure is handled by meson.build as automagic.
Fixes: 5ca8c25a6a
Bug: https://bugs.gentoo.org/932003
Signed-off-by: Eli Schwartz <eschwartz@gentoo.org>
92 lines
2.0 KiB
Bash
92 lines
2.0 KiB
Bash
# Copyright 1999-2026 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
EAPI=8
|
|
|
|
PYTHON_COMPAT=( python3_1{1..4} )
|
|
inherit linux-info python-any-r1 meson udev
|
|
|
|
DESCRIPTION="Userspace system daemon to enable security levels for Thunderbolt 3"
|
|
HOMEPAGE="https://gitlab.freedesktop.org/bolt/bolt"
|
|
SRC_URI="https://gitlab.freedesktop.org/${PN}/${PN}/-/archive/${PV}/${P}.tar.bz2"
|
|
|
|
LICENSE="LGPL-2.1 GPL-2+"
|
|
SLOT="0"
|
|
KEYWORDS="amd64 ~loong ~riscv ~x86"
|
|
IUSE="selinux test"
|
|
RESTRICT="!test? ( test )"
|
|
|
|
RDEPEND="
|
|
>=dev-libs/glib-2.56.0:2
|
|
virtual/libudev:=
|
|
virtual/udev
|
|
sys-auth/polkit[introspection]
|
|
selinux? ( sec-policy/selinux-thunderbolt )
|
|
"
|
|
DEPEND="
|
|
${RDEPEND}
|
|
test? (
|
|
dev-util/umockdev
|
|
)
|
|
"
|
|
BDEPEND="
|
|
app-text/asciidoc
|
|
dev-util/glib-utils
|
|
virtual/pkgconfig
|
|
test? (
|
|
dev-util/umockdev
|
|
${PYTHON_DEPS}
|
|
$(python_gen_any_dep '
|
|
dev-python/pygobject[${PYTHON_USEDEP}]
|
|
dev-python/dbus-python[${PYTHON_USEDEP}]
|
|
dev-python/python-dbusmock[${PYTHON_USEDEP}]
|
|
')
|
|
)
|
|
"
|
|
|
|
python_check_deps() {
|
|
python_has_version \
|
|
"dev-python/pygobject[${PYTHON_USEDEP}]" \
|
|
"dev-python/dbus-python[${PYTHON_USEDEP}]" \
|
|
"dev-python/python-dbusmock[${PYTHON_USEDEP}]"
|
|
}
|
|
|
|
pkg_setup() {
|
|
if use kernel_linux && kernel_is lt 5 6; then
|
|
CONFIG_CHECK="~THUNDERBOLT"
|
|
ERROR_THUNDERBOLT="This package requires the thunderbolt kernel driver."
|
|
else
|
|
CONFIG_CHECK="~USB4"
|
|
ERROR_USB4="This package requires the USB4 kernel driver for Thunderbolt support."
|
|
fi
|
|
CONFIG_CHECK+=" ~HOTPLUG_PCI"
|
|
ERROR_HOTPLUG_PCI="Thunderbolt requires PCI hotplug support."
|
|
|
|
linux-info_pkg_setup
|
|
use test && python-any-r1_pkg_setup
|
|
}
|
|
|
|
src_configure() {
|
|
local emesonargs=(
|
|
-Dman=true
|
|
--sysconfdir="${EPREFIX}"/etc
|
|
--localstatedir="${EPREFIX}"/var
|
|
--sharedstatedir="${EPREFIX}"/var/lib
|
|
)
|
|
meson_src_configure
|
|
}
|
|
|
|
src_install() {
|
|
meson_src_install
|
|
newinitd "${FILESDIR}"/${PN}.openrc-r1 boltd
|
|
keepdir /var/lib/boltd
|
|
}
|
|
|
|
pkg_postinst() {
|
|
udev_reload
|
|
}
|
|
|
|
pkg_postrm() {
|
|
udev_reload
|
|
}
|