From f66547f84e26a3a4e2e2d58680afdf6c60fd7291 Mon Sep 17 00:00:00 2001 From: merge-script Date: Tue, 6 Aug 2024 10:30:00 +0100 Subject: [PATCH] Merge bitcoin/bitcoin#30588: depends: fix ZMQ CMake getcachesize check a0a9a11642752578fb1f5142c3fb26cb39d1548a depends: fix ZMQ CMake getcachesize check (fanquake) Pull request description: Fixes #30587. ACKs for top commit: maflcko: ACK a0a9a11642752578fb1f5142c3fb26cb39d1548a hebasto: ACK a0a9a11642752578fb1f5142c3fb26cb39d1548a. On Ubuntu (s390x), I was able to reproduce https://github.com/bitcoin/bitcoin/issues/30587. With this PR building `zeromq` succeeds. TheCharlatan: ACK a0a9a11642752578fb1f5142c3fb26cb39d1548a Tree-SHA512: 70ca50ebe8e36d5a10a2354a1fbed49f5f802ae5115e09686bccca7e5d1da35168e84a6cab40dd2c83f8918889cdfdcbd5d1cbe25273b844c8ddd21865ea6c51 --- depends/packages/zeromq.mk | 2 ++ depends/patches/zeromq/cacheline_undefined.patch | 15 +++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 depends/patches/zeromq/cacheline_undefined.patch diff --git a/depends/packages/zeromq.mk b/depends/packages/zeromq.mk index a6b12f5b52..d9c1253484 100644 --- a/depends/packages/zeromq.mk +++ b/depends/packages/zeromq.mk @@ -10,6 +10,7 @@ $(package)_patches += builtin_sha1.patch $(package)_patches += fix_have_windows.patch $(package)_patches += openbsd_kqueue_headers.patch $(package)_patches += cmake_minimum.patch +$(package)_patches += cacheline_undefined.patch $(package)_patches += no_librt.patch $(package)_patches += fix_mingw_link.patch @@ -28,6 +29,7 @@ define $(package)_preprocess_cmds patch -p1 < $($(package)_patch_dir)/remove_libstd_link.patch && \ patch -p1 < $($(package)_patch_dir)/macos_mktemp_check.patch && \ patch -p1 < $($(package)_patch_dir)/builtin_sha1.patch && \ + patch -p1 < $($(package)_patch_dir)/cacheline_undefined.patch && \ patch -p1 < $($(package)_patch_dir)/fix_have_windows.patch && \ patch -p1 < $($(package)_patch_dir)/openbsd_kqueue_headers.patch && \ patch -p1 < $($(package)_patch_dir)/cmake_minimum.patch && \ diff --git a/depends/patches/zeromq/cacheline_undefined.patch b/depends/patches/zeromq/cacheline_undefined.patch new file mode 100644 index 0000000000..02bd2a5fe5 --- /dev/null +++ b/depends/patches/zeromq/cacheline_undefined.patch @@ -0,0 +1,15 @@ +Use proper STREQUAL instead of EQUAL to compare strings.txt + +See: https://github.com/zeromq/libzmq/pull/4711. + +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -476,7 +476,7 @@ execute_process( + if(CACHELINE_SIZE STREQUAL "" + OR CACHELINE_SIZE EQUAL 0 + OR CACHELINE_SIZE EQUAL -1 +- OR CACHELINE_SIZE EQUAL "undefined") ++ OR CACHELINE_SIZE STREQUAL "undefined") + set(ZMQ_CACHELINE_SIZE 64) + else() + set(ZMQ_CACHELINE_SIZE ${CACHELINE_SIZE})