Skip to content

Commit a510d51

Browse files
zapb-0borneoa
authored andcommitted
bootstrap: Do not set up Git submodules by default
Building OpenOCD with jimtcl and libjaylink Git submodules is deprecated and will be removed in the upcoming releases. The remaining 'git2cl' submodule is only required during the OpenOCD release process. Only set up Git submodules when the 'with-submodules' argument is used, for example during the OpenOCD release process or for the transition period until all submodules are replaced by external dependencies. We keep the existing 'nosubmodule' argument in order to not break automatic testing with Jenkins. Change-Id: Ia4fd765e3a2d6b2c40b084a1ffdf919d5f4f35bb Signed-off-by: Marc Schink <[email protected]> Reviewed-on: https://review.openocd.org/c/openocd/+/8381 Tested-by: jenkins Reviewed-by: Antonio Borneo <[email protected]> Reviewed-by: R. Diez <[email protected]>
1 parent 77c904f commit a510d51

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

bootstrap

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,21 @@ else
1515
exit 1
1616
fi
1717

18-
SKIP_SUBMODULE=0
18+
WITH_SUBMODULES=0
1919

2020
case "$#" in
2121
0) ;;
22-
1) if [ "$1" = "nosubmodule" ]; then
23-
SKIP_SUBMODULE=1
24-
else
22+
1) if [ "$1" = "with-submodules" ]; then
23+
WITH_SUBMODULES=1
24+
elif [ "$1" = "nosubmodule" ]; then
25+
WITH_SUBMODULES=0
26+
elif [ -n "$1" ]; then
2527
echo "$0: Illegal argument $1" >&2
26-
echo "USAGE: $0 [nosubmodule]" >&2
28+
echo "USAGE: $0 [with-submodules]" >&2
2729
exit 1
2830
fi;;
2931
*) echo "$0: Wrong number of command-line arguments." >&2
30-
echo "USAGE: $0 [nosubmodule]" >&2
32+
echo "USAGE: $0 [with-submodules]" >&2
3133
exit 1;;
3234
esac
3335

@@ -42,12 +44,12 @@ autoheader --warnings=all
4244
automake --warnings=all --gnu --add-missing --copy
4345
)
4446

45-
if [ "$SKIP_SUBMODULE" -ne 0 ]; then
46-
echo "Skipping submodule setup"
47-
else
47+
if [ "$WITH_SUBMODULES" -ne 0 ]; then
4848
echo "Setting up submodules"
4949
git submodule sync
5050
git submodule update --init
51+
else
52+
echo "Skipping submodule setup"
5153
fi
5254

5355
if [ -x src/jtag/drivers/libjaylink/autogen.sh ]; then

0 commit comments

Comments
 (0)