From: Charles McGarvey Date: Mon, 21 Jan 2013 18:16:30 +0000 (-0700) Subject: add conditional-eproto patch; bump version number X-Git-Tag: v0.0401^0 X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fp5-Alien-ZMQ;a=commitdiff_plain;h=db8094cee87e60a7167d3777e8fc96e51d7d6c8d add conditional-eproto patch; bump version number --- diff --git a/dist.ini b/dist.ini index 3805e61..c021fe4 100644 --- a/dist.ini +++ b/dist.ini @@ -1,6 +1,6 @@ name = Alien-ZMQ -version = 0.04 +version = 0.0401 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 new file mode 100644 index 0000000..31aad06 --- /dev/null +++ b/files/zeromq-3.2.2-conditional-eproto.patch @@ -0,0 +1,38 @@ +diff -ur zeromq-3.2.2.orig/src/err.hpp zeromq-3.2.2/src/err.hpp +--- zeromq-3.2.2.orig/src/err.hpp 2012-10-25 02:30:40.000000000 -0600 ++++ zeromq-3.2.2/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/inc/My/Build.pm b/inc/My/Build.pm index a6a55f4..fa8eb27 100644 --- a/inc/My/Build.pm +++ b/inc/My/Build.pm @@ -183,7 +183,7 @@ sub install_zeromq { say "Patching..."; for my $patch (glob("$basedir/files/zeromq-$version-*.patch")) { - run ["patch"], '<', $patch or die "Failed to patch ØMQ"; + run [qw/patch -p1/], '<', $patch or die "Failed to patch ØMQ"; } say "Configuring...";