This is an automated email from the ASF dual-hosted git repository.

morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-doris.git


The following commit(s) were added to refs/heads/master by this push:
     new 5f28686  [Script] Check if ninja exist in build.sh (#5099)
5f28686 is described below

commit 5f2868667ac51bd9671c94960b0ad86716c99ebb
Author: Zhengguo Yang <[email protected]>
AuthorDate: Sat Dec 19 11:18:50 2020 +0800

    [Script] Check if ninja exist in build.sh (#5099)
    
    Add a check of ninja exist to build.sh
---
 build.sh | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/build.sh b/build.sh
index 6cba4d1..8f52150 100755
--- a/build.sh
+++ b/build.sh
@@ -75,7 +75,6 @@ OPTS=$(getopt \
   -l 'spark-dpp' \
   -l 'clean' \
   -l 'help' \
-  -l 'ninja' \
   -- "$@")
 
 if [ $? != 0 ] ; then
@@ -91,7 +90,6 @@ BUILD_SPARK_DPP=
 CLEAN=
 RUN_UT=
 HELP=0
-USE_NINJA=0
 if [ $# == 1 ] ; then
     # default
     BUILD_BE=1
@@ -115,7 +113,6 @@ else
             --spark-dpp) BUILD_SPARK_DPP=1 ; shift ;;
             --clean) CLEAN=1 ; shift ;;
             --ut) RUN_UT=1   ; shift ;;
-            --ninja) USE_NINJA=1 ; shift ;;
             -h) HELP=1; shift ;;
             --help) HELP=1; shift ;;
             --) shift ;  break ;;
@@ -148,7 +145,6 @@ echo "Get params:
     BUILD_SPARK_DPP     -- $BUILD_SPARK_DPP
     CLEAN               -- $CLEAN
     RUN_UT              -- $RUN_UT
-    USE_NINJA           -- $USE_NINJA
     WITH_MYSQL          -- $WITH_MYSQL
     WITH_LZO            -- $WITH_LZO
 "
@@ -177,7 +173,7 @@ if [ ${BUILD_BE} -eq 1 ] ; then
     cd ${CMAKE_BUILD_DIR}
     GENERATOR="Unix Makefiles"
     BUILD_SYSTEM="make"
-    if [ ${USE_NINJA} -eq 1 ]; then
+    if ninja --version 2>/dev/null; then
         GENERATOR="Ninja"
         BUILD_SYSTEM="ninja"
     fi


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to