On Thu, 23 Jul 2026 at 13:21, Sadineni, Harish via
lists.openembedded.org
<[email protected]> wrote:
> Also update `CARGO_TARGET_<TRIPLE>_RUSTFLAGS` to add an explicit
> `-L` search path to the target `rustlib` directory inside the sysroot.
> The path is selected dynamically based on the multilib configuration,
> choosing `lib` for 32-bit targets and `lib64` for 64-bit targets. This
> ensures Cargo can locate the correct target-specific Rust libraries
> during cross-compilation with the cross-canadian toolchain.
...
> +               if echo "${RUST_TARGET_SYS}" | grep -qE '(32)'; then
> +                       LIBDIR="lib"
> +               else
> +                       LIBDIR="lib64"
> +               fi
> +       else
> +               # multilib not enabled
> +               LIBDIR="lib"
> +       fi
> +       
> LIB_PATH="\$OECORE_TARGET_SYSROOT/usr/\${LIBDIR}/rustlib/${RUST_TARGET_SYS}/lib"

Sorry no. Hardcoding libdir names like this is not okay. You need to
find a way to obtain them from original definitions.

Alex
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#241923): 
https://lists.openembedded.org/g/openembedded-core/message/241923
Mute This Topic: https://lists.openembedded.org/mt/120408881/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to