zeromq: update to 4.3.4
Added patch to fix compilation with clang. Added patch stuff from pupnp for ease of patching. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
--- a/tests/testutil.cpp
|
||||
+++ b/tests/testutil.cpp
|
||||
@@ -382,7 +382,7 @@ fd_t connect_socket (const char *endpoint_, const int af_, const int protocol_)
|
||||
@@ -386,7 +386,7 @@ fd_t connect_socket (const char *endpoint_, const int af_, const int protocol_)
|
||||
protocol_ == IPPROTO_UDP
|
||||
? IPPROTO_UDP
|
||||
: protocol_ == IPPROTO_TCP ? IPPROTO_TCP : 0);
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
if (af_ == AF_INET || af_ == AF_INET6) {
|
||||
const char *port = strrchr (endpoint_, ':') + 1;
|
||||
@@ -439,7 +439,7 @@ fd_t bind_socket_resolve_port (const char *address_,
|
||||
@@ -443,7 +443,7 @@ fd_t bind_socket_resolve_port (const char *address_,
|
||||
protocol_ == IPPROTO_UDP
|
||||
? IPPROTO_UDP
|
||||
: protocol_ == IPPROTO_TCP ? IPPROTO_TCP : 0);
|
||||
@@ -32,7 +32,7 @@
|
||||
|
||||
--- a/tests/testutil.cpp
|
||||
+++ b/tests/testutil.cpp
|
||||
@@ -296,7 +296,7 @@ int is_ipv6_available ()
|
||||
@@ -300,7 +300,7 @@ int is_ipv6_available ()
|
||||
ipv6 = 0;
|
||||
}
|
||||
#endif
|
||||
@@ -41,7 +41,7 @@
|
||||
}
|
||||
|
||||
return ipv6;
|
||||
@@ -484,7 +484,7 @@ fd_t bind_socket_resolve_port (const char *address_,
|
||||
@@ -488,7 +488,7 @@ fd_t bind_socket_resolve_port (const char *address_,
|
||||
#else
|
||||
int fd = mkstemp (buffer);
|
||||
TEST_ASSERT_TRUE (fd != -1);
|
||||
|
||||
27
mingw-w64-zeromq/002-unused.patch
Normal file
27
mingw-w64-zeromq/002-unused.patch
Normal file
@@ -0,0 +1,27 @@
|
||||
From a02cbd0646175a44edb1d636911eb8dae12ec13f Mon Sep 17 00:00:00 2001
|
||||
From: Rosen Penev <rosenp@gmail.com>
|
||||
Date: Sun, 2 May 2021 16:49:27 -0700
|
||||
Subject: [PATCH] fix unused variables under windows
|
||||
|
||||
Fixes compilation as -Werror is passed.
|
||||
---
|
||||
src/clock.cpp | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/clock.cpp b/src/clock.cpp
|
||||
index 79522ad38..93da90a8e 100644
|
||||
--- a/src/clock.cpp
|
||||
+++ b/src/clock.cpp
|
||||
@@ -126,9 +126,11 @@ static f_compatible_get_tick_count64 my_get_tick_count64 =
|
||||
init_compatible_get_tick_count64 ();
|
||||
#endif
|
||||
|
||||
+#ifndef ZMQ_HAVE_WINDOWS
|
||||
const uint64_t usecs_per_msec = 1000;
|
||||
-const uint64_t usecs_per_sec = 1000000;
|
||||
const uint64_t nsecs_per_usec = 1000;
|
||||
+#endif
|
||||
+const uint64_t usecs_per_sec = 1000000;
|
||||
|
||||
zmq::clock_t::clock_t () :
|
||||
_last_tsc (rdtsc ()),
|
||||
@@ -3,7 +3,7 @@
|
||||
_realname=zeromq
|
||||
pkgbase=mingw-w64-${_realname}
|
||||
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
|
||||
pkgver=4.3.3
|
||||
pkgver=4.3.4
|
||||
_cppzmqver=4.7.1
|
||||
pkgrel=1
|
||||
pkgdesc="Fast messaging system built on sockets, C and C++ bindings. aka 0MQ, ZMQ (mingw-w64)"
|
||||
@@ -17,15 +17,30 @@ options=('staticlibs' 'strip')
|
||||
source=("https://github.com/zeromq/libzmq/releases/download/v${pkgver}/${_realname}-${pkgver}.tar.gz"
|
||||
"zmq-${_cppzmqver}.hpp::https://raw.githubusercontent.com/zeromq/cppzmq/v${_cppzmqver}/zmq.hpp"
|
||||
"zmq_addon-${_cppzmqver}.hpp::https://raw.githubusercontent.com/zeromq/cppzmq/v${_cppzmqver}/zmq_addon.hpp"
|
||||
"001-testutil_different_signedness-fix.patch")
|
||||
sha256sums=('9d9285db37ae942ed0780c016da87060497877af45094ff9e1a1ca736e3875a2'
|
||||
"001-testutil_different_signedness-fix.patch"
|
||||
"002-unused.patch::https://patch-diff.githubusercontent.com/raw/zeromq/libzmq/pull/4181.patch")
|
||||
sha256sums=('c593001a89f5a85dd2ddf564805deb860e02471171b3f204944857336295c3e5'
|
||||
'92b92acc0a93f9511097df20cc9ed4041bde4d0d9c6cdd6cc2ada29c84487ab8'
|
||||
'705bac35610437f22243da8cf300488d1e37c0815c60f70809051a8be8d0cb4c'
|
||||
'af238d54dd615654fda61e42bb6393da529cb288a74310f2c82d5d27933c1011')
|
||||
'0bfdbd8caca39791c909c2cbeba5878a9c430d8a9dd1f06458f42656f593e8c6'
|
||||
'035e2d7cfa8a5d5fff2d0ae9be17c58f0e4d300cc34182091fa25d2d7ac4ac57')
|
||||
|
||||
# Helper macros to help make tasks easier #
|
||||
apply_patch_with_msg() {
|
||||
for _patch in "$@"
|
||||
do
|
||||
msg2 "Applying ${_patch}"
|
||||
patch -Nbp1 -i "${srcdir}/${_patch}"
|
||||
done
|
||||
}
|
||||
|
||||
prepare() {
|
||||
cd ${_realname}-${pkgver}
|
||||
patch -Np1 -i "${srcdir}/001-testutil_different_signedness-fix.patch"
|
||||
apply_patch_with_msg \
|
||||
001-testutil_different_signedness-fix.patch \
|
||||
002-unused.patch
|
||||
|
||||
autoreconf -fi
|
||||
}
|
||||
|
||||
build() {
|
||||
|
||||
Reference in New Issue
Block a user