diff options
| author | Chen Qi <Qi.Chen@windriver.com> | 2024-10-09 01:56:47 -0700 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2024-11-26 06:11:30 -0800 |
| commit | e57dc303e1cf5665c0ff1d5b44e5d593538b9559 (patch) | |
| tree | 63a3e68cb3497020d3fc4abe7d2d90d31bc5b9d3 | |
| parent | ddd907e5917eb0de2b1a14a79e560ce8ad4b63db (diff) | |
| download | poky-e57dc303e1cf5665c0ff1d5b44e5d593538b9559.tar.gz | |
toolchain-shar-extract.sh: exit when post-relocate-setup.sh fails
When LD_LIBRARY_PATH is set, post-relocate-setup.sh will fail and
exit properly. But such failure is ignored and the SDK installation
will continue and tell user that things succeed. This is misleading.
So exit immediately if post-relocate-setup.sh fails.
Fixes [Yocto #15586]
(From OE-Core rev: 1ecc2102cc8f4fbcf32c1296e1f7549c774380ac)
Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit c8e2dcc1f71aa33cc6e56dfdebebbe7ef010c944)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
| -rw-r--r-- | meta/files/toolchain-shar-extract.sh | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/files/toolchain-shar-extract.sh b/meta/files/toolchain-shar-extract.sh index 89d30005fd..3b4647fca7 100644 --- a/meta/files/toolchain-shar-extract.sh +++ b/meta/files/toolchain-shar-extract.sh | |||
| @@ -286,6 +286,10 @@ post_relocate="$target_sdk_dir/post-relocate-setup.sh" | |||
| 286 | if [ -e "$post_relocate" ]; then | 286 | if [ -e "$post_relocate" ]; then |
| 287 | $SUDO_EXEC sed -e "s:@SDKPATH@:$target_sdk_dir:g" -i $post_relocate | 287 | $SUDO_EXEC sed -e "s:@SDKPATH@:$target_sdk_dir:g" -i $post_relocate |
| 288 | $SUDO_EXEC /bin/sh $post_relocate "$target_sdk_dir" "@SDKPATH@" | 288 | $SUDO_EXEC /bin/sh $post_relocate "$target_sdk_dir" "@SDKPATH@" |
| 289 | if [ $? -ne 0 ]; then | ||
| 290 | echo "Executing $post_relocate failed" | ||
| 291 | exit 1 | ||
| 292 | fi | ||
| 289 | $SUDO_EXEC rm -f $post_relocate | 293 | $SUDO_EXEC rm -f $post_relocate |
| 290 | fi | 294 | fi |
| 291 | 295 | ||
