mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 04:13:28 +01:00
r9107@Kushana: nickm | 2006-10-06 02:14:02 -0400
When eventdns is enabled, we can allow machines with thread-unsafe resolver functions to build multithreaded anyway. svn:r8608
This commit is contained in:
parent
1d4bd3990f
commit
09a2ec0192
@ -88,6 +88,9 @@ Changes in version 0.1.2.2-alpha - 2006-10-??
|
|||||||
- Just because your DirPort is open doesn't mean people should be
|
- Just because your DirPort is open doesn't mean people should be
|
||||||
able to remotely teach you about hidden service descriptors. Now
|
able to remotely teach you about hidden service descriptors. Now
|
||||||
only accept rendezvous posts if you've got HSAuthoritativeDir set.
|
only accept rendezvous posts if you've got HSAuthoritativeDir set.
|
||||||
|
- When eventdns is enabled, allow multithreaded builds on NetBSD and
|
||||||
|
OpenBSD. (We had previously disabled threads on these platforms
|
||||||
|
because they didn't have working thread-safe resolver functions)
|
||||||
|
|
||||||
o Major bugfixes, other:
|
o Major bugfixes, other:
|
||||||
- Avoiding crashing on race condition in dns.c:
|
- Avoiding crashing on race condition in dns.c:
|
||||||
|
52
configure.in
52
configure.in
@ -19,31 +19,6 @@ AC_ARG_ENABLE(debug,
|
|||||||
CFLAGS="$CFLAGS -g"
|
CFLAGS="$CFLAGS -g"
|
||||||
fi])
|
fi])
|
||||||
|
|
||||||
AC_ARG_ENABLE(threads,
|
|
||||||
AC_HELP_STRING(--disable-threads, disable multi-threading support))
|
|
||||||
|
|
||||||
if test x$enable_threads = x; then
|
|
||||||
case $host in
|
|
||||||
*-*-netbsd* | *-*-openbsd* )
|
|
||||||
# Don't try multithreading on netbsd -- there is no threadsafe DNS
|
|
||||||
# lookup function there.
|
|
||||||
AC_MSG_NOTICE([You are running OpenBSD or NetBSD; I am assuming that
|
|
||||||
getaddrinfo is not threadsafe here, so I will disable threads.])
|
|
||||||
enable_threads="no";;
|
|
||||||
*-*-solaris* )
|
|
||||||
# Don't try multithreading on solaris -- cpuworkers seem to lock.
|
|
||||||
AC_MSG_NOTICE([You are running Solaris; Sometimes threading makes
|
|
||||||
cpu workers lock up here, so I will disable threads.])
|
|
||||||
enable_threads="no";;
|
|
||||||
*)
|
|
||||||
enable_threads="yes";;
|
|
||||||
esac
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test $enable_threads = "yes"; then
|
|
||||||
AC_DEFINE(ENABLE_THREADS, 1, [Defined if we will try to use multithreading])
|
|
||||||
fi
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(eventdns,
|
AC_ARG_ENABLE(eventdns,
|
||||||
AC_HELP_STRING(--enable-eventdns, enable asynchronous dns module),
|
AC_HELP_STRING(--enable-eventdns, enable asynchronous dns module),
|
||||||
[case "${enableval}" in
|
[case "${enableval}" in
|
||||||
@ -64,6 +39,33 @@ AC_ARG_ENABLE(transparent,
|
|||||||
*) AC_MSG_ERROR(bad value for --enable-transparent) ;;
|
*) AC_MSG_ERROR(bad value for --enable-transparent) ;;
|
||||||
esac], [transparent=true])
|
esac], [transparent=true])
|
||||||
|
|
||||||
|
AC_ARG_ENABLE(threads,
|
||||||
|
AC_HELP_STRING(--disable-threads, disable multi-threading support))
|
||||||
|
|
||||||
|
if test x$enable_threads = x; then
|
||||||
|
case $host in
|
||||||
|
*-*-netbsd* | *-*-openbsd* )
|
||||||
|
# Don't try multithreading on netbsd -- there is no threadsafe DNS
|
||||||
|
# lookup function there.
|
||||||
|
if test x$eventdns != xtrue; then
|
||||||
|
AC_MSG_NOTICE([You are running OpenBSD or NetBSD; I am assuming that
|
||||||
|
getaddrinfo is not threadsafe here, so I will disable threads.])
|
||||||
|
enable_threads="no"
|
||||||
|
fi ;;
|
||||||
|
*-*-solaris* )
|
||||||
|
# Don't try multithreading on solaris -- cpuworkers seem to lock.
|
||||||
|
AC_MSG_NOTICE([You are running Solaris; Sometimes threading makes
|
||||||
|
cpu workers lock up here, so I will disable threads.])
|
||||||
|
enable_threads="no";;
|
||||||
|
*)
|
||||||
|
enable_threads="yes";;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test $enable_threads = "yes"; then
|
||||||
|
AC_DEFINE(ENABLE_THREADS, 1, [Defined if we will try to use multithreading])
|
||||||
|
fi
|
||||||
|
|
||||||
case $host in
|
case $host in
|
||||||
*-*-solaris* )
|
*-*-solaris* )
|
||||||
AC_DEFINE(_REENTRANT, 1, [Define on some platforms to activate x_r() functions in time.h])
|
AC_DEFINE(_REENTRANT, 1, [Define on some platforms to activate x_r() functions in time.h])
|
||||||
|
Loading…
Reference in New Issue
Block a user