Skip to content

Commit b324ff3

Browse files
committed
add --update-submodule to build.sh
1 parent 0bb40e0 commit b324ff3

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

build.sh

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ Usage: $0 <options>
4848
--spark-dpp build Spark DPP application. Default ON.
4949
--hive-udf build Hive UDF library for Spark Load. Default ON.
5050
--be-java-extensions build Backend java extensions. Default ON.
51+
--update-submodule update git submodule
5152
--clean clean and build target
5253
--output specify the output directory
5354
-j build Backend parallel
@@ -123,6 +124,7 @@ if ! OPTS="$(getopt \
123124
-l 'spark-dpp' \
124125
-l 'hive-udf' \
125126
-l 'be-java-extensions' \
127+
-l 'update-submodule' \
126128
-l 'clean' \
127129
-l 'coverage' \
128130
-l 'help' \
@@ -144,6 +146,7 @@ BUILD_INDEX_TOOL='OFF'
144146
BUILD_SPARK_DPP=0
145147
BUILD_BE_JAVA_EXTENSIONS=0
146148
BUILD_HIVE_UDF=0
149+
UPDATE_SUBMODULE=0
147150
CLEAN=0
148151
HELP=0
149152
PARAMETER_COUNT="$#"
@@ -204,6 +207,10 @@ else
204207
BUILD_BE_JAVA_EXTENSIONS=1
205208
shift
206209
;;
210+
--update-submodule)
211+
UPDATE_SUBMODULE=1
212+
shift
213+
;;
207214
--clean)
208215
CLEAN=1
209216
shift
@@ -293,8 +300,11 @@ update_submodule() {
293300
fi
294301
}
295302

296-
update_submodule "be/src/apache-orc" "apache-orc" "https://github.com/apache/doris-thirdparty/archive/refs/heads/orc.tar.gz"
297-
update_submodule "be/src/clucene" "clucene" "https://github.com/apache/doris-thirdparty/archive/refs/heads/clucene.tar.gz"
303+
echo "UPDATE_SUBMODULE ${UPDATE_SUBMODULE}"
304+
if [[ "${UPDATE_SUBMODULE}" -eq 1 ]]; then
305+
update_submodule "be/src/apache-orc" "apache-orc" "https://github.com/apache/doris-thirdparty/archive/refs/heads/orc.tar.gz"
306+
update_submodule "be/src/clucene" "clucene" "https://github.com/apache/doris-thirdparty/archive/refs/heads/clucene.tar.gz"
307+
fi
298308

299309
if [[ "${CLEAN}" -eq 1 && "${BUILD_BE}" -eq 0 && "${BUILD_FE}" -eq 0 && "${BUILD_SPARK_DPP}" -eq 0 ]]; then
300310
clean_gensrc

0 commit comments

Comments
 (0)