Browse Source

configure: fix defaults in help.

Both "[ 1 ]" and "[ 0 ]" both evaluate true in shell; we really want
an explicit '1' test.

Before:
$ ./configure --help
...
  --enable/disable-compat (default disable)

After:
$ ./configure --help
...
  --enable/disable-compat (default enable)

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ppa-0.6.1
Rusty Russell 7 years ago
committed by Christian Decker
parent
commit
6a73c7eeb1
  1. 6
      configure

6
configure

@ -19,10 +19,10 @@ CONFIG_HEADER=ccan/config.h
usage_with_default()
{
if [ $# = 4 ]; then
if [ $2 ]; then
DEF=$4
else
if [ "$2" = 1 ]; then
DEF=$3
else
DEF=$4
fi
else
DEF=$2

Loading…
Cancel
Save