diff --git a/build_client.sh b/build_client.sh index 186c540..81ed881 100755 --- a/build_client.sh +++ b/build_client.sh @@ -6,11 +6,10 @@ tearoot_cmake_config="`pwd`/cmake/config/tearoot-client.cmake" tearoot_cmake_module="`pwd`/cmake/" traroot_library="`pwd`/third_party" -shared_path="client" source scripts/build_helper.sh begin_task "build_client" "Building client" ./client/jenkins/create_build.sh -check_err_exit ${shared_path} "Failed to build client!" +check_err_exit "__build_client" "Failed to build client!" end_task "build_client" "Client build finished" \ No newline at end of file diff --git a/scripts/build_helper.sh b/scripts/build_helper.sh index 3788c39..745f8ba 100644 --- a/scripts/build_helper.sh +++ b/scripts/build_helper.sh @@ -228,7 +228,11 @@ function cmake_build() { function check_err_exit() { error_code=$? [[ ${error_code} -eq 0 || "${error_code}" == "0" ]] && return 0 - echo -e "\e[1;31mFailed to build project $1 at $(realpath $1). Status code: ${error_code}" + if [[ ${1} =~ __* ]]; then + echo -e "\e[1;31mFailed to build project ${1:2}. Status code: ${error_code}" + else + echo -e "\e[1;31mFailed to build project $1 at $(realpath $1). Status code: ${error_code}" + fi [[ ${#@} -gt 1 ]] && echo "${@:2}" echo -e "Aborting build\e[0;39m" exit 1