From: Jordan Crouse <jorcrous@amazon.com>
To: <openembedded-core@lists.openembedded.org>
Cc: Khem Raj <raj.khem@gmail.com>,
Alexander Kanavin <alex.kanavin@gmail.com>,
Jordan Crouse <jorcrous@amazon.com>
Subject: [PATCH v2 1/3] spirv-tools: Correctly set the prefix in exported cmake packages
Date: Fri, 11 Nov 2022 21:47:12 +0000 [thread overview]
Message-ID: <20221111214714.9939-2-jorcrous@amazon.com> (raw)
In-Reply-To: <20221111214714.9939-1-jorcrous@amazon.com>
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".
Signed-off-by: Jordan Crouse <jorcrous@amazon.com>
---
Changes in v2:
- Don't change PR per Khem Raj
meta/recipes-graphics/spir/spirv-tools_1.3.231.1.bb | 5 +++--
1 file 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 += "\
"
do_install:append:class-target() {
- # reproducibility: remove build host path
+ # Properly set _IMPORT_PREFIX in INTERFACE_LINK_LIBRARIES so that dependent
+ # tools can find the right library
sed -i ${D}${libdir}/cmake/SPIRV-Tools/SPIRV-ToolsTarget.cmake \
- -e 's:${STAGING_DIR_HOST}::g'
+ -e 's:INTERFACE_LINK_LIBRARIES.*$:INTERFACE_LINK_LIBRARIES "\$\{_IMPORT_PREFIX\}/lib":'
}
# all the libraries are unversioned, so don't pack it on PN-dev
--
2.37.1
next prev parent reply other threads:[~2022-11-11 21:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-11 21:47 [PATCH v2 0/3] Add vulkan validation and improvements for headless devices Jordan Crouse
2022-11-11 21:47 ` Jordan Crouse [this message]
2022-11-11 21:47 ` [PATCH v2 2/3] vulkan-loader: Allow headless targets to build the loader Jordan Crouse
2022-11-11 21:47 ` [PATCH v2 3/3] vulkan-validation: Add the official Vulkan validation layers Jordan Crouse
2022-11-13 22:22 ` [OE-core] " Alexandre Belloni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221111214714.9939-2-jorcrous@amazon.com \
--to=jorcrous@amazon.com \
--cc=alex.kanavin@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
--cc=raj.khem@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.