diff mbox series

vulkan-validation-layers: cleanup recipe

Message ID 20230611231135.1995485-1-vince@underview.tech
State Under Review
Headers show
Series vulkan-validation-layers: cleanup recipe | expand

Commit Message

Vincent Davis Jr June 11, 2023, 11:11 p.m. UTC
Commit doesn't change build behavior hopefully allows
cmake to find required .cmake files faster.

* Removes ${libdir} from FILES:${PN} as its not required.
* Updates PACKAGECONFIG to uses just one @bb.utils.filter call.
* Updates GLSLANG_INSTALL_DIR to <recipe-sysroot>/lib${64} as
  that contains the actual directory of the glslang .cmake
  config files.
* VULKAN_HEADERS_INSTALL_DIR and SPIRV_HEADERS_INSTALL_DIR
  are updated to <recipe-sysroot>/usr/share from
  <recipe-sysroot>/usr. According to cmake
  "Config Mode Search Procedure" the choosen directory would
  be the second entry list of directories to search when looking
  for .cmake files after first looking into
  CMAKE_FIND_PACKAGE_REDIRECTS_DIR directory.

Signed-off-by: Vincent Davis Jr <vince@underview.tech>
---
 .../vulkan/vulkan-validation-layers_1.3.243.0.bb    | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

Comments

Vincent Davis Jr June 13, 2023, 9:17 p.m. UTC | #1
Sorry, Guys want to cancel this MR. Thought I saw the VulkanHeadersConfig.cmake be located in <recipes-sysroot>/usr/share/cmake when testing on other platforms
and different distro features. Changes to VULKAN_HEADERS_INSTALL_DIR fail in certain configurations.
diff mbox series

Patch

diff --git a/meta/recipes-graphics/vulkan/vulkan-validation-layers_1.3.243.0.bb b/meta/recipes-graphics/vulkan/vulkan-validation-layers_1.3.243.0.bb
index 6e1ef7a05d..c33c543f6f 100644
--- a/meta/recipes-graphics/vulkan/vulkan-validation-layers_1.3.243.0.bb
+++ b/meta/recipes-graphics/vulkan/vulkan-validation-layers_1.3.243.0.bb
@@ -23,22 +23,19 @@  DEPENDS = "vulkan-headers vulkan-loader spirv-headers spirv-tools glslang"
 EXTRA_OECMAKE = "\
     -DBUILD_TESTS=OFF \
     -DUSE_ROBIN_HOOD_HASHING=OFF \
-    -DGLSLANG_INSTALL_DIR=${STAGING_DATADIR} \
-    -DVULKAN_HEADERS_INSTALL_DIR=${STAGING_EXECPREFIXDIR} \
-    -DSPIRV_HEADERS_INSTALL_DIR=${STAGING_EXECPREFIXDIR} \
+    -DGLSLANG_INSTALL_DIR=${STAGING_LIBDIR} \
+    -DVULKAN_HEADERS_INSTALL_DIR=${STAGING_DATADIR} \
+    -DSPIRV_HEADERS_INSTALL_DIR=${STAGING_DATADIR} \
     "
 
 PACKAGECONFIG[x11] = "-DBUILD_WSI_XLIB_SUPPORT=ON -DBUILD_WSI_XCB_SUPPORT=ON, -DBUILD_WSI_XLIB_SUPPORT=OFF -DBUILD_WSI_XCB_SUPPORT=OFF, libxcb libx11 libxrandr"
 PACKAGECONFIG[wayland] = "-DBUILD_WSI_WAYLAND_SUPPORT=ON, -DBUILD_WSI_WAYLAND_SUPPORT=OFF, wayland"
 
-PACKAGECONFIG ?= "\
-    ${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)} \
-    ${@bb.utils.filter('DISTRO_FEATURES', 'wayland', d)} \
-    "
+PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'x11 wayland', d)}"
 
 inherit cmake features_check pkgconfig
 
-FILES:${PN} += "${datadir}/vulkan ${libdir}"
+FILES:${PN} += "${datadir}/vulkan"
 
 SOLIBS = ".so"
 FILES_SOLIBSDEV = ""