From 03cf2eb0e346efc4529e3deb029f8228502c7448 Mon Sep 17 00:00:00 2001 From: Charles McGarvey Date: Thu, 2 May 2013 18:28:44 -0600 Subject: [PATCH] switch distribution to zeromq-3.2.3; bump version --- Build.PL | 4 +- dist.ini | 2 +- files/zeromq-3.2.2-conditional-eproto.patch | 37 ------------------- files/zeromq-3.2.3-conditional-eproto.patch | 15 ++++++++ ...ests.patch => zeromq-3.2.3-no-tests.patch} | 6 ++- lib/Alien/ZMQ.pm | 21 +++++------ 6 files changed, 32 insertions(+), 53 deletions(-) delete mode 100644 files/zeromq-3.2.2-conditional-eproto.patch create mode 100644 files/zeromq-3.2.3-conditional-eproto.patch rename files/{zeromq-3.2.2-no-tests.patch => zeromq-3.2.3-no-tests.patch} (73%) diff --git a/Build.PL b/Build.PL index 086a271..9fb1901 100644 --- a/Build.PL +++ b/Build.PL @@ -16,7 +16,7 @@ my $builder = My::Build->new( dist_version_from => "lib/Alien/ZMQ.pm", share_dir => "share", ); -$builder->notes('zmq-version', '3.2.2'); -$builder->notes('zmq-sha1', '0e8734c773b6a757b474c16fc3c517993ba47283'); +$builder->notes('zmq-version', '3.2.3'); +$builder->notes('zmq-sha1', '6857a3a0e908eca58f7c0f90e2ba4695f6700957'); $builder->create_build_script; diff --git a/dist.ini b/dist.ini index ad6a5ac..567ec66 100644 --- a/dist.ini +++ b/dist.ini @@ -1,6 +1,6 @@ name = Alien-ZMQ -version = 0.0403 +version = 0.05 author = Charles McGarvey license = Perl_5 copyright_holder = Charles McGarvey diff --git a/files/zeromq-3.2.2-conditional-eproto.patch b/files/zeromq-3.2.2-conditional-eproto.patch deleted file mode 100644 index d9b9d9a..0000000 --- a/files/zeromq-3.2.2-conditional-eproto.patch +++ /dev/null @@ -1,37 +0,0 @@ ---- a/src/err.hpp 2012-10-25 02:30:40.000000000 -0600 -+++ b/src/err.hpp 2013-01-21 10:56:25.095010874 -0700 -@@ -152,4 +152,10 @@ - - #endif - -+// Conditionally check for EPROTO; some platforms (OpenBSD) don't support it. -+#ifdef EPROTO -+#define OR_ERRNO_EQ_EPROTO || errno == EPROTO -+#else -+#define OR_ERRNO_EQ_EPROTO -+#endif - -diff -ur zeromq-3.2.2.orig/src/ipc_listener.cpp zeromq-3.2.2/src/ipc_listener.cpp ---- zeromq-3.2.2.orig/src/ipc_listener.cpp 2012-11-23 00:54:28.000000000 -0700 -+++ zeromq-3.2.2/src/ipc_listener.cpp 2013-01-21 10:57:02.670355121 -0700 -@@ -196,7 +196,7 @@ - fd_t sock = ::accept (s, NULL, NULL); - if (sock == -1) { - errno_assert (errno == EAGAIN || errno == EWOULDBLOCK || -- errno == EINTR || errno == ECONNABORTED || errno == EPROTO || -+ errno == EINTR || errno == ECONNABORTED OR_ERRNO_EQ_EPROTO || - errno == ENFILE); - return retired_fd; - } -diff -ur zeromq-3.2.2.orig/src/tcp_listener.cpp zeromq-3.2.2/src/tcp_listener.cpp ---- zeromq-3.2.2.orig/src/tcp_listener.cpp 2012-11-23 00:54:28.000000000 -0700 -+++ zeromq-3.2.2/src/tcp_listener.cpp 2013-01-21 10:56:48.884173113 -0700 -@@ -262,7 +262,7 @@ - #else - if (sock == -1) { - errno_assert (errno == EAGAIN || errno == EWOULDBLOCK || -- errno == EINTR || errno == ECONNABORTED || errno == EPROTO || -+ errno == EINTR || errno == ECONNABORTED OR_ERRNO_EQ_EPROTO || - errno == ENOBUFS || errno == ENOMEM || errno == EMFILE || - errno == ENFILE); - return retired_fd; diff --git a/files/zeromq-3.2.3-conditional-eproto.patch b/files/zeromq-3.2.3-conditional-eproto.patch new file mode 100644 index 0000000..1c4d745 --- /dev/null +++ b/files/zeromq-3.2.3-conditional-eproto.patch @@ -0,0 +1,15 @@ +This patch is for platforms which don't define EPROTO. +--- a/src/err.hpp ++++ b/src/err.hpp +@@ -44,6 +44,11 @@ + #include + #endif + ++// EPROTO is not used by OpenBSD and maybe other platforms. ++#ifndef EPROTO ++#define EPROTO 0 ++#endif ++ + namespace zmq + { + const char *errno_to_string (int errno_); diff --git a/files/zeromq-3.2.2-no-tests.patch b/files/zeromq-3.2.3-no-tests.patch similarity index 73% rename from files/zeromq-3.2.2-no-tests.patch rename to files/zeromq-3.2.3-no-tests.patch index 0c3c57f..b06c6fa 100644 --- a/files/zeromq-3.2.2-no-tests.patch +++ b/files/zeromq-3.2.3-no-tests.patch @@ -1,5 +1,7 @@ ---- a/Makefile.in 2012-11-23 00:58:57.000000000 -0700 -+++ b/Makefile.in 2013-01-18 23:08:21.794836073 -0700 +This patch prevents the tests from being built. This is required for platforms +that do not support pthreads. +--- a/Makefile.in ++++ b/Makefile.in @@ -256,8 +256,8 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ diff --git a/lib/Alien/ZMQ.pm b/lib/Alien/ZMQ.pm index 3990b86..4660cfb 100644 --- a/lib/Alien/ZMQ.pm +++ b/lib/Alien/ZMQ.pm @@ -1,5 +1,5 @@ package Alien::ZMQ; -# ABSTRACT: finding and installing libzmq, the core zeromq library +# ABSTRACT: find and install libzmq, the core zeromq library use warnings; use strict; @@ -9,15 +9,9 @@ use String::ShellQuote qw/shell_quote/; =head1 DESCRIPTION Upon installation, the target system is probed for the presence of libzmq. If -it is not found, B is installed in a shared directory. In +it is not found, B is installed in a shared directory. In short, modules that need libzmq can depend on this module to make sure that it -is available. - -This module is still B. In particular, I'm still pondering on -how S should be handled. Currently, if S is found on -the system, L will use it, but there is no way to install -S with L. I'm not sure what the most useful behavior -with regards to S is, so please talk to me if you have any ideas. +is available, or use it independently as a way to install zeromq. =head1 SYNOPSIS @@ -56,9 +50,9 @@ not be used when compiling libzmq from source (if it needs to be). To affect the compiling of libzmq, using the L flag instead. A better alternative to using L and L is to help -the L program find your libzmq by using the C +the L program find your libzmq by using the C environment variable. Of course, this method requires that you have the -L program installed. Here's an example: +L program installed. Here's an example: perl Build.PL PKG_CONFIG_PATH=/opt/zeromq/lib/pkgconfig ./Build @@ -86,6 +80,11 @@ Probing is only done during the installation of this module, so if you are using a system-installed version of libzmq and you uninstall or upgrade it, you will also need to reinstall L. +If S is found on the system, L will use it. There are +a few incompatibilities between S and S, so your +program may want to use the L method to check which version of +libzmq is installed. + =head1 BUGS MSWin32 is not yet supported, but cygwin works. -- 2.43.0