6 echo >&2 "$0: error: $@"
16 Usage: $0 [OPTION]... [VAR=VALUE]...
18 This script creates necessary configuration files to build/install.
20 To assign environment variables (e.g., CC, CFLAGS...), specify them as
21 VAR=VALUE. See below for descriptions of some of the useful variables.
23 Defaults for the options are specified in brackets.
26 -h, --help display this help and exit
27 --prefix=[path] base path [/usr/local]
28 --bindir=DIR user executables [PREFIX/bin]
29 --sbindir=DIR system admin executables [PREFIX/sbin]
30 --libdir=DIR object code libraries [PREFIX/lib]
31 --scriptdir=DIR script type plugins [LIBDIR/vlock/scripts]
32 --moduledir=DIR module type plugins [LIBDIR/vlock/modules]
33 --mandir=DIR man documentation [PREFIX/share/man]
36 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
37 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
38 --enable-plugins enable plugin support [enabled]
39 --enable-pam enable PAM authentication [enabled]
40 --enable-shadow enable shadow authentication [disabled]
41 --enable-root-password enable unlogging with root password [enabled]
43 Some influential environment variables:
45 CFLAGS C compiler flags
46 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
47 nonstandard directory <lib dir>
48 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
49 headers in a nonstandard directory <include dir>
52 Use these variables to override the choices made by \`configure' or to help
53 it to find libraries and programs with nonstandard names/locations.
55 Report bugs to <frank-vlock@benkstein.net>.
65 enable_root_password
="$2"
68 if [ "$2" = "yes" ] ; then
69 if [ -n "$auth_method" ] && [ "$auth_method" != "$1" ] ; then
70 fatal_error
"pam and shadow authentication are mutually exclusive"
74 fatal_error
"cannot disable authentication"
78 fatal_error
"invalid feature name: $1"
83 while [ $# -gt 0 ] ; do
84 opt
=`expr "x$1" : 'x\([^=]*\)=.*' ||:`
85 optarg
=`expr "x$1" : 'x[^=]*=\(.*\)' ||:`
88 feature
=`expr "$1" : '--disable-\(.*\)'`
89 enable_feature
"$feature" no
93 feature
=`expr "$1" : '--enable-\(.*\)=no'`
94 enable_feature
"$feature" no
98 feature
=`expr "$1" : '--enable-\(.*\)=yes'`
99 enable_feature
"$feature" yes
103 feature
=`expr "$1" : '--enable-\(.*\)'`
104 enable_feature
"$feature" yes
110 eval set -- "$opt" "$optarg" "$@"
114 shift 2 || fatal_error
"$1 argument missing"
118 shift 2 || fatal_error
"$1 argument missing"
122 shift 2 || fatal_error
"$1 argument missing"
126 shift 2 || fatal_error
"$1 argument missing"
130 shift 2 || fatal_error
"$1 argument missing"
134 shift 2 || fatal_error
"$1 argument missing"
138 shift 2 || fatal_error
"$1 argument missing"
145 error
"unrecognized option: $1"
146 echo >&2 "Try \`$0 --help' for more information."
150 fatal_error
"invalid argument: $1"
163 scriptdir: $SCRIPTDIR
164 moduledir: $MODULEDIR
167 plugins: $ENABLE_PLUGINS
168 root-password: $ENABLE_ROOT_PASSWORD
169 auth-method: $AUTH_METHOD