From e03da189af92cbc3269ebe7f818cdf0a5a4728f6 Mon Sep 17 00:00:00 2001 From: Marc Slemko Date: Fri, 21 Jul 2006 21:32:36 +0000 Subject: [PATCH] autoconf/automake: Fixed handling of bits/socket.h MSG_NODELAY git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664732 13f79535-47bb-0310-9956-ffa450edef68 --- lib/cpp/Makefile.am | 1 + lib/cpp/bootstrap.sh | 9 +++++---- lib/cpp/configure.ac | 6 +++--- lib/cpp/src/transport/TSocket.cc | 5 +++-- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/lib/cpp/Makefile.am b/lib/cpp/Makefile.am index 1d79b5be..822a2c7f 100644 --- a/lib/cpp/Makefile.am +++ b/lib/cpp/Makefile.am @@ -10,6 +10,7 @@ libconcurrency_la_SOURCES = src/concurrency/Monitor.cc \ libconcurrency_inst_headers = src/concurrency/Exception.h \ src/concurrency/Monitor.h \ + src/concurrency/PosixThreadFactory.h \ src/concurrency/Thread.h \ src/concurrency/ThreadManager.h \ src/concurrency/TimerManager.h diff --git a/lib/cpp/bootstrap.sh b/lib/cpp/bootstrap.sh index df392e7c..e85fd2b7 100755 --- a/lib/cpp/bootstrap.sh +++ b/lib/cpp/bootstrap.sh @@ -16,24 +16,25 @@ autoscan.log \ config.guess \ config.h \ config.hin \ -config.hin \ config.log \ config.status \ config.sub \ configure \ configure.scan \ depcomp \ +.deps \ install-sh \ +.libs \ libtool \ ltmain.sh \ -missing \ -stamp-h1 +Makefile.in \ +missing autoscan autoheader aclocal -libtoolize --force +libtoolize --automake touch NEWS README AUTHORS ChangeLog autoconf automake -ac diff --git a/lib/cpp/configure.ac b/lib/cpp/configure.ac index 0499a0e1..a269df6c 100644 --- a/lib/cpp/configure.ac +++ b/lib/cpp/configure.ac @@ -28,12 +28,12 @@ AC_CHECK_HEADERS([stddef.h]) AC_CHECK_HEADERS([sys/socket.h]) -AC_CHECK_HEADERS([bits/socket.h]) - AC_CHECK_HEADERS([sys/time.h]) AC_CHECK_HEADERS([unistd.h]) +AC_CHECK_LIB(pthread, pthread_create) + AC_C_CONST AC_C_VOLATILE @@ -47,7 +47,7 @@ AC_HEADER_TIME AC_TYPE_SIZE_T AC_TYPE_INT32_T -x + AC_TYPE_INT64_T AC_TYPE_UINT16_T diff --git a/lib/cpp/src/transport/TSocket.cc b/lib/cpp/src/transport/TSocket.cc index 55f512e1..2161697d 100644 --- a/lib/cpp/src/transport/TSocket.cc +++ b/lib/cpp/src/transport/TSocket.cc @@ -1,3 +1,4 @@ +#include #include #include #include @@ -165,11 +166,11 @@ void TSocket::write(const uint8_t* buf, uint32_t len) { int flags = 0; - #if HAVE_BITS_SOCKET_H + #if defined(MSG_NOSIGNAL) // Note the use of MSG_NOSIGNAL to suppress SIGPIPE errors, instead we // check for the EPIPE return condition and close the socket in that case flags |= MSG_NOSIGNAL; - #endif // HAVE_BITS_SOCKET_H + #endif // defined(MSG_NOSIGNAL) int b = send(socket_, buf + sent, len - sent, flags); ++g_socket_syscalls; -- 2.17.1