diff --git a/build.sh b/build.sh index be0413d..515c62c 100755 --- a/build.sh +++ b/build.sh @@ -8,6 +8,7 @@ script_dir=$(cd $(dirname $0);pwd) cd $script_dir echo $script_dir pwd +err=0 mainverstr=$(cat ../sdk/include/huagao/brand.h |grep VERSION_MAIN) mainverstr=${mainverstr: -3} mainverstr=$(echo $mainverstr) @@ -117,10 +118,13 @@ cmake ../code_device make if [ $? -ne 0 ];then - echo "--------------------------------------make fail---------------------------------------" - #exit 1 # commented, we should restore the CMakeLists.txts... + + err=1 + echo "--------------------------------------make fail---------------------------------------" + # commented, we should restore the CMakeLists.txts... else - echo "--------------------------------------make succeed------------------------------------" + err=0 + echo "--------------------------------------make succeed------------------------------------" fi #make @@ -138,3 +142,4 @@ if [ -f ../code_device/hgdriver/wrapper/CMakeLists.txtbkp ]; then pwd fi +exit $err \ No newline at end of file