Re: gnome-libs and --disable-debug in the configure script

Gleef <> writes:

> That's one of the more annoying quirks of autoconf.  Unless you go through
> a lot of effort setting up the script, autoconf will
> recognize both --enable-<feature> and --disable-<feature> as both doing
> the same thing, toggling <feature> from the default behavior.  It leaves
> it up to the configure script writer to set a default and list the correct
> form of the option, and up to the person running configure to follow
> directions :-).

Yes, I agree - being forced to use

AC_ARG_ENABLE(debug, [  --enable-debug turn on debugging [default=no]], enable_debug="$enableval", enable_debug=no)

if test x$enable_debug = xyes ; then

instead of something like

AC_ARG_ENABLE(debug, [  --enable-debug turn on debugging [default=no]], AC_DEFINE(GNOME_ENABLE_DEBUG), AC_DEFINE(GNOME_DISABLE_DEBUG))

is really annoying. I can understand this for the AC_ARG_WITH macro, here it
makes sense to check the $withval, but AC_ARG_ENABLE ist just for enabling or
disabling a feature.

> It's certainly not perfect.  Autoconf is maintained by the Free Software
> Foundation, I'm sure they'd love patches if you can give it saner
> behavior, without wrecking anything.

At least, I can try it out.



   Martin Baulig - Angewandte Mathematik - Universitaet Trier,

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]