summaryrefslogtreecommitdiffstats
path: root/meta/recipes-graphics/spir
diff options
context:
space:
mode:
authorJordan Crouse <jorcrous@amazon.com>2022-11-11 21:47:12 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-11-14 16:19:43 +0000
commit130b55bdf381c5e52bba9a57d074510a30d27929 (patch)
tree7778c3daa3830d0f6465833c6d91e6af044936e8 /meta/recipes-graphics/spir
parent20064a9e2a2785870e56bd38db339f0b57b56731 (diff)
downloadpoky-130b55bdf381c5e52bba9a57d074510a30d27929.tar.gz
spirv-tools: Correctly set the prefix in exported cmake packages
spirv-tools exports Cmake packages. When they are installed the INTERFACE_LINK_LIBRARIES variable is not correctly updated to use _IMPORT_PREFIX like the other variables. This may have something to do with the path to the sysroot being different than the source path. The existing recipe recognizes that the sysroot path made it through to the install and tries to get rid of it, but this just ends up with dependent tools looking in vain for /usr/lib/librt.so. Replace the INTERFACE_LINK_LIBRARIES value in SPIRV-ToolsTarget.cmake with "${IMPORT_PREFIX}/lib". (From OE-Core rev: ca2d6d9164fba91d86357e56617b58eeeeb76d72) Signed-off-by: Jordan Crouse <jorcrous@amazon.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-graphics/spir')
-rw-r--r--meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb5
1 files changed, 3 insertions, 2 deletions
diff --git a/meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb b/meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb
index ea47796543..e175cde145 100644
--- a/meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb
+++ b/meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb
@@ -25,9 +25,10 @@ EXTRA_OECMAKE += "\
25" 25"
26 26
27do_install:append:class-target() { 27do_install:append:class-target() {
28 # reproducibility: remove build host path 28 # Properly set _IMPORT_PREFIX in INTERFACE_LINK_LIBRARIES so that dependent
29 # tools can find the right library
29 sed -i ${D}${libdir}/cmake/SPIRV-Tools/SPIRV-ToolsTarget.cmake \ 30 sed -i ${D}${libdir}/cmake/SPIRV-Tools/SPIRV-ToolsTarget.cmake \
30 -e 's:${STAGING_DIR_HOST}::g' 31 -e 's:INTERFACE_LINK_LIBRARIES.*$:INTERFACE_LINK_LIBRARIES "\$\{_IMPORT_PREFIX\}/lib":'
31} 32}
32 33
33# all the libraries are unversioned, so don't pack it on PN-dev 34# all the libraries are unversioned, so don't pack it on PN-dev