File tree Expand file tree Collapse file tree 3 files changed +12
-1
lines changed Expand file tree Collapse file tree 3 files changed +12
-1
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- refs/heads/master: cd91c6d065bf4b0688a588cb7ed19ad90aa53b94
2
+ refs/heads/master: 8d7863fad045edff9d9c825b48e72dd022c6fad5
Original file line number Diff line number Diff line change @@ -340,8 +340,12 @@ endif
340
340
# Re-configuration
341
341
# #####################################################################
342
342
343
+ ifndef CFG_DISABLE_MANAGE_SUBMODULES
343
344
# This is a pretty expensive operation but I don't see any way to avoid it
344
345
NEED_GIT_RECONFIG =$(shell cd "$(CFG_SRC_DIR ) " && "$(CFG_GIT ) " submodule status | grep -c '^\(+\|-\) ')
346
+ else
347
+ NEED_GIT_RECONFIG =0
348
+ endif
345
349
346
350
ifeq ($(NEED_GIT_RECONFIG ) ,0)
347
351
else
Original file line number Diff line number Diff line change @@ -253,6 +253,7 @@ opt docs 1 "build documentation"
253
253
opt optimize 1 " build optimized rust code"
254
254
opt optimize-cxx 1 " build optimized C++ code"
255
255
opt optimize-llvm 1 " build optimized LLVM"
256
+ opt manage-submodules 1 " let the build manage the git submodules"
256
257
opt mingw-cross 0 " cross-compile for win32 using mingw"
257
258
opt clang 0 " prefer gcc to clang for building the runtime"
258
259
valopt prefix " /usr/local" " set installation prefix"
@@ -404,11 +405,17 @@ step_msg "configuring submodules"
404
405
# Have to be in the top of src directory for this
405
406
cd ${CFG_SRC_DIR}
406
407
408
+ if [ -z $CFG_DISABLE_MANAGE_SUBMODULES ]
409
+ then
407
410
SUBMODULE_STATUS=$( " ${CFG_GIT} " submodule status)
408
411
NEED_INIT_COUNT=$( echo " $SUBMODULE_STATUS " | grep -c " ^-" )
409
412
NEED_UPDATE_COUNT=$( echo " $SUBMODULE_STATUS " | grep -c " ^+" )
410
413
NEED_INIT=$( test $NEED_INIT_COUNT -gt 0) $?
411
414
NEED_UPDATE=$( test " ($NEED_INIT )" -o " $NEED_UPDATE_COUNT " -gt 0) $?
415
+ else
416
+ NEED_INIT=
417
+ NEED_UPDATE=
418
+ fi
412
419
413
420
if [ $NEED_INIT ]
414
421
then
You can’t perform that action at this time.
0 commit comments