Skip to content

OE/Yocto SDK mitigation#2861

Open
ch-f wants to merge 2 commits intowarmcat:mainfrom
ch-f:yocto_sdk_fix
Open

OE/Yocto SDK mitigation#2861
ch-f wants to merge 2 commits intowarmcat:mainfrom
ch-f:yocto_sdk_fix

Conversation

@ch-f
Copy link
Copy Markdown

@ch-f ch-f commented Apr 1, 2023

When using OE/Yocto to create a SDK/toolchain, the generated LibwebsocketsTargets.cmake falsely contains the host path (build artifacts) in INTERFACE_LINK_LIBRARIES instead of the actually installed SDK path.

This originates from LIBUV_LIBRARIES and OPENSSL_LIBRARIES because they contain the full host path to the libraries instead of just library names (without the '-l').

There might be more full host path for different LWS features.

For reference, a similar report issue is here.

Maybe this mitigation is better addressed at meta-openembedded?

ch-f added 2 commits April 1, 2023 21:29
When using OE/Yocto to create a SDK/toolchain, the generated
LibwebsocketsTargets.cmake falsely contains the host path (build
artifacts) in INTERFACE_LINK_LIBRARIES instead of the actually installed
SDK path.

This host path originates from OPENSSL_LIBRARIES that gives the full
path to the openssl library at build time.

To avoid propagating full build host specific path to generated
LibwebsocketsTargets.cmake, this patch forces to link with ssl and
crypto instead of a full path.
When using OE/Yocto to create a SDK/toolchain, the generated
LibwebsocketsTargets.cmake falsely contains the host path (build
artifacts) in INTERFACE_LINK_LIBRARIES instead of the actually installed
SDK path.

This host path originates from LIBUV_LIBRARIES that gives the full
path to the openssl library at build time.

To avoid propagating full build host specific path to generated
LibwebsocketsTargets.cmake, this patch is using pkg_check_modules().
@lws-team lws-team force-pushed the main branch 10 times, most recently from 4a18968 to c199714 Compare June 19, 2025 05:18
@lws-team lws-team force-pushed the main branch 9 times, most recently from aca2548 to 20263de Compare July 9, 2025 18:51
@lws-team lws-team force-pushed the main branch 6 times, most recently from e028532 to 5867044 Compare August 1, 2025 12:39
@lws-team lws-team force-pushed the main branch 3 times, most recently from 555e80f to 36ef2d6 Compare August 11, 2025 06:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant