[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [libmicrohttpd] branch master updated (ac85c571 -> a6b47251
From: |
gnunet |
Subject: |
[GNUnet-SVN] [libmicrohttpd] branch master updated (ac85c571 -> a6b47251) |
Date: |
Sat, 22 Apr 2017 19:43:30 +0200 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a change to branch master
in repository libmicrohttpd.
from ac85c571 connection.c: silent compiler warning
new bc005396 configure: check for invalid "with-thread" parameters
new 541d6283 configure: refactoring to be consistent with other configure
variables
new a6b47251 Fixed support for old libgcrypt on W32 with W32 threads.
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
ChangeLog | 5 +++++
configure.ac | 40 +++++++++++++++++++++++++---------------
src/microhttpd/daemon.c | 8 +++-----
3 files changed, 33 insertions(+), 20 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 77984c9e..3b07dc14 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sat Apr 22 20:39:00 MSK 2017
+ Fixed builds in Linux without epoll.
+ Check for invalid --with-thread= configure parameters.
+ Fixed support for old libgcrypt on W32 with W32 threads. -EG
+
Tue Apr 11 22:17:00 MSK 2017
Releasing GNU libmicrohttpd 0.9.53. -EG
diff --git a/configure.ac b/configure.ac
index 431e08e6..31f18c30 100644
--- a/configure.ac
+++ b/configure.ac
@@ -341,33 +341,43 @@ esac
AC_ARG_WITH([threads],
[AS_HELP_STRING([--with-threads=LIB],[choose threading library (posix, w32,
auto) [auto]])],
[], [with_threads='auto'])
-test "x$with_threads" = "xwin32" && with_threads='w32'
-test "x$with_threads" = "xpthreads" && with_threads='posix'
+AS_CASE([[$with_threads]],
+ [[win32]], [[with_threads='w32']],
+ [[pthreads]], [[with_threads='posix']],
+ [[posix]], [[:]],
+ [[w32]], [[:]],
+ [[auto]], [[:]],
+ [AC_MSG_ERROR([[incorrect parameter "$with_threads" specified for
--with-threads]])]
+)
# Check for posix threads support, regardless of configure parameters as
-# posix threads are used in some tests even on W32.
+# testsuite use only posix threads.
AX_PTHREAD(
[
- HAVE_POSIX_THREADS='yes'
+ mhd_have_posix_threads='yes'
AC_DEFINE([[HAVE_PTHREAD_H]],[[1]],[Define to 1 if you have the
<pthread.h> header file.])
- ],[[HAVE_POSIX_THREADS='no']])
-AM_CONDITIONAL([HAVE_POSIX_THREADS],[test "x$HAVE_POSIX_THREADS" = "xyes"])
+ ],[[mhd_have_posix_threads='no']])
+AM_CONDITIONAL([HAVE_POSIX_THREADS],[test "x$mhd_have_posix_threads" = "xyes"])
-HAVE_W32_THREADS='no'
-AS_IF([[test "x$os_is_windows" = "xyes"]],
+mhd_have_w32_threads='no'
+AS_IF([[test "x$with_threads" = "xauto"]],
+ [
+ AS_IF([[test "x$os_is_windows" = "xyes"]],
[
AC_MSG_CHECKING([[for W32 threads]])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([#include <windows.h>], [ HANDLE h = CreateThread(NULL,
0, NULL, NULL, 0, NULL);])]
- , [[HAVE_W32_THREADS='yes']], [[HAVE_W32_THREADS='no']]
+ , [[mhd_have_w32_threads='yes']], [[mhd_have_w32_threads='no']]
)
- AC_MSG_RESULT([[$HAVE_W32_THREADS]])
+ AC_MSG_RESULT([[$mhd_have_w32_threads]])
])
+ ]
+)
AC_MSG_CHECKING([[for threading lib to use with libmicrohttpd]])
AS_IF([[test "x$with_threads" = "xposix"]],
[ # forced posix threads
- AS_IF([[test "x$HAVE_POSIX_THREADS" = "xyes"]], [[ USE_THREADS='posix' ]],
+ AS_IF([[test "x$mhd_have_posix_threads" = "xyes"]], [[ USE_THREADS='posix'
]],
[ AS_IF([[test "x$os_is_windows" = "xyes"]] ,
[ AC_MSG_ERROR([[Posix threads are not available. Try to configure
--with-threads=auto]])],
[ AC_MSG_ERROR([[No threading lib is available. Consider installing
pthreads]])] )
@@ -375,15 +385,15 @@ AS_IF([[test "x$with_threads" = "xposix"]],
] ,
[[ test "x$with_threads" = "xw32" ]] ,
[ # forced w32 threads
- AS_IF([[test "x$HAVE_W32_THREADS" = "xyes"]],
+ AS_IF([[test "x$mhd_have_w32_threads" = "xyes"]],
[[ USE_THREADS='w32' ]],
[ AC_MSG_ERROR([[W32 threads are not available. Try to configure
--with-threads=auto]])])
] ,
[ # automatic threads lib selection
- AS_IF([[test "x$os_is_native_w32" = "xyes" && test "x$HAVE_W32_THREADS"
= "xyes"]] ,
+ AS_IF([[test "x$os_is_native_w32" = "xyes" && test
"x$mhd_have_w32_threads" = "xyes"]] ,
[[ USE_THREADS='w32' ]] ,
- [[ test "x$HAVE_POSIX_THREADS" = "xyes" ]], [[ USE_THREADS='posix' ]],
- [[ test "x$HAVE_W32_THREADS" = "xyes" ]], [[ USE_THREADS='w32' ]],
+ [[ test "x$mhd_have_posix_threads" = "xyes" ]], [[ USE_THREADS='posix'
]],
+ [[ test "x$mhd_have_w32_threads" = "xyes" ]], [[ USE_THREADS='w32' ]],
[ AC_MSG_ERROR([[No threading lib is available. Consider installing
pthreads]]) ]
)
]
diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c
index 02713e3a..fb8922f4 100644
--- a/src/microhttpd/daemon.c
+++ b/src/microhttpd/daemon.c
@@ -6664,7 +6664,7 @@ gcry_w32_mutex_init (void **ppmtx)
static int
gcry_w32_mutex_destroy (void **ppmtx)
{
- int res = (MHD_mutex_destroy_chk_ ((MHD_mutex_*)*ppmtx)) ? 0 : 1;
+ int res = (MHD_mutex_destroy_ ((MHD_mutex_*)*ppmtx)) ? 0 : EINVAL;
free (*ppmtx);
return res;
}
@@ -6673,16 +6673,14 @@ gcry_w32_mutex_destroy (void **ppmtx)
static int
gcry_w32_mutex_lock (void **ppmtx)
{
- MHD_mutex_lock_chk_ ((MHD_mutex_*)*ppmtx);
- return 0;
+ return MHD_mutex_lock_ ((MHD_mutex_*)*ppmtx) ? 0 : EINVAL;
}
static int
gcry_w32_mutex_unlock (void **ppmtx)
{
- MHD_mutex_unlock_chk_ ((MHD_mutex_*)*ppmtx);
- return 0;
+ return MHD_mutex_unlock_ ((MHD_mutex_*)*ppmtx) ? 0 : EINVAL;
}
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [libmicrohttpd] branch master updated (ac85c571 -> a6b47251),
gnunet <=