summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rust/files
diff options
context:
space:
mode:
authorSundeep KOKKONDA <sundeep.kokkonda@gmail.com>2022-09-07 07:48:17 +0530
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-09-07 08:53:50 +0100
commitdd8fd17a1ba1dee2900ee6efd1d658d56802972b (patch)
tree6d979fad563338dae56659d1d36adeba5caaa824 /meta/recipes-devtools/rust/files
parent1e2b9bafd4a86c212ef2096ae1410ff0c565db91 (diff)
downloadpoky-dd8fd17a1ba1dee2900ee6efd1d658d56802972b.tar.gz
rust-cross-canadian: Fix for the issue caused by using sdk shell
This is a fix for the fix in YOCTO #14878. When the shebang is more than 128 characters the default shell /bin/sh is used instead of SDK shell as a fallback, which causes problems with LD_LIBRARY_PATH. With this patch shell usage is avoided as we use a C wrapper and unset LD_LIBRARY_PATH that way. [YOCTO #14892] (From OE-Core rev: 7cd6faf4e0147eef557f83fb266a25935e26efff) Signed-off-by: Sundeep KOKKONDA <sundeep.kokkonda@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rust/files')
-rw-r--r--meta/recipes-devtools/rust/files/target-rust-ccld.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rust/files/target-rust-ccld.c b/meta/recipes-devtools/rust/files/target-rust-ccld.c
new file mode 100644
index 0000000000..d3d491fb60
--- /dev/null
+++ b/meta/recipes-devtools/rust/files/target-rust-ccld.c
@@ -0,0 +1,19 @@
1/*
2*
3* Copyright (C) 2022 Wind River Systems
4*
5* SPDX-License-Identifier: MIT
6*
7*/
8
9#include <string.h>
10#include <stdlib.h>
11#include <unistd.h>
12
13int main (int argc, char *argv[])
14{
15 unsetenv("LD_LIBRARY_PATH");
16 execvp("target-rust-ccld-wrapper", argv);
17
18 return 0;
19}