From: Vincent Davis Jr <vince@underview.tech>
To: openembedded-core@lists.openembedded.org
Cc: Vincent Davis Jr <vince@underview.tech>
Subject: [PATCH v3 1/2] spirv-tools: fix INTERFACE_LINK_LIBRARIES cmake prop
Date: Tue, 6 Jun 2023 10:13:35 -0500 [thread overview]
Message-ID: <20230606151335.6019-1-vince@underview.tech> (raw)
The output of spirv-tools specifically SPIRV-ToolsTarget.cmake is
utilized in other recipes. If other recipe utilize cmake and include
SPIRV-Tools in target_link_libraries. I leads to errors such as
error: '../recipe-sysroot/usr/lib',
needed by 'layers/libVkLayer_khronos_validation.so',
missing and no known rule to make it
This is due to cmake pulling in the properties set in
SPIRV-ToolsTarget.cmake. Key property being
INTERFACE_LINK_LIBRARIES.
With the current setup do_install:append:class-target updates
SPIRV-ToolsTarget.cmake package installed file to bellow
set_target_properties(SPIRV-Tools PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include"
INTERFACE_LINK_LIBRARIES "${_IMPORT_PREFIX}/lib"
)
set_target_properties(SPIRV-Tools-shared PROPERTIES
INTERFACE_COMPILE_DEFINITIONS "SPIRV_TOOLS_SHAREDLIB"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include"
INTERFACE_LINK_LIBRARIES "${_IMPORT_PREFIX}/lib"
)
If base_libdir isn't lib, but lib64 you get the error
described at the being of commit message as lib directory
doesn't exists.
Solution replace hardcoded "lib" with "${base_libdir}".
Signed-off-by: Vincent Davis Jr <vince@underview.tech>
---
meta/recipes-graphics/spir/spirv-tools_1.3.243.0.bb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta/recipes-graphics/spir/spirv-tools_1.3.243.0.bb b/meta/recipes-graphics/spir/spirv-tools_1.3.243.0.bb
index c57acc5a11..21f9dd9650 100644
--- a/meta/recipes-graphics/spir/spirv-tools_1.3.243.0.bb
+++ b/meta/recipes-graphics/spir/spirv-tools_1.3.243.0.bb
@@ -32,7 +32,7 @@ do_install:append:class-target() {
# 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:INTERFACE_LINK_LIBRARIES.*$:INTERFACE_LINK_LIBRARIES "\$\{_IMPORT_PREFIX\}/lib":'
+ -e 's:INTERFACE_LINK_LIBRARIES.*$:INTERFACE_LINK_LIBRARIES "\$\{_IMPORT_PREFIX\}\${base_libdir}":'
}
# all the libraries are unversioned, so don't pack it on PN-dev
--
2.34.1
next reply other threads:[~2023-06-06 15:14 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-06 15:13 Vincent Davis Jr [this message]
2023-06-06 15:13 ` [PATCH v3 2/2] vulkan-validation-layers: add new recipe v1.3.243.0 Vincent Davis Jr
2023-06-09 2:11 ` [OE-core] " Khem Raj
2023-06-09 5:20 ` Vincent Davis Jr
2023-06-09 5:58 ` [OE-core] " Khem Raj
2023-06-09 18:41 ` Vincent Davis Jr
2023-06-09 20:57 ` Vincent Davis Jr
2023-06-11 6:55 ` [OE-core] " Khem Raj
2023-06-11 16:39 ` Khem Raj
2023-06-11 17:53 ` Vincent Davis Jr
2023-06-11 17:56 ` Vincent Davis Jr
2023-06-11 20:30 ` Vincent Davis Jr
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=20230606151335.6019-1-vince@underview.tech \
--to=vince@underview.tech \
--cc=openembedded-core@lists.openembedded.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).