Skip to content

Commit

Permalink
gui-libs/gtk: Dependency fixes, test running tweaks
Browse files Browse the repository at this point in the history
* Add missing libdrm and linux-headers linux build deps.
* Fix minimum required vulkan version.
* examples automagically depend on librsvg - just pull it in for them, as the
  circular dep with librsvg is mostly a thing of the past.
* Depend on either gles2 or opengl gst-plugins-base, as former is preferred
  nowadays and the dep didn't allow avoiding the latter. Either will provide
  the necessary for gtk[gstreamer] gstreamer-gl-1.0.pc package.
* Add media-libs/gstreamer dep for correctness and avoiding a iwdevtools warn.
* Leave a note about zero-copy dmabuf video playback build-time conditional
  dependending on gstreamer-1.23 for later minimum dep raising.
* Drop obsolete at-spi2-core dependency - gtk has its own copy of everything
  it needs.
* Clarify librsvg PDEPEND comment, as it's only for wd40 profiles, as rust
  librsvg doesn't ship the tool behind USE=tools that links to gtk, where
  that probably even was GTK 3, not GTK 4. Also SLOT depend just in case.
* Tweak the meson test parameters to match upstream CI setup a bit more in
  terms of skipped test suites for a lesser chance of expected failures
  being hit. The tests are still rather dependent on installed fonts, the
  graphics driver used and so on, but lets see how it fares for others.

Signed-off-by: Mart Raudsepp <[email protected]>
  • Loading branch information
leio committed Apr 28, 2024
1 parent 298aa95 commit 653816f
Showing 1 changed file with 28 additions and 7 deletions.
35 changes: 28 additions & 7 deletions gui-libs/gtk/gtk-4.14.3.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ REQUIRED_USE="

KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"

# TODO: Optional gst build dep on >=gst-plugins-base-1.23.1, so depend on it once we can
COMMON_DEPEND="
>=dev-libs/glib-2.76.0:2
>=x11-libs/cairo-1.17.6[aqua?,glib,svg(+),X?]
Expand All @@ -36,20 +37,24 @@ COMMON_DEPEND="
cloudproviders? ( net-libs/libcloudproviders )
colord? ( >=x11-misc/colord-0.1.9:0= )
cups? ( >=net-print/cups-2.0 )
examples? ( gnome-base/librsvg:2 )
gstreamer? (
>=media-libs/gstreamer-1.12.3:1.0
>=media-libs/gst-plugins-bad-1.12.3:1.0
>=media-libs/gst-plugins-base-1.12.3:1.0[opengl]
|| (
>=media-libs/gst-plugins-base-1.12.3:1.0[gles2]
>=media-libs/gst-plugins-base-1.12.3:1.0[opengl]
)
)
introspection? ( >=dev-libs/gobject-introspection-1.76:= )
vulkan? ( media-libs/vulkan-loader:= )
vulkan? ( >=media-libs/vulkan-loader-1.3:= )
wayland? (
>=dev-libs/wayland-1.21.0
>=dev-libs/wayland-protocols-1.31
media-libs/mesa[wayland]
>=x11-libs/libxkbcommon-0.2
)
X? (
>=app-accessibility/at-spi2-core-2.46.0
media-libs/fontconfig
media-libs/mesa[X(+)]
x11-libs/libX11
Expand All @@ -63,15 +68,19 @@ COMMON_DEPEND="
)
"
DEPEND="${COMMON_DEPEND}
kernel_linux? (
x11-libs/libdrm
sys-kernel/linux-headers
)
sysprof? ( >=dev-util/sysprof-capture-3.40.1:4 )
X? ( x11-base/xorg-proto )
"
RDEPEND="${COMMON_DEPEND}
>=dev-util/gtk-update-icon-cache-3
"
# librsvg for svg icons (PDEPEND to avoid circular dep), bug #547710
# librsvg for svg icons (PDEPEND to avoid circular dep on wd40 profiles with librsvg[tools]), bug #547710
PDEPEND="
gnome-base/librsvg
gnome-base/librsvg:2
>=x11-themes/adwaita-icon-theme-3.14
"
BDEPEND="
Expand Down Expand Up @@ -177,7 +186,13 @@ src_test() {

if use X; then
einfo "Running tests under X"
GSETTINGS_SCHEMA_DIR="${S}/gtk" virtx meson_src_test --setup=x11 --timeout-multiplier=130
GSETTINGS_SCHEMA_DIR="${S}/gtk" virtx meson_src_test --timeout-multiplier=130 \
--setup=x11 \
--no-suite=failing \
--no-suite=x11_failing \
--no-suite=flaky \
--no-suite=headless \
--no-suite=gsk-compare-broadway
fi

if use wayland; then
Expand All @@ -189,7 +204,13 @@ src_test() {
compositor=$!
export WAYLAND_DISPLAY=wayland-5

GSETTINGS_SCHEMA_DIR="${S}/gtk" meson_src_test --setup=wayland --timeout-multiplier=130
GSETTINGS_SCHEMA_DIR="${S}/gtk" meson_src_test --timeout-multiplier=130 \
--setup=wayland \
--no-suite=failing \
--no-suite=wayland_failing \
--no-suite=flaky \
--no-suite=headless \
--no-suite=gsk-compare-broadway

exit_code=$?
kill ${compositor}
Expand Down

0 comments on commit 653816f

Please sign in to comment.