]> git.sur5r.net Git - openocd/blob - bootstrap
tcl/target: ti_tms570.cfg restructure dap support
[openocd] / bootstrap
1 #!/bin/sh
2 # Run the autotools bootstrap sequence to create the configure script
3
4 # Abort execution on error
5 set -e
6
7 if which libtoolize > /dev/null; then
8     libtoolize="libtoolize"
9 elif which glibtoolize >/dev/null; then
10     libtoolize="glibtoolize"
11 else
12     echo "$0: Error: libtool is required" >&2
13     exit 1
14 fi
15
16 if [ "$1" = "nosubmodule" ]; then
17     SKIP_SUBMODULE=1
18 elif [ -n "$1" ]; then
19     echo "$0: Illegal argument $1"
20     echo "USAGE: $0 [nosubmodule]"
21     exit 1
22 fi
23
24 # bootstrap the autotools
25 (
26 set -x
27 aclocal
28 ${libtoolize} --automake --copy
29 autoconf
30 autoheader
31 automake --gnu --add-missing --copy
32 )
33
34 if [ -n "$SKIP_SUBMODULE" ]; then
35     echo "Skipping submodule setup"
36 else
37     echo "Setting up submodules"
38     git submodule init
39     git submodule update
40 fi
41
42 if [ -x src/jtag/drivers/libjaylink/autogen.sh ]; then
43     (
44     cd src/jtag/drivers/libjaylink
45     ./autogen.sh
46     )
47 fi
48
49 echo "Bootstrap complete. Quick build instructions:"
50 echo "./configure ...."