Bail out if /bin/bash does not exist, or if it is not bash>=3.0.
Force make to use /bin/bash as shell.
1.1 --- a/configure Fri Nov 02 18:55:55 2007 +0000
1.2 +++ b/configure Wed Jan 16 21:41:53 2008 +0000
1.3 @@ -125,7 +125,7 @@
1.4 [ -x /bin/bash ] || do_error "bash 3.0 or above was not found in /bin/bash"
1.5 bash_version=$(/bin/bash -c 'echo ${BASH_VERSION}')
1.6 bash_major=$(/bin/bash -c 'echo ${BASH_VERSINFO[0]}')
1.7 -[ ${bash_major} -ge 3 ] || do_error "bash 3.0 or above is needed (found ${bash_version})"
1.8 +[ ${bash_major} -ge 3 ] || do_error "bash 3.0 or above is needed (/bin/bash is ${bash_version})"
1.9
1.10 sed -r -e "s,@@BINDIR@@,${BINDIR},g;" \
1.11 -e "s,@@LIBDIR@@,${LIBDIR},g;" \
2.1 --- a/ct-ng.in Fri Nov 02 18:55:55 2007 +0000
2.2 +++ b/ct-ng.in Wed Jan 16 21:41:53 2008 +0000
2.3 @@ -3,8 +3,16 @@
2.4 # Copyright 2006 Yann E. MORIN <yann.morin.1998@anciens.enib.fr>
2.5
2.6 # Don't print directory as we descend into them
2.7 +# Don't use built-in rules, we know what we're doing
2.8 MAKEFLAGS += --no-print-directory --no-builtin-rules
2.9
2.10 +# Some distributions (eg. Ubuntu) thought it wise to point /bin/sh to
2.11 +# a truly POSIX-conforming shell, ash in this case. This is not so good
2.12 +# as we, smart (haha!) developers (as smart we ourselves think we are),
2.13 +# got used to bashisms, and are enclined to easiness... So force use of
2.14 +# bash. (Note: this is ugly, but ./configure checks for it).
2.15 +export SHELL=/bin/bash
2.16 +
2.17 # This is where ct-ng is.
2.18 # Don't bother to change it other than with a new ./configure!
2.19 CT_NG:=@@CT_BINDIR@@/ct-ng