configure 55.3 KB
Newer Older
1
#! /bin/sh
2

3
# Guess values for system-dependent variables and create Makefiles.
4 5
# Generated automatically using autoconf version 2.13 
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 7 8 9
#
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.

10 11
# Defaults:
ac_help=
12
ac_default_prefix=/usr/local
13
# Any additions from configure.in:
14
ac_default_prefix=/usr/testbed
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
ac_help="$ac_help
  --with-TBDEFS=name	Specify definitions file (defs-default default)"
ac_help="$ac_help
  --with-LEDA		Specify LEDA path (/usr/testbed default)"
ac_help="$ac_help
  --with-assignbinary	Specify assign binary (overrides LEDA, default on)"
ac_help="$ac_help
  --with-ssh-args	Specify ssh arguments when running from testbed scripts "
ac_help="$ac_help
  --with-rcdir		Specify path to install rc.d scripts (/usr/local/etc/rc.d default)"
ac_help="$ac_help
  --with-apache-config	Specify path to install apache config files (/usr/local/etc/apache default)"
ac_help="$ac_help
  --enable-debug        Build with debug flags (-g -DDEBUG)
  --disable-debug       Build with optimization flags (-O2 -DNDEBUG -UDEBUG)"
ac_help="$ac_help
  --disable-events      Disable events (requires Elvin libraries)"
ac_help="$ac_help
  --enable-windows      Enable Windows XP support (requires third-party software)"
ac_help="$ac_help
  --disable-sfs         Disable SFS support (SFS must be installed on ops)"
ac_help="$ac_help
  --enable-testmode     Enable test mode
  --disable-testmode    Disable test mode"
39 40 41 42

# Initialize some variables set by options.
# The variables have the same names as the options, with
# dashes changed to underlines.
43 44
build=NONE
cache_file=./config.cache
45
exec_prefix=NONE
46
host=NONE
47
no_create=
48
nonopt=NONE
49 50 51 52 53 54 55
no_recursion=
prefix=NONE
program_prefix=NONE
program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
56
sitefile=
57
srcdir=
58
target=NONE
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
verbose=
x_includes=NONE
x_libraries=NONE
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datadir='${prefix}/share'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'

75 76 77 78 79 80 81
# Initialize some other variables.
subdirs=
MFLAGS= MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}
# Maximum number of lines to put in a shell here document.
ac_max_here_lines=12

82 83 84
ac_prev=
for ac_option
do
85

86 87 88 89 90 91 92
  # If the previous option needs an argument, assign it.
  if test -n "$ac_prev"; then
    eval "$ac_prev=\$ac_option"
    ac_prev=
    continue
  fi

93 94 95 96
  case "$ac_option" in
  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  *) ac_optarg= ;;
  esac
97 98 99

  # Accept the important Cygnus configure options, so we can diagnose typos.

100
  case "$ac_option" in
101 102 103 104

  -bindir | --bindir | --bindi | --bind | --bin | --bi)
    ac_prev=bindir ;;
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
105
    bindir="$ac_optarg" ;;
106 107

  -build | --build | --buil | --bui | --bu)
108
    ac_prev=build ;;
109
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
110
    build="$ac_optarg" ;;
111 112 113 114 115 116

  -cache-file | --cache-file | --cache-fil | --cache-fi \
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
    ac_prev=cache_file ;;
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
117
    cache_file="$ac_optarg" ;;
118 119 120 121 122

  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
    ac_prev=datadir ;;
  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  | --da=*)
123
    datadir="$ac_optarg" ;;
124 125

  -disable-* | --disable-*)
126
    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
127
    # Reject names that are not valid shell variable names.
128 129 130 131 132
    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    eval "enable_${ac_feature}=no" ;;
133 134

  -enable-* | --enable-*)
135
    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
136
    # Reject names that are not valid shell variable names.
137 138 139 140 141 142
    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    case "$ac_option" in
      *=*) ;;
143 144
      *) ac_optarg=yes ;;
    esac
145
    eval "enable_${ac_feature}='$ac_optarg'" ;;
146 147 148 149 150 151 152 153

  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  | --exec | --exe | --ex)
    ac_prev=exec_prefix ;;
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  | --exec=* | --exe=* | --ex=*)
154
    exec_prefix="$ac_optarg" ;;
155 156 157 158 159

  -gas | --gas | --ga | --g)
    # Obsolete; use --with-gas.
    with_gas=yes ;;

160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214
  -help | --help | --hel | --he)
    # Omit some internal or obsolete options to make the list less imposing.
    # This message is too long to be a string in the A/UX 3.1 sh.
    cat << EOF
Usage: configure [options] [host]
Options: [defaults in brackets after descriptions]
Configuration:
  --cache-file=FILE       cache test results in FILE
  --help                  print this message
  --no-create             do not create output files
  --quiet, --silent       do not print \`checking...' messages
  --site-file=FILE        use FILE as the site file
  --version               print the version of autoconf that created configure
Directory and file names:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [$ac_default_prefix]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [same as prefix]
  --bindir=DIR            user executables in DIR [EPREFIX/bin]
  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
  --datadir=DIR           read-only architecture-independent data in DIR
                          [PREFIX/share]
  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
                          [PREFIX/com]
  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
  --includedir=DIR        C header files in DIR [PREFIX/include]
  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
  --infodir=DIR           info documentation in DIR [PREFIX/info]
  --mandir=DIR            man documentation in DIR [PREFIX/man]
  --srcdir=DIR            find the sources in DIR [configure dir or ..]
  --program-prefix=PREFIX prepend PREFIX to installed program names
  --program-suffix=SUFFIX append SUFFIX to installed program names
  --program-transform-name=PROGRAM
                          run sed PROGRAM on installed program names
EOF
    cat << EOF
Host type:
  --build=BUILD           configure for building on BUILD [BUILD=HOST]
  --host=HOST             configure for HOST [guessed]
  --target=TARGET         configure for TARGET [TARGET=HOST]
Features and packages:
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --x-includes=DIR        X include files are in DIR
  --x-libraries=DIR       X library files are in DIR
EOF
    if test -n "$ac_help"; then
      echo "--enable and --with options recognized:$ac_help"
    fi
    exit 0 ;;
215 216

  -host | --host | --hos | --ho)
217
    ac_prev=host ;;
218
  -host=* | --host=* | --hos=* | --ho=*)
219
    host="$ac_optarg" ;;
220 221 222 223 224 225

  -includedir | --includedir | --includedi | --included | --include \
  | --includ | --inclu | --incl | --inc)
    ac_prev=includedir ;;
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  | --includ=* | --inclu=* | --incl=* | --inc=*)
226
    includedir="$ac_optarg" ;;
227 228 229 230

  -infodir | --infodir | --infodi | --infod | --info | --inf)
    ac_prev=infodir ;;
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
231
    infodir="$ac_optarg" ;;
232 233 234 235

  -libdir | --libdir | --libdi | --libd)
    ac_prev=libdir ;;
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
236
    libdir="$ac_optarg" ;;
237 238 239 240 241 242

  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  | --libexe | --libex | --libe)
    ac_prev=libexecdir ;;
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  | --libexe=* | --libex=* | --libe=*)
243
    libexecdir="$ac_optarg" ;;
244 245 246 247 248 249 250 251

  -localstatedir | --localstatedir | --localstatedi | --localstated \
  | --localstate | --localstat | --localsta | --localst \
  | --locals | --local | --loca | --loc | --lo)
    ac_prev=localstatedir ;;
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
252
    localstatedir="$ac_optarg" ;;
253 254 255 256

  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
    ac_prev=mandir ;;
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
257
    mandir="$ac_optarg" ;;
258 259 260 261 262 263

  -nfp | --nfp | --nf)
    # Obsolete; use --without-fp.
    with_fp=no ;;

  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
264
  | --no-cr | --no-c)
265 266 267 268 269 270 271 272 273 274 275 276 277
    no_create=yes ;;

  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
    no_recursion=yes ;;

  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  | --oldin | --oldi | --old | --ol | --o)
    ac_prev=oldincludedir ;;
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
278
    oldincludedir="$ac_optarg" ;;
279 280 281 282

  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
    ac_prev=prefix ;;
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
283
    prefix="$ac_optarg" ;;
284 285 286 287 288 289

  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  | --program-pre | --program-pr | --program-p)
    ac_prev=program_prefix ;;
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
290
    program_prefix="$ac_optarg" ;;
291 292 293 294 295 296

  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  | --program-suf | --program-su | --program-s)
    ac_prev=program_suffix ;;
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
297
    program_suffix="$ac_optarg" ;;
298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313

  -program-transform-name | --program-transform-name \
  | --program-transform-nam | --program-transform-na \
  | --program-transform-n | --program-transform- \
  | --program-transform | --program-transfor \
  | --program-transfo | --program-transf \
  | --program-trans | --program-tran \
  | --progr-tra | --program-tr | --program-t)
    ac_prev=program_transform_name ;;
  -program-transform-name=* | --program-transform-name=* \
  | --program-transform-nam=* | --program-transform-na=* \
  | --program-transform-n=* | --program-transform-=* \
  | --program-transform=* | --program-transfor=* \
  | --program-transfo=* | --program-transf=* \
  | --program-trans=* | --program-tran=* \
  | --progr-tra=* | --program-tr=* | --program-t=*)
314
    program_transform_name="$ac_optarg" ;;
315 316 317 318 319 320 321 322 323

  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil)
    silent=yes ;;

  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
    ac_prev=sbindir ;;
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  | --sbi=* | --sb=*)
324
    sbindir="$ac_optarg" ;;
325 326 327 328 329 330 331 332 333 334

  -sharedstatedir | --sharedstatedir | --sharedstatedi \
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  | --sharedst | --shareds | --shared | --share | --shar \
  | --sha | --sh)
    ac_prev=sharedstatedir ;;
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  | --sha=* | --sh=*)
335
    sharedstatedir="$ac_optarg" ;;
336 337 338 339

  -site | --site | --sit)
    ac_prev=site ;;
  -site=* | --site=* | --sit=*)
340 341 342 343 344 345
    site="$ac_optarg" ;;

  -site-file | --site-file | --site-fil | --site-fi | --site-f)
    ac_prev=sitefile ;;
  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
    sitefile="$ac_optarg" ;;
346

347 348 349
  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
    ac_prev=srcdir ;;
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
350
    srcdir="$ac_optarg" ;;
351 352 353 354 355 356

  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  | --syscon | --sysco | --sysc | --sys | --sy)
    ac_prev=sysconfdir ;;
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
357
    sysconfdir="$ac_optarg" ;;
358 359

  -target | --target | --targe | --targ | --tar | --ta | --t)
360
    ac_prev=target ;;
361
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
362
    target="$ac_optarg" ;;
363 364 365 366

  -v | -verbose | --verbose | --verbos | --verbo | --verb)
    verbose=yes ;;

367 368 369
  -version | --version | --versio | --versi | --vers)
    echo "configure generated by autoconf version 2.13"
    exit 0 ;;
370 371

  -with-* | --with-*)
372
    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
373
    # Reject names that are not valid shell variable names.
374 375 376
    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
    fi
377
    ac_package=`echo $ac_package| sed 's/-/_/g'`
378 379
    case "$ac_option" in
      *=*) ;;
380 381
      *) ac_optarg=yes ;;
    esac
382
    eval "with_${ac_package}='$ac_optarg'" ;;
383 384

  -without-* | --without-*)
385
    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
386
    # Reject names that are not valid shell variable names.
387 388 389 390 391
    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
    fi
    ac_package=`echo $ac_package| sed 's/-/_/g'`
    eval "with_${ac_package}=no" ;;
392 393 394 395 396 397 398 399 400 401

  --x)
    # Obsolete; use --with-x.
    with_x=yes ;;

  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  | --x-incl | --x-inc | --x-in | --x-i)
    ac_prev=x_includes ;;
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
402
    x_includes="$ac_optarg" ;;
403 404 405 406 407 408

  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
    ac_prev=x_libraries ;;
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
409
    x_libraries="$ac_optarg" ;;
410

411
  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
412 413 414
    ;;

  *)
415 416 417 418 419 420 421
    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
      echo "configure: warning: $ac_option: invalid host type" 1>&2
    fi
    if test "x$nonopt" != xNONE; then
      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
    fi
    nonopt="$ac_option"
422 423 424 425 426 427
    ;;

  esac
done

if test -n "$ac_prev"; then
428
  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
429 430
fi

431
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
432

433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456
# File descriptor usage:
# 0 standard input
# 1 file creation
# 2 errors and warnings
# 3 some systems may open it to /dev/tty
# 4 used on the Kubota Titan
# 6 checking for... messages and results
# 5 compiler messages saved in config.log
if test "$silent" = yes; then
  exec 6>/dev/null
else
  exec 6>&1
fi
exec 5>./config.log

echo "\
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
" 1>&5

# Strip out --no-create and --no-recursion so they do not pile up.
# Also quote any args containing shell metacharacters.
ac_configure_args=
for ac_arg
457
do
458 459 460 461 462 463 464 465
  case "$ac_arg" in
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c) ;;
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
466 467 468
  esac
done

469 470 471 472 473 474 475 476 477
# NLS nuisances.
# Only set these to C if already set.  These must not be set unconditionally
# because not all systems understand e.g. LANG=C (notably SCO).
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
# Non-C LC_CTYPE values break the ctype check.
if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
Robert Ricci's avatar
Robert Ricci committed
478

479 480 481 482
# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -rf conftest* confdefs.h
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
echo > confdefs.h
483

484 485 486
# A filename unique to this package, relative to the directory that
# configure is in, which we can look for to find out if srcdir is correct.
ac_unique_file=Makeconf.in
487 488 489 490 491

# Find the source files, if location was not specified.
if test -z "$srcdir"; then
  ac_srcdir_defaulted=yes
  # Try the directory containing this script, then its parent.
492 493 494
  ac_prog=$0
  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
495 496 497 498 499 500 501 502 503
  srcdir=$ac_confdir
  if test ! -r $srcdir/$ac_unique_file; then
    srcdir=..
  fi
else
  ac_srcdir_defaulted=no
fi
if test ! -r $srcdir/$ac_unique_file; then
  if test "$ac_srcdir_defaulted" = yes; then
504
    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
505
  else
506
    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
507 508
  fi
fi
509
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
Robert Ricci's avatar
Robert Ricci committed
510

511 512 513 514 515
# Prefer explicitly selected file to automatically selected ones.
if test -z "$sitefile"; then
  if test -z "$CONFIG_SITE"; then
    if test "x$prefix" != xNONE; then
      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
Robert Ricci's avatar
Robert Ricci committed
516
    else
517
      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
518
    fi
519
  fi
520 521
else
  CONFIG_SITE="$sitefile"
522 523 524
fi
for ac_site_file in $CONFIG_SITE; do
  if test -r "$ac_site_file"; then
525
    echo "loading site script $ac_site_file"
526 527 528 529 530
    . "$ac_site_file"
  fi
done

if test -r "$cache_file"; then
531 532
  echo "loading cache $cache_file"
  . $cache_file
533
else
534 535
  echo "creating cache $cache_file"
  > $cache_file
536 537
fi

Robert Ricci's avatar
Robert Ricci committed
538
ac_ext=c
539
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
Robert Ricci's avatar
Robert Ricci committed
540
ac_cpp='$CPP $CPPFLAGS'
541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cross_compiling=$ac_cv_prog_cc_cross

ac_exeext=
ac_objext=o
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
    ac_n= ac_c='
' ac_t='	'
  else
    ac_n=-n ac_c= ac_t=
  fi
else
  ac_n= ac_c='\c' ac_t=
fi
Robert Ricci's avatar
Robert Ricci committed
558

559 560 561 562 563 564 565 566 567 568 569 570 571 572

ac_aux_dir=
for ac_dir in ${srcdir}/autoconf $srcdir/${srcdir}/autoconf; do
  if test -f $ac_dir/install-sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install-sh -c"
    break
  elif test -f $ac_dir/install.sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install.sh -c"
    break
  fi
done
if test -z "$ac_aux_dir"; then
573
  { echo "configure: error: can not find install-sh or install.sh in ${srcdir}/autoconf $srcdir/${srcdir}/autoconf" 1>&2; exit 1; }
574
fi
575 576 577
ac_config_guess=$ac_aux_dir/config.guess
ac_config_sub=$ac_aux_dir/config.sub
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
578 579


580

581

Robert Ricci's avatar
Robert Ricci committed
582

583 584 585
# Make sure we can run config.sub.
if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
586
fi
587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628

echo $ac_n "checking host system type""... $ac_c" 1>&6
echo "configure:590: checking host system type" >&5

host_alias=$host
case "$host_alias" in
NONE)
  case $nonopt in
  NONE)
    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
    fi ;;
  *) host_alias=$nonopt ;;
  esac ;;
esac

host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6

echo $ac_n "checking build system type""... $ac_c" 1>&6
echo "configure:611: checking build system type" >&5

build_alias=$build
case "$build_alias" in
NONE)
  case $nonopt in
  NONE) build_alias=$host_alias ;;
  *) build_alias=$nonopt ;;
  esac ;;
esac

build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$build" 1>&6

if test $host != $build; then
  ac_tool_prefix=${host_alias}-
629
else
630
  ac_tool_prefix=
631 632
fi

633 634 635 636 637 638
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:637: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Robert Ricci's avatar
Robert Ricci committed
639
else
640 641
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
Robert Ricci's avatar
Robert Ricci committed
642
else
643 644 645 646 647 648 649 650 651 652 653
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_CC="${ac_tool_prefix}gcc"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="gcc"
Robert Ricci's avatar
Robert Ricci committed
654 655
fi
fi
656 657 658
CC="$ac_cv_prog_CC"
if test -n "$CC"; then
  echo "$ac_t""$CC" 1>&6
Robert Ricci's avatar
Robert Ricci committed
659
else
660
  echo "$ac_t""no" 1>&6
Robert Ricci's avatar
Robert Ricci committed
661
fi
662 663


664 665

# Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args.
666
set dummy ${ac_tool_prefix}g++; ac_word=$2
667 668 669 670
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:669: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
671 672 673 674
else
  if test -n "$CXX"; then
  ac_cv_prog_CXX="$CXX" # Let the user override the test.
else
675 676 677 678 679 680 681 682 683 684 685
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_CXX="${ac_tool_prefix}g++"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_CXX" && ac_cv_prog_CXX="g++"
686 687
fi
fi
688
CXX="$ac_cv_prog_CXX"
689
if test -n "$CXX"; then
690
  echo "$ac_t""$CXX" 1>&6
691
else
692
  echo "$ac_t""no" 1>&6
693 694 695
fi


Robert Ricci's avatar
Robert Ricci committed
696

697
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
698
set dummy ${ac_tool_prefix}ar; ac_word=$2
699 700 701 702
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:701: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
703 704 705 706
else
  if test -n "$AR"; then
  ac_cv_prog_AR="$AR" # Let the user override the test.
else
707 708 709 710 711 712 713 714 715 716 717
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_AR="${ac_tool_prefix}ar"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
718 719
fi
fi
720
AR="$ac_cv_prog_AR"
721
if test -n "$AR"; then
722
  echo "$ac_t""$AR" 1>&6
Robert Ricci's avatar
Robert Ricci committed
723
else
724
  echo "$ac_t""no" 1>&6
Robert Ricci's avatar
Robert Ricci committed
725
fi
726 727


728 729

# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
730
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
731 732 733 734
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:733: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
735 736 737 738
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
739 740 741 742 743 744 745 746 747 748 749
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB="ranlib"
750 751
fi
fi
752
RANLIB="$ac_cv_prog_RANLIB"
753
if test -n "$RANLIB"; then
754
  echo "$ac_t""$RANLIB" 1>&6
755
else
756
  echo "$ac_t""no" 1>&6
757 758 759 760
fi



761
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
762
set dummy ${ac_tool_prefix}strip; ac_word=$2
763 764 765 766
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:765: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
767 768 769 770
else
  if test -n "$STRIP"; then
  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
771 772 773 774 775 776 777 778 779 780 781
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_STRIP="${ac_tool_prefix}strip"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP="strip"
782 783
fi
fi
784
STRIP="$ac_cv_prog_STRIP"
785
if test -n "$STRIP"; then
786
  echo "$ac_t""$STRIP" 1>&6
787
else
788
  echo "$ac_t""no" 1>&6
789 790 791 792
fi



793
# Extract the first word of "${ac_tool_prefix}ssh", so it can be a program name with args.
Robert Ricci's avatar
Robert Ricci committed
794
set dummy ${ac_tool_prefix}ssh; ac_word=$2
795 796 797 798
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:797: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_SSH'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Robert Ricci's avatar
Robert Ricci committed
799 800 801 802
else
  if test -n "$SSH"; then
  ac_cv_prog_SSH="$SSH" # Let the user override the test.
else
803 804 805 806 807 808 809 810 811 812 813
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_SSH="${ac_tool_prefix}ssh"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_SSH" && ac_cv_prog_SSH="ssh"
Robert Ricci's avatar
Robert Ricci committed
814 815
fi
fi
816
SSH="$ac_cv_prog_SSH"
Robert Ricci's avatar
Robert Ricci committed
817
if test -n "$SSH"; then
818
  echo "$ac_t""$SSH" 1>&6
Robert Ricci's avatar
Robert Ricci committed
819
else
820
  echo "$ac_t""no" 1>&6
Robert Ricci's avatar
Robert Ricci committed
821 822 823 824
fi



825

826 827


828
#
829
# These get defined in the definitions file (--with-TBDEFS).
830 831
# NB: See AC_DEFINE_UNQUOTED() calls below, if you want a variable
# to appear in config.h.
832
# 
833 834 835 836 837





Leigh Stoller's avatar
Leigh Stoller committed
838 839


840 841 842



843

844

845 846 847 848 849 850 851 852 853 854










855 856


857 858


859

860

861

862

863

864

865 866 867 868 869 870 871 872 873 874 875 876 877 878 879


#
# Offer both versions of the email addresses that have the @ escaped
# for perl (the default), and that don't
#









880

881

882 883 884



885

886

887

888

889 890


891

892 893
#
# Defaults for for above variables.
894
# 
895
TBADMINGROUP="flux"
896 897 898
CLIENT_ETCDIR="/etc/emulab"
CLIENT_BINDIR="/usr/local/etc/emulab"
CLIENT_VARDIR="/var/emulab"
899 900
TBSECURECOOKIES=1
TBMAINSITE=0
901

902 903 904
#
# Okay, I know this is improper usage of --with. Too bad.
#
905 906 907
# Check whether --with-TBDEFS or --without-TBDEFS was given.
if test "${with_TBDEFS+set}" = set; then
  withval="$with_TBDEFS"
908
  
909
    if test "$withval" = "yes"; then
910
	{ echo "configure: error: Invalid TBDEFS - Must specify the value" 1>&2; exit 1; }
911
    fi
912
    TBDEFS="$withval"
913 914

else
915
  
Robert Ricci's avatar
Robert Ricci committed
916
    TBDEFS="$srcdir/defs-default"
917

918 919
fi

920

921 922 923 924 925
if test -f $TBDEFS; then
    #
    # Remove the comments and newlines.  Really, that's what it does.
    #
    eval `cat $TBDEFS | sed -n -e '{s/#.*$//;H;}; ${g;s/\n/ /g;s/  */ /g;p;}'`
926
else
927
	{ echo "configure: error: Definitions file $TBDEFS was not found." 1>&2; exit 1; }
928 929
fi

930 931 932 933 934 935
#
# These must come after the "eval" above, since the variables are not
# defined until the defs file is taken in.
#
# Be sure to add to config.h.in!
#
936
cat >> confdefs.h <<EOF
937
#define TBDBNAME "$TBDBNAME"
938
EOF
939

940
cat >> confdefs.h <<EOF
941
#define TBADMINGROUP "$TBADMINGROUP"
942
EOF
943

944
cat >> confdefs.h <<EOF
945
#define IPBASE "$IPBASE"
946
EOF
947

948
cat >> confdefs.h <<EOF
949
#define BOSSNODE "$BOSSNODE"
950
EOF
951

952
cat >> confdefs.h <<EOF
953
#define USERNODE "$USERNODE"
954
EOF
955

956
cat >> confdefs.h <<EOF
957
#define FSNODE "$FSNODE"
958
EOF
959

960
cat >> confdefs.h <<EOF
961
#define OURDOMAIN "$OURDOMAIN"
962
EOF
963

964
cat >> confdefs.h <<EOF
965
#define FSDIR_PROJ "$FSDIR_PROJ"
966
EOF
967

968
cat >> confdefs.h <<EOF
969
#define FSDIR_GROUPS "$FSDIR_GROUPS"
970
EOF
971

972
cat >> confdefs.h <<EOF
973
#define FSDIR_USERS "$FSDIR_USERS"
974
EOF
975

976
if test -n "$FSDIR_SHARE"; then
977
    cat >> confdefs.h <<EOF
978
#define FSDIR_SHARE "$FSDIR_SHARE"
979
EOF
980 981

fi
982

983
#
984 985
# The email addresses need to be be munged for perl scripts. But,
# php needs them un-escaped
986
#
987
TBOPSEMAIL_NOSLASH="$TBOPSEMAIL"
988
TBOPSEMAIL="`echo $TBOPSEMAIL | sed -e 's/@/\\\@/'`"
989
TBLOGSEMAIL_NOSLASH="$TBLOGSEMAIL"
990
TBLOGSEMAIL="`echo $TBLOGSEMAIL | sed -e 's/@/\\\@/'`"
991
TBAUDITEMAIL_NOSLASH="$TBAUDITEMAIL"
992
TBAUDITEMAIL="`echo $TBAUDITEMAIL | sed -e 's/@/\\\@/'`"
993 994 995 996
TBWWWEMAIL_NOSLASH="$TBWWWEMAIL"
TBWWWEMAIL="`echo $TBWWWEMAIL | sed -e 's/@/\\\@/'`"
TBAPPROVALEMAIL_NOSLASH="$TBAPPROVALEMAIL"
TBAPPROVALEMAIL="`echo $TBAPPROVALEMAIL | sed -e 's/@/\\\@/'`"
997 998 999 1000
TBSTATEDEMAIL_NOSLASH="$TBSTATEDEMAIL_NOSLASH"
TBSTATEDEMAIL="`echo $TBSTATEDEMAIL | sed -e 's/@/\\\@/'`"
TBTESTSUITEEMAIL_NOSLASH="$TBTESTSUITEEMAIL_NOSLASH"
TBTESTSUITEEMAIL="`echo $TBTESTSUITEEMAIL | sed -e 's/@/\\\@/'`"
1001

1002
if test -n "$TBAUTOMAILEMAIL"; then
1003
    TBAUTOMAILEMAIL_NOSLASH="$TBAUTOMAILEMAIL"
1004 1005 1006 1007 1008
    TBAUTOMAILEMAIL="`echo $TBAUTOMAILEMAIL | sed -e 's/@/\\\@/'`"
else
    TBAUTOMAILEMAIL_NOSLASH="$TBLOGSEMAIL_NOSLASH"
    TBAUTOMAILEMAIL="$TBLOGSEMAIL"
fi
1009
if test -n "$TBACTIVEARCHIVE"; then
1010
    TBACTIVEARCHIVE_NOSLASH="$TBACTIVEARCHIVE"
1011 1012
    TBACTIVEARCHIVE="`echo $TBACTIVEARCHIVE | sed -e 's/@/\\\@/'`"
else
1013
    TBACTIVEARCHIVE_NOSLASH="$TBOPSEMAIL_NOSLASH"
1014 1015 1016
    TBACTIVEARCHIVE="$TBOPSEMAIL"
fi
if test -n "$TBUSERSARCHIVE"; then
1017
    TBUSERSARCHIVE_NOSLASH="$TBUSERSARCHIVE"
1018 1019
    TBUSERSARCHIVE="`echo $TBUSERSARCHIVE | sed -e 's/@/\\\@/'`"
else
1020
    TBUSERSARCHIVE_NOSLASH="$TBOPSEMAIL_NOSLASH"
1021 1022 1023
    TBUSERSARCHIVE="$TBOPSEMAIL"
fi

1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045
if test -z "$TBAUTHDOMAIN"; then
    TBAUTHDOMAIN=".$OURDOMAIN"
fi
if test -z "$TBAUTHTIMEOUT"; then
    TBAUTHTIMEOUT="21600"
fi
if test -z "$WWW"; then
    WWW="$WWWHOST"
fi
if test -z "$TBBASE"; then
    TBBASE="https://$WWW"
fi
if test -z "$TBDOCBASE"; then
    TBDOCBASE="http://$WWW"
fi
if test -z "$TBWWW"; then
    TBWWW="<$TBBASE/>"
fi
if test -z "$THISHOMEBASE"; then
    THISHOMEBASE="Emulab.Net"
fi

1046 1047 1048
#
# LEDA library path
#
1049 1050 1051
# Check whether --with-LEDA or --without-LEDA was given.
if test "${with_LEDA+set}" = set; then
  withval="$with_LEDA"
1052
  
1053 1054 1055 1056 1057 1058 1059
    if test "$withval" = "yes"; then
        LEDA="$ac_default_prefix/LEDA/LEDA-4.0"
    else
        LEDA="$withval"
    fi

else
1060
  
1061 1062 1063 1064 1065
    if test -d "$ac_default_prefix/LEDA/LEDA-4.0"; then
        LEDA="$ac_default_prefix/LEDA/LEDA-4.0"
    else
        LEDA=""
    fi
1066

1067 1068
fi

1069 1070


1071 1072 1073
#
# Override LEDA with assign binary.
#
1074 1075 1076
# Check whether --with-assignbinary or --without-assignbinary was given.
if test "${with_assignbinary+set}" = set; then
  withval="$with_assignbinary"
1077
  
1078 1079 1080 1081 1082 1083 1084 1085 1086
    if test "$withval" = "yes"; then
        ASSIGN="assign.bin"
        LEDA=""
    else
        ASSIGN="$withval"
        LEDA=""
    fi

else
1087
  
1088 1089 1090 1091 1092
    if test "$LEDA" = ""; then
        ASSIGN="assign.bin"
    else
        ASSIGN=""
    fi
1093

1094 1095
fi

1096 1097


Robert Ricci's avatar
Robert Ricci committed
1098 1099 1100 1101 1102 1103
#
# Arguments to ssh to disable strict host key checking, etc
#
# Check whether --with-SSH_ARGS or --without-SSH_ARGS was given.
if test "${with_SSH_ARGS+set}" = set; then
  withval="$with_SSH_ARGS"
1104
  
Robert Ricci's avatar
Robert Ricci committed
1105 1106 1107
    SSH_ARGS="$withval"

else
1108
  
Robert Ricci's avatar
Robert Ricci committed
1109
    SSH_ARGS="-q -o \"BatchMode yes\" -o \"StrictHostKeyChecking no\""
1110
    SSH_ARGS="$SSH_ARGS -o \"Protocol 1\""
Robert Ricci's avatar
Robert Ricci committed
1111

1112 1113
fi

Robert Ricci's avatar
Robert Ricci committed
1114 1115


1116 1117 1118 1119 1120 1121
#
# Path to install rc.d scripts in
#
# Check whether --with-rcdir or --without-rcdir was given.
if test "${with_rcdir+set}" = set; then
  withval="$with_rcdir"
1122
  
1123 1124 1125
    INSTALL_RCDIR="$with_rcdir"

else
1126
  
Robert Ricci's avatar
Robert Ricci committed
1127
    INSTALL_RCDIR="/usr/local/etc/rc.d"
1128

1129 1130
fi

1131 1132


1133 1134 1135 1136 1137 1138
#
# Path to install apache config files in
#
# Check whether --with-apache-config-dir or --without-apache-config-dir was given.
if test "${with_apache_config_dir+set}" = set; then
  withval="$with_apache_config_dir"
1139
  
1140 1141 1142
    INSTALL_APACHE_CONFIG="$withval"

else
1143
  
Robert Ricci's avatar
Robert Ricci committed
1144
    INSTALL_APACHE_CONFIG="/usr/local/etc/apache"
1145

1146 1147
fi

1148 1149 1150



1151 1152 1153 1154 1155 1156 1157
#
# Optionally build with optimization or aggressive non-optimization
# (Actually three options: on, off or default.)
#
# Check whether --enable-debug or --disable-debug was given.
if test "${enable_debug+set}" = set; then
  enableval="$enable_debug"
1158 1159
  :
fi
1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172


if test "$enable_debug" = "yes"; then
	OPT_CFLAGS="-g -DDEBUG";
else
	if test "$enable_debug" = "no"; then
		OPT_CFLAGS="-O2 -DNDEBUG -UDEBUG";
	else
		OPT_CFLAGS="-g -O";
	fi
fi


1173
#
1174
# Disable event system. Relies on Elvin. On by default.
1175
# 
1176 1177 1178
# Check whether --enable-events or --disable-events was given.
if test "${enable_events+set}" = set; then
  enableval="$enable_events"
1179 1180
  :
fi
1181 1182


1183 1184 1185 1186
if test "$enable_events" = "no"; then
	eventfiles="";
        EVENTSYS=0;
else
1187 1188
	eventfiles="event/GNUmakefile event/lib/GNUmakefile \
		    event/sched/GNUmakefile event/test/GNUmakefile \
1189
                    event/tbgen/GNUmakefile event/tbgen/tevd.restart \
1190
                    event/example/GNUmakefile event/example/tbsend.pl \
1191
		    event/example/tbrecv.pl event/example/tbsend-short.pl \
1192
		    event/trafgen/GNUmakefile \
1193
		    event/nsetrafgen/GNUmakefile \
1194
                    event/delay-agent/GNUmakefile \
Robert Ricci's avatar
Robert Ricci committed
1195
		    event/program-agent/GNUmakefile \
1196
		    event/stated/GNUmakefile event/stated/stated";
1197

1198
	optional_subdirs="$optional_subdirs event";
1199
        EVENTSYS=1;
1200 1201
fi

1202

1203 1204 1205 1206 1207
#
# Enable Windows support.
# Right now this means NTFS support in imagezip, maybe more things later.
# Relies on Linux NTFS library.
# Off by default.
1208
# 
1209 1210 1211
# Check whether --enable-windows or --disable-windows was given.
if test "${enable_windows+set}" = set; then
  enableval="$enable_windows"
1212 1213
  :
fi
1214 1215 1216


if test "$enable_windows" = "yes"; then
1217 1218 1219
	winfiles="os/imagezip/ntfs/GNUmakefile \
                  os/imagezip/ntfs/liblocale/GNUmakefile \
                  os/imagezip/ntfs/libntfs/GNUmakefile"
1220 1221 1222 1223 1224 1225 1226 1227
	optional_subdirs="$optional_subdirs";
        WINSUPPORT=1;
else
	winfiles="";
        WINSUPPORT=0;
fi


1228 1229
#
# Disable SFS support if SFS is not installed on ops node.
1230
# 
1231 1232 1233
# Check whether --enable-sfs or --disable-sfs was given.
if test "${enable_sfs+set}" = set; then
  enableval="$enable_sfs"
1234 1235
  :
fi
1236 1237 1238 1239 1240 1241


if test "$enable_sfs" = "no"; then
        SFSSUPPORT=0;
else
        SFSSUPPORT=1;
1242
	cat >> confdefs.h <<\EOF
1243
#define SFSSUPPORT 1
1244
EOF
1245 1246 1247 1248

fi


1249 1250 1251 1252 1253 1254 1255 1256
#
# Testing mode.  In testing mode scripts should not effect hardware state.
# This is designed to be used with the testsuite software which operates
# on a test copy of the DB.
#
# Check whether --enable-testmode or --disable-testmode was given.
if test "${enable_testmode+set}" = set; then
  enableval="$enable_testmode"
1257 1258
  :
fi
1259 1260 1261 1262 1263 1264 1265 1266 1267


if test "$enable_testmode" = "yes"; then
	TESTMODE=1;
else
	TESTMODE=0;
fi


1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281
# Make sure $INSTALL is valid at any depth in our tree, i.e. make it absoulte.
# This can be needed when no valid install is found and autoconf falls back on
# the supplied install.sh, but we called 'configure' with a relative path.
# Find a good install program.  We prefer a C program (faster),
# so one script is as good as another.  But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
1282
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1283
echo "configure:1284: checking for a BSD compatible install" >&5
1284
if test -z "$INSTALL"; then
1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS=":"
  for ac_dir in $PATH; do
    # Account for people who put trailing slashes in PATH elements.
    case "$ac_dir/" in
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
    *)
      # OSF1 and SCO ODT 3.0 have their own names for install.
      # Don't use installbsd from OSF since it installs stuff as root
      # by default.
      for ac_prog in ginstall scoinst install; do
        if test -f $ac_dir/$ac_prog; then
	  if test $ac_prog = install &&
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
	    # AIX install.  It has an incompatible calling convention.
	    :
	  else
	    ac_cv_path_install="$ac_dir/$ac_prog -c"
	    break 2
	  fi
	fi
1308
      done
1309 1310 1311 1312
      ;;
    esac
  done
  IFS="$ac_save_IFS"
1313 1314 1315

fi
  if test "${ac_cv_path_install+set}" = set; then
1316
    INSTALL="$ac_cv_path_install"
1317 1318 1319 1320 1321
  else
    # As a last resort, use the slow shell script.  We don't cache a
    # path for INSTALL within a source directory, because that will
    # break other packages using the cache if that directory is
    # removed, or if the path is relative.
1322
    INSTALL="$ac_install_sh"
1323 1324
  fi
fi
1325
echo "$ac_t""$INSTALL" 1>&6
1326 1327 1328 1329 1330

# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'

1331
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343

test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'

case "$INSTALL" in
..*)
        INSTALL=`pwd`/$INSTALL
        ;;
esac


outfiles="$outfiles Makeconf GNUmakefile \
	assign/GNUmakefile \
1344
	ssl/GNUmakefile ssl/mksig \
1345
	capture/GNUmakefile \
1346
	db/GNUmakefile db/nalloc db/nfree db/if2port db/backup \
1347
	db/webcontrol db/node_status db/genelists db/genelists.proxy \
1348
	db/setsitevar db/newwanode \
1349
	db/libdb.pm db/inuse db/avail db/nodeip db/showgraph \
1350
	db/dhcpd_makeconf db/nodelog db/webnodelog db/unixgroups \
1351
	db/dbcheck db/interswitch db/dbboot db/schemacheck \
1352
	db/sitevarscheck \
1353 1354
	db/grabron db/webnfree db/stategraph db/readycount \
	db/idletimes db/idlemail db/webidlemail \
1355
	discvr/GNUmakefile \
1356
	ipod/GNUmakefile \
1357
	lib/GNUmakefile lib/libtb/GNUmakefile \
1358
	os/GNUmakefile os/split-image.sh os/imagezip/GNUmakefile \
Mike Hibler's avatar
Mike Hibler committed
1359
	os/frisbee.redux/GNUmakefile os/growdisk/GNUmakefile \
1360
	pxe/GNUmakefile pxe/proxydhcp.restart pxe/bootinfo.restart \
1361
	security/GNUmakefile security/paperbag security/lastlog_daemon \
1362
	security/plasticwrap \
1363
        sensors/GNUmakefile sensors/slothd/GNUmakefile \
1364
	sensors/slothd/sdisrunning sensors/slothd/sddeploy \
1365 1366 1367
	account/GNUmakefile account/tbacct account/webtbacct \
	account/addpubkey account/webaddpubkey \
	account/addsfskey account/webaddsfskey \
1368
	account/quotamail \
1369
	tbsetup/GNUmakefile tbsetup/console_setup tbsetup/spewlogfile \
1370
	tbsetup/console_reset tbsetup/bwconfig tbsetup/power_rpc27.pm \
1371
	tbsetup/os_load tbsetup/os_setup tbsetup/os_select tbsetup/power \
1372
	tbsetup/node_reboot tbsetup/webnscheck tbsetup/nscheck \
1373
	tbsetup/resetvlans tbsetup/rmuser tbsetup/rmproj \
1374
	tbsetup/sched_reload tbsetup/sched_reserve tbsetup/reload_daemon \
1375
	tbsetup/batchexp tbsetup/batch_daemon \
Mac Newbold's avatar
Mac Newbold committed
1376
	tbsetup/webdelay_config tbsetup/tbresize \