From 41e13dc2ec42de4897067c6bc2fe08c079932435 Mon Sep 17 00:00:00 2001 From: taoxiangdong Date: Tue, 20 Oct 2020 15:08:46 +0800 Subject: [PATCH] update build.sh --- build.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index 1bc8007e..a07d6b08 100644 --- a/build.sh +++ b/build.sh @@ -120,12 +120,22 @@ build_graphengine() CMAKE_ARGS="${CMAKE_ARGS} -DENABLE_OPEN_SRC=True -DCMAKE_INSTALL_PREFIX=${OUTPUT_PATH}" echo "${CMAKE_ARGS}" cmake ${CMAKE_ARGS} .. + if [0 -ne $?] + then + echo "execute command: cmake ${CMAKE_ARGS} .. failed." + return 1 + fi make ${VERBOSE} -j${THREAD_NUM} && make install + if [ $? -ne 0 ] + then + echo "execute command: make ${VERBOSE} -j${THREAD_NUM} && make install failed." + return 1 + fi echo "GraphEngine build success!" } g++ -v mk_dir ${OUTPUT_PATH} -build_graphengine +build_graphengine || { echo "GraphEngine build failed."; return; } echo "---------------- GraphEngine build finished ----------------" #cp -rf "${BUILD_PATH}/graphengine/"*.so "${OUTPUT_PATH}" #rm -rf "${OUTPUT_PATH}/"libproto*