[telepathy-gabble/telepathy-gabble-0.8] Make --disable-assumed-ft-cap work.
Will Thompson
will.thompson at collabora.co.uk
Mon Dec 7 08:42:12 PST 2009
configure looks for args of the form "--enable-foo-bar" or
"--disable-foo-bar", and if if foo-bar is in a big table built from all
the AC_ARG_ENABLEs in configure.ac, it sets the variable enable_foo_bar.
So then our code would run, and set enable_assumed_ft_cap to yes,
trampling over any value it was set to by parsing the arguments to
configure.
The fourth argument of AC_ARG_ENABLE is the correct place to specify
what to do if the user doesn't pass anything about this option to
configure, so I moved the defaulting there; I also renamed the variable
to avoid the collision, consistent with the Werror arg.
---
configure.ac | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/configure.ac b/configure.ac
index 290ec2e..cb6ce45 100644
--- a/configure.ac
+++ b/configure.ac
@@ -106,15 +106,15 @@ if test x$enable_handle_leak_debug = xyes; then
HANDLE_LEAK_DEBUG_CFLAGS="-rdynamic"
fi
-enable_assumed_ft_cap=yes
AC_ARG_ENABLE([assumed-ft-cap],
AC_HELP_STRING([--disable-assumed-ft-cap],
[do not assume that we have a client capable of receiving file transfers]),
- [enable_assumed_ft_cap="$enableval"], [])
-if test "x$enable_assumed_ft_cap" = xyes; then
+ [assumed_ft_cap="$enableval"],
+ [assumed_ft_cap=yes])
+if test "x$assumed_ft_cap" = xyes; then
AC_DEFINE(ENABLE_ASSUMED_FT_CAP, [], [--enable-assumed-ft-cap])
fi
-AM_CONDITIONAL([ENABLE_ASSUMED_FT_CAP], [test "x$enable_assumed_ft_cap" = xyes])
+AM_CONDITIONAL([ENABLE_ASSUMED_FT_CAP], [test "x$assumed_ft_cap" = xyes])
AC_SUBST(HANDLE_LEAK_DEBUG_CFLAGS)
--
1.5.6.5
More information about the telepathy-commits
mailing list