Re: autoconf/configure information sources?
On Thu, Oct 18, 2001 at 06:06:31PM -0400, Dale Scheetz wrote:
> If I knew how to provide a "custom" option for configure.in, I could hack
> the macro into optionally using the defaults. Know how to do that?
Depending on whether you would prefer a --with[out]-xyz or and
-{en,dis}able-xyz option[1], you should use the macros AC_ARG_WITH or
AC_ARG_ENABLE, respectively:
AC_ARG_WITH([xyz], [ --with-xyz enable xyz support],
[
if "x$withval" == "xno"; then
<actions to disable use of the package>;
else
<actions to enable use of the package>;
fi
], [
<arg was not given, do the default stuff>
]
Similar with --enable-xyz.
- Sebastian
[1] --with is used to tell autoconf that it should (not) use a certain
software package (like e.g. OpenSSL), while --enable/--disable is
used to en-/disable certain features.
Reply to: