From: Andreas Sturmlechner Date: Wed, 11 Mar 2020 19:46:54 +0000 (+0100) Subject: dev-util/vulkan-tools: Make USE cube USE requirements explicit X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7135e9d11ee6fa60ebf69235eae502c6b913c7d8;p=gentoo.git dev-util/vulkan-tools: Make USE cube USE requirements explicit Do not enable cube by default (mitigating strict REQUIRED_USE constraint) Fix QA issue (unused cmake variables with USE=-cube) Package-Manager: Portage-2.3.93, Repoman-2.3.20 Signed-off-by: Andreas Sturmlechner Signed-off-by: Matt Turner --- diff --git a/dev-util/vulkan-tools/vulkan-tools-9999.ebuild b/dev-util/vulkan-tools/vulkan-tools-9999.ebuild index e4065eb7f9cb..1d6d8e74d61e 100644 --- a/dev-util/vulkan-tools/vulkan-tools-9999.ebuild +++ b/dev-util/vulkan-tools/vulkan-tools-9999.ebuild @@ -23,9 +23,10 @@ HOMEPAGE="https://github.com/KhronosGroup/Vulkan-Tools" LICENSE="Apache-2.0" SLOT="0" -IUSE="+cube wayland +X" +IUSE="cube wayland +X" -REQUIRED_USE="|| ( X wayland )" +# Cube demo only supports one window system at a time +REQUIRED_USE="!cube? ( || ( X wayland ) ) cube? ( ^^ ( X wayland ) )" BDEPEND="${PYTHON_DEPS} >=dev-util/cmake-3.10.2 @@ -48,12 +49,10 @@ pkg_setup() { /usr/bin/vulkaninfo ) - if use cube; then - MULTILIB_CHOST_TOOLS+=( - /usr/bin/vkcube - /usr/bin/vkcubepp - ) - fi + use cube && MULTILIB_CHOST_TOOLS+=( + /usr/bin/vkcube + /usr/bin/vkcubepp + ) python-any-r1_pkg_setup } @@ -66,26 +65,13 @@ multilib_src_configure() { -DBUILD_WSI_WAYLAND_SUPPORT=$(usex wayland) -DBUILD_WSI_XCB_SUPPORT=$(usex X) -DBUILD_WSI_XLIB_SUPPORT=$(usex X) - -DGLSLANG_INSTALL_DIR="${EPREFIX}/usr" -DVULKAN_HEADERS_INSTALL_DIR="${EPREFIX}/usr" ) - # Upstream only supports one window system at a time - # If X is set at all, even if wayland is set, use X - # - # If -cube is set, the flags we set are ignored, - # so we don't need to consider that - if use X; then - mycmakeargs+=( - -DCUBE_WSI_SELECTION="XCB" - ) - fi - - if ! use X && use wayland; then - mycmakeargs+=( - -DCUBE_WSI_SELECTION="WAYLAND" - ) - fi + use cube && mycmakeargs+=( + -DGLSLANG_INSTALL_DIR="${EPREFIX}/usr" + -DCUBE_WSI_SELECTION=$(usex X XCB WAYLAND) + ) cmake_src_configure }