summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--devel/thrift/Makefile20
-rw-r--r--devel/thrift/distinfo4
-rw-r--r--devel/thrift/files/patch-configure.ac11
-rw-r--r--devel/thrift/files/patch-lib__c_glib__src__transport__thrift_framed_transport.h10
-rw-r--r--devel/thrift/files/patch-lib__c_glib__src__transport__thrift_socket.h11
-rw-r--r--devel/thrift/files/patch-lib__cpp__src__server__TNonblockingServer.h12
-rw-r--r--devel/thrift/pkg-plist29
7 files changed, 79 insertions, 18 deletions
diff --git a/devel/thrift/Makefile b/devel/thrift/Makefile
index 50124b456fcd..53d590c842bf 100644
--- a/devel/thrift/Makefile
+++ b/devel/thrift/Makefile
@@ -6,12 +6,11 @@
#
PORTNAME= thrift
-PORTVERSION= 0.6.1
+PORTVERSION= 0.7.0
PORTEPOCH= 1
CATEGORIES= devel
MASTER_SITES= APACHE
MASTER_SITE_SUBDIR= /thrift/${PORTVERSION}
-DISTNAME= thrift-${PORTVERSION}
MAINTAINER= skv@FreeBSD.org
COMMENT= Framework for scalable cross-language services development
@@ -36,14 +35,16 @@ CONFIGURE_ARGS= --with-boost=${LOCALBASE} --with-libevent=${LOCALBASE} \
--enable-shared --enable-static --with-zlib
CONFIGURE_ENV+= ${MAKE_ENV}
+OPTIONS= GLIB "Building C (GLib) Library" off
+
# For Perl support, use devel/p5-Thrift.
# For Python support, use devel/py-thrift.
# For Ruby support, use devel/ruby-thrift.
+# For PHP support, use devel/php5-thrift.
# Other languages are not yet supported, please feel free to contribute
# using one of the leaf ports as an example.
CONFIGURE_ARGS+= \
--with-cpp \
- --without-c_glib \
--without-csharp \
--without-erlang \
--without-haskell \
@@ -54,6 +55,16 @@ CONFIGURE_ARGS+= \
--without-python \
--without-ruby
+.if !defined(WITHOUT_GLIB)
+ CONFIGURE_ARGS+= --with-c_glib
+ LIB_DEPENDS+= glib-2.0:${PORTSDIR}/devel/glib20
+ MAKE_ENV+= WITH_GLIB=1
+ PLIST_SUB+= WITH_GLIB=""
+.else
+ CONFIGURE_ARGS+= --without-c_glib
+ PLIST_SUB+= WITH_GLIB="@comment "
+.endif
+
.include <bsd.port.pre.mk>
.if ${ARCH} == "ia64" || ${ARCH} == "powerpc" || ${ARCH} == "sparc64"
@@ -65,6 +76,9 @@ post-patch:
pre-configure:
@${REINPLACE_CMD} '/config.h/d' ${WRKSRC}/lib/cpp/Makefile.am
+ ${CHMOD} 774 ${WRKSRC}/configure
+ ${CHMOD} 774 ${WRKSRC}/install-sh
+ ${CHMOD} 774 ${WRKSRC}/lib/php/src/ext/thrift_protocol/build/shtool
post-install:
@${LN} -sf ${PREFIX}/lib/libthrift.so.0 ${PREFIX}/lib/libthrift.so
diff --git a/devel/thrift/distinfo b/devel/thrift/distinfo
index 94b786e428a7..6d10b1d384a2 100644
--- a/devel/thrift/distinfo
+++ b/devel/thrift/distinfo
@@ -1,2 +1,2 @@
-SHA256 (thrift-0.6.1.tar.gz) = 1bed1ea17bf31c861fa8dd6e0182360eb8234383f32d0e4a36b70047b2e6b313
-SIZE (thrift-0.6.1.tar.gz) = 2034583
+SHA256 (thrift-0.7.0.tar.gz) = ca830156f6f1f94e77823eb5db6ff8f532ed5ccb9e913df83d0c3d6c4ddb9009
+SIZE (thrift-0.7.0.tar.gz) = 2248326
diff --git a/devel/thrift/files/patch-configure.ac b/devel/thrift/files/patch-configure.ac
deleted file mode 100644
index 8718ee419d25..000000000000
--- a/devel/thrift/files/patch-configure.ac
+++ /dev/null
@@ -1,11 +0,0 @@
---- configure.ac.orig 2011-03-20 21:26:41.000000000 +0000
-+++ configure.ac 2011-03-20 21:26:57.000000000 +0000
-@@ -85,7 +85,7 @@
- have_cpp=no
- if test "$with_cpp" = "yes"; then
- AX_BOOST_BASE([1.33.1])
-- if test "x$succeeded" == "xyes" ; then
-+ if test "x$succeeded" = "xyes" ; then
- have_cpp="yes"
- fi
-
diff --git a/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_framed_transport.h b/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_framed_transport.h
new file mode 100644
index 000000000000..6bc412c72c5c
--- /dev/null
+++ b/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_framed_transport.h
@@ -0,0 +1,10 @@
+--- ./lib/c_glib/src/transport/thrift_framed_transport.h.orig 2011-08-11 17:18:58.000000000 +0400
++++ ./lib/c_glib/src/transport/thrift_framed_transport.h 2011-08-26 12:00:03.000000000 +0400
+@@ -22,6 +22,7 @@
+
+ #include <glib.h>
+ #include <glib-object.h>
++#include <netinet/in.h>
+
+ #include "transport/thrift_transport.h"
+
diff --git a/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_socket.h b/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_socket.h
new file mode 100644
index 000000000000..698e4eae6c15
--- /dev/null
+++ b/devel/thrift/files/patch-lib__c_glib__src__transport__thrift_socket.h
@@ -0,0 +1,11 @@
+--- ./lib/c_glib/src/transport/thrift_socket.h.orig 2011-08-11 17:18:58.000000000 +0400
++++ ./lib/c_glib/src/transport/thrift_socket.h 2011-08-26 11:58:33.000000000 +0400
+@@ -21,6 +21,8 @@
+ #define _THRIFT_SOCKET_H
+
+ #include <glib-object.h>
++#include <sys/socket.h>
++#include <netinet/in.h>
+
+ #include "transport/thrift_transport.h"
+
diff --git a/devel/thrift/files/patch-lib__cpp__src__server__TNonblockingServer.h b/devel/thrift/files/patch-lib__cpp__src__server__TNonblockingServer.h
new file mode 100644
index 000000000000..1d92c3997951
--- /dev/null
+++ b/devel/thrift/files/patch-lib__cpp__src__server__TNonblockingServer.h
@@ -0,0 +1,12 @@
+--- ./lib/cpp/src/server/TNonblockingServer.h.orig 2011-08-11 17:18:59.000000000 +0400
++++ ./lib/cpp/src/server/TNonblockingServer.h 2011-08-26 11:47:01.000000000 +0400
+@@ -33,6 +33,9 @@
+ #include <unistd.h>
+ #include <event.h>
+
++#include <sys/types.h>
++#include <sys/socket.h>
++
+ namespace apache { namespace thrift { namespace server {
+
+ using apache::thrift::transport::TMemoryBuffer;
diff --git a/devel/thrift/pkg-plist b/devel/thrift/pkg-plist
index daf5987af60a..9ce0afa763a0 100644
--- a/devel/thrift/pkg-plist
+++ b/devel/thrift/pkg-plist
@@ -1,11 +1,9 @@
-@comment $FreeBSD$
bin/thrift
include/thrift/TApplicationException.h
include/thrift/TLogging.h
include/thrift/TProcessor.h
include/thrift/TReflectionLocal.h
include/thrift/Thrift.h
-include/thrift/async/SimpleCallback.h
include/thrift/async/TAsyncBufferProcessor.h
include/thrift/async/TAsyncChannel.h
include/thrift/async/TAsyncProcessor.h
@@ -21,8 +19,10 @@ include/thrift/concurrency/Thread.h
include/thrift/concurrency/ThreadManager.h
include/thrift/concurrency/TimerManager.h
include/thrift/concurrency/Util.h
+%%WITH_GLIB%%include/thrift/config.h
include/thrift/processor/PeekProcessor.h
include/thrift/processor/StatsProcessor.h
+%%WITH_GLIB%%include/thrift/processor/thrift_processor.h
include/thrift/protocol/TBase64Utils.h
include/thrift/protocol/TBinaryProtocol.h
include/thrift/protocol/TBinaryProtocol.tcc
@@ -35,17 +35,28 @@ include/thrift/protocol/TProtocol.h
include/thrift/protocol/TProtocolException.h
include/thrift/protocol/TProtocolTap.h
include/thrift/protocol/TVirtualProtocol.h
+%%WITH_GLIB%%include/thrift/protocol/thrift_binary_protocol.h
+%%WITH_GLIB%%include/thrift/protocol/thrift_binary_protocol_factory.h
+%%WITH_GLIB%%include/thrift/protocol/thrift_protocol.h
+%%WITH_GLIB%%include/thrift/protocol/thrift_protocol_factory.h
include/thrift/server/TNonblockingServer.h
include/thrift/server/TServer.h
include/thrift/server/TSimpleServer.h
include/thrift/server/TThreadPoolServer.h
include/thrift/server/TThreadedServer.h
+%%WITH_GLIB%%include/thrift/server/thrift_server.h
+%%WITH_GLIB%%include/thrift/server/thrift_simple_server.h
+%%WITH_GLIB%%include/thrift/thrift.h
+%%WITH_GLIB%%include/thrift/thrift_application_exception.h
+%%WITH_GLIB%%include/thrift/thrift_struct.h
include/thrift/transport/TBufferTransports.h
include/thrift/transport/TFDTransport.h
include/thrift/transport/TFileTransport.h
include/thrift/transport/THttpClient.h
include/thrift/transport/THttpServer.h
include/thrift/transport/THttpTransport.h
+include/thrift/transport/TSSLServerSocket.h
+include/thrift/transport/TSSLSocket.h
include/thrift/transport/TServerSocket.h
include/thrift/transport/TServerTransport.h
include/thrift/transport/TShortReadTransport.h
@@ -57,10 +68,22 @@ include/thrift/transport/TTransportException.h
include/thrift/transport/TTransportUtils.h
include/thrift/transport/TVirtualTransport.h
include/thrift/transport/TZlibTransport.h
+%%WITH_GLIB%%include/thrift/transport/thrift_buffered_transport.h
+%%WITH_GLIB%%include/thrift/transport/thrift_framed_transport.h
+%%WITH_GLIB%%include/thrift/transport/thrift_memory_buffer.h
+%%WITH_GLIB%%include/thrift/transport/thrift_server_socket.h
+%%WITH_GLIB%%include/thrift/transport/thrift_server_transport.h
+%%WITH_GLIB%%include/thrift/transport/thrift_socket.h
+%%WITH_GLIB%%include/thrift/transport/thrift_transport.h
+%%WITH_GLIB%%include/thrift/transport/thrift_transport_factory.h
lib/libthrift.a
lib/libthrift.la
lib/libthrift.so
lib/libthrift.so.0
+%%WITH_GLIB%%lib/libthrift_c_glib.a
+%%WITH_GLIB%%lib/libthrift_c_glib.la
+%%WITH_GLIB%%lib/libthrift_c_glib.so
+%%WITH_GLIB%%lib/libthrift_c_glib.so.0
lib/libthriftnb.a
lib/libthriftnb.la
lib/libthriftnb.so
@@ -69,6 +92,8 @@ lib/libthriftz.a
lib/libthriftz.la
lib/libthriftz.so
lib/libthriftz.so.0
+%%WITH_GLIB%%lib/pkgconfig/thrift_c_glib.pc
+@dirrmtry %%WITH_GLIB%%lib/pkgconfig
libdata/pkgconfig/thrift-nb.pc
libdata/pkgconfig/thrift-z.pc
libdata/pkgconfig/thrift.pc