Skip to content

Commit 2de68d6

Browse files
committed
depends: add zeromq builtin sha1 patch
1 parent 0c86052 commit 2de68d6

File tree

2 files changed

+20
-1
lines changed

2 files changed

+20
-1
lines changed

depends/packages/zeromq.mk

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ $(package)_file_name=$(package)-$($(package)_version).tar.gz
55
$(package)_sha256_hash=6653ef5910f17954861fe72332e68b03ca6e4d9c7160eb3a8de5a5a913bfab43
66
$(package)_patches = remove_libstd_link.patch
77
$(package)_patches += macos_mktemp_check.patch
8+
$(package)_patches += builtin_sha1.patch
89

910
define $(package)_set_vars
1011
$(package)_config_opts = --without-docs --disable-shared --disable-valgrind
@@ -16,7 +17,8 @@ endef
1617

1718
define $(package)_preprocess_cmds
1819
patch -p1 < $($(package)_patch_dir)/remove_libstd_link.patch && \
19-
patch -p1 < $($(package)_patch_dir)/macos_mktemp_check.patch
20+
patch -p1 < $($(package)_patch_dir)/macos_mktemp_check.patch && \
21+
patch -p1 < $($(package)_patch_dir)/builtin_sha1.patch
2022
endef
2123

2224
define $(package)_config_cmds
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
Don't use builtin sha1 if not using ws
2+
3+
The builtin SHA1 (ZMQ_USE_BUILTIN_SHA1) is only used in the websocket
4+
engine (ws_engine.cpp).
5+
Upstreamed in https://github.com/zeromq/libzmq/pull/4670.
6+
7+
--- a/CMakeLists.txt
8+
+++ b/CMakeLists.txt
9+
@@ -234,7 +234,7 @@ if(NOT ZMQ_USE_GNUTLS)
10+
endif()
11+
endif()
12+
endif()
13+
- if(NOT ZMQ_USE_NSS)
14+
+ if(ENABLE_WS AND NOT ZMQ_USE_NSS)
15+
list(APPEND sources ${CMAKE_CURRENT_SOURCE_DIR}/external/sha1/sha1.c
16+
${CMAKE_CURRENT_SOURCE_DIR}/external/sha1/sha1.h)
17+
message(STATUS "Using builtin sha1")

0 commit comments

Comments
 (0)