From 17dd0d49da96e8043ed244a480de0a48b0b116fd Mon Sep 17 00:00:00 2001 From: Wolfgang Grandegger Date: Sat, 22 Jul 2017 13:15:41 +0200 Subject: [PATCH] support/scripts/fix-rpath: check if the patchelf utility is executable Signed-off-by: Wolfgang Grandegger Reviewed-by: Arnout Vandecappelle (Essensium/Mind) Signed-off-by: Thomas Petazzoni --- support/scripts/fix-rpath | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/support/scripts/fix-rpath b/support/scripts/fix-rpath index f7c70b7c7e..f92e6013da 100755 --- a/support/scripts/fix-rpath +++ b/support/scripts/fix-rpath @@ -45,6 +45,9 @@ Environment: TOOLCHAIN_EXTERNAL_DOWNLOAD_INSTALL_DIR (default HOST_DIR/opt/ext-toolchain) + +Returns: 0 if success or 1 in case of error + EOF } @@ -60,6 +63,11 @@ main() { local find_args=( ) local sanitize_extra_args=( ) + if ! "${PATCHELF}" --version > /dev/null 2>&1; then + echo "Error: can't execute patchelf utility '${PATCHELF}'" + exit 1 + fi + case "${tree}" in host) rootdir="${HOST_DIR}" -- 2.30.2