diff options
| author | Glenn Morris | 2017-01-11 15:01:28 -0500 |
|---|---|---|
| committer | Glenn Morris | 2017-01-11 15:01:28 -0500 |
| commit | d40073f017ffb3dee2266f356c127ef587c40b71 (patch) | |
| tree | dbb77f88f8ff6a2f2ee007d00c96d2a98b8f2128 | |
| parent | 255f675d890b7fa2dc97a40dc03e82fa95b22e65 (diff) | |
| download | emacs-d40073f017ffb3dee2266f356c127ef587c40b71.tar.gz emacs-d40073f017ffb3dee2266f356c127ef587c40b71.zip | |
* autogen.sh: Add --no-check option. (Bug#25359)
| -rwxr-xr-x | autogen.sh | 89 |
1 files changed, 47 insertions, 42 deletions
diff --git a/autogen.sh b/autogen.sh index 2021c771fc8..8679db78fd5 100755 --- a/autogen.sh +++ b/autogen.sh | |||
| @@ -103,6 +103,7 @@ check_version () | |||
| 103 | return 2 | 103 | return 2 |
| 104 | } | 104 | } |
| 105 | 105 | ||
| 106 | do_check=true | ||
| 106 | do_autoconf=false | 107 | do_autoconf=false |
| 107 | test $# -eq 0 && do_autoconf=true | 108 | test $# -eq 0 && do_autoconf=true |
| 108 | do_git=false | 109 | do_git=false |
| @@ -111,6 +112,9 @@ for arg; do | |||
| 111 | case $arg in | 112 | case $arg in |
| 112 | --help) | 113 | --help) |
| 113 | exec echo "$0: usage: $0 [all|autoconf|git]";; | 114 | exec echo "$0: usage: $0 [all|autoconf|git]";; |
| 115 | --no-check) | ||
| 116 | do_check=false | ||
| 117 | test $# -eq 1 && do_autoconf=true;; | ||
| 114 | all) | 118 | all) |
| 115 | do_autoconf=true | 119 | do_autoconf=true |
| 116 | test -e .git && do_git=true;; | 120 | test -e .git && do_git=true;; |
| @@ -128,66 +132,68 @@ done | |||
| 128 | 132 | ||
| 129 | if $do_autoconf; then | 133 | if $do_autoconf; then |
| 130 | 134 | ||
| 131 | echo 'Checking whether you have the necessary tools... | 135 | if $do_check; then |
| 136 | |||
| 137 | echo 'Checking whether you have the necessary tools... | ||
| 132 | (Read INSTALL.REPO for more details on building Emacs)' | 138 | (Read INSTALL.REPO for more details on building Emacs)' |
| 133 | 139 | ||
| 134 | missing= | 140 | missing= |
| 135 | 141 | ||
| 136 | for prog in $progs; do | 142 | for prog in $progs; do |
| 137 | 143 | ||
| 138 | sprog=`echo "$prog" | sed 's/-/_/g'` | 144 | sprog=`echo "$prog" | sed 's/-/_/g'` |
| 139 | 145 | ||
| 140 | eval min=\$${sprog}_min | 146 | eval min=\$${sprog}_min |
| 141 | 147 | ||
| 142 | echo "Checking for $prog (need at least version $min)..." | 148 | echo "Checking for $prog (need at least version $min)..." |
| 143 | 149 | ||
| 144 | check_version $prog $min | 150 | check_version $prog $min |
| 145 | 151 | ||
| 146 | retval=$? | 152 | retval=$? |
| 147 | 153 | ||
| 148 | case $retval in | 154 | case $retval in |
| 149 | 0) stat="ok" ;; | 155 | 0) stat="ok" ;; |
| 150 | 1) stat="missing" ;; | 156 | 1) stat="missing" ;; |
| 151 | 2) stat="too old" ;; | 157 | 2) stat="too old" ;; |
| 152 | *) stat="unable to check" ;; | 158 | *) stat="unable to check" ;; |
| 153 | esac | 159 | esac |
| 154 | 160 | ||
| 155 | echo $stat | 161 | echo $stat |
| 156 | 162 | ||
| 157 | if [ $retval -ne 0 ]; then | 163 | if [ $retval -ne 0 ]; then |
| 158 | missing="$missing $prog" | 164 | missing="$missing $prog" |
| 159 | eval ${sprog}_why=\""$stat"\" | 165 | eval ${sprog}_why=\""$stat"\" |
| 160 | fi | 166 | fi |
| 161 | 167 | ||
| 162 | done | 168 | done |
| 163 | 169 | ||
| 164 | 170 | ||
| 165 | if [ x"$missing" != x ]; then | 171 | if [ x"$missing" != x ]; then |
| 166 | 172 | ||
| 167 | echo ' | 173 | echo ' |
| 168 | Building Emacs from the repository requires the following specialized programs:' | 174 | Building Emacs from the repository requires the following specialized programs:' |
| 169 | 175 | ||
| 170 | for prog in $progs; do | 176 | for prog in $progs; do |
| 171 | sprog=`echo "$prog" | sed 's/-/_/g'` | 177 | sprog=`echo "$prog" | sed 's/-/_/g'` |
| 172 | 178 | ||
| 173 | eval min=\$${sprog}_min | 179 | eval min=\$${sprog}_min |
| 174 | 180 | ||
| 175 | echo "$prog (minimum version $min)" | 181 | echo "$prog (minimum version $min)" |
| 176 | done | 182 | done |
| 177 | 183 | ||
| 178 | 184 | ||
| 179 | echo ' | 185 | echo ' |
| 180 | Your system seems to be missing the following tool(s):' | 186 | Your system seems to be missing the following tool(s):' |
| 181 | 187 | ||
| 182 | for prog in $missing; do | 188 | for prog in $missing; do |
| 183 | sprog=`echo "$prog" | sed 's/-/_/g'` | 189 | sprog=`echo "$prog" | sed 's/-/_/g'` |
| 184 | 190 | ||
| 185 | eval why=\$${sprog}_why | 191 | eval why=\$${sprog}_why |
| 186 | 192 | ||
| 187 | echo "$prog ($why)" | 193 | echo "$prog ($why)" |
| 188 | done | 194 | done |
| 189 | 195 | ||
| 190 | echo ' | 196 | echo ' |
| 191 | If you think you have the required tools, please add them to your PATH | 197 | If you think you have the required tools, please add them to your PATH |
| 192 | and re-run this script. | 198 | and re-run this script. |
| 193 | 199 | ||
| @@ -208,18 +214,17 @@ make install. Add the installation directory to your PATH and re-run | |||
| 208 | this script. | 214 | this script. |
| 209 | 215 | ||
| 210 | If you know that the required versions are in your PATH, but this | 216 | If you know that the required versions are in your PATH, but this |
| 211 | script has made an error, then you can simply run | 217 | script has made an error, then you can simply re-run this script with |
| 212 | 218 | the --no-check option. | |
| 213 | autoreconf -fi -I m4 | ||
| 214 | |||
| 215 | instead of this script. | ||
| 216 | 219 | ||
| 217 | Please report any problems with this script to bug-gnu-emacs@gnu.org .' | 220 | Please report any problems with this script to bug-gnu-emacs@gnu.org .' |
| 218 | 221 | ||
| 219 | exit 1 | 222 | exit 1 |
| 220 | fi | 223 | fi |
| 224 | |||
| 225 | echo 'Your system has the required tools.' | ||
| 221 | 226 | ||
| 222 | echo 'Your system has the required tools.' | 227 | fi # do_check |
| 223 | 228 | ||
| 224 | ## Create nt/gnulib.mk if it doesn't exist, as autoreconf will need it. | 229 | ## Create nt/gnulib.mk if it doesn't exist, as autoreconf will need it. |
| 225 | if test ! -f nt/gnulib.mk; then | 230 | if test ! -f nt/gnulib.mk; then |