On Sunday 25 of April 2010 00:09:09 Daniel Stenberg wrote:
> On Wed, 21 Apr 2010, Kamil Dudka wrote:
> > I ugly hacked configure.ac to enable this feature.
>
> Attached here is my first stab at a configure option
> --enable-threader-resolver
It looks good to me. I spotted only one typo in comment. Maybe we
should also disallow to define USE_ARES and USE_THREADS_POSIX together
as it could cause a confusion. An incremental patch is attached.
Kamil
diff --git a/configure.ac b/configure.ac
index 490461d..9610eb0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2291,6 +2291,11 @@ AM_CONDITIONAL(USE_EMBEDDED_ARES, test x$embedded_ares = xyes)
CURL_CHECK_OPTION_THREADED_RESOLVER
+if test "x$want_thres" = xyes && test "x$want_ares" = xyes; then
+ AC_MSG_ERROR(
+[Options --enable-threaded-resolver and --enable-ares are mutually exclusive])
+fi
+
if test "$want_thres" = "yes"; then
AC_CHECK_HEADER(pthread.h,
[ AC_DEFINE(HAVE_PTHREAD_H, 1, [if you have <pthread.h>])
diff --git a/m4/curl-confopts.m4 b/m4/curl-confopts.m4
index ec29e2c..5a43b19 100644
--- a/m4/curl-confopts.m4
+++ b/m4/curl-confopts.m4
@@ -38,7 +38,7 @@ AC_HELP_STRING([--disable-threaded-resover],[Disable threaded resolver]),
OPT_THRES=$enableval)
case "$OPT_THRES" in
yes)
- dnl --enable-ares option used
+ dnl --enable-threaded-resolver option used
want_thres="yes"
;;
*)
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html