From 5bfb13032e3963306a14fedc660d6218c48741f8 Mon Sep 17 00:00:00 2001 From: Luca Boccassi Date: Fri, 4 Oct 2019 15:19:16 +0100 Subject: [PATCH] Problem: packages not build with TLS support Solution: add dependency to gnutls --- packaging/debian/control | 2 ++ packaging/debian/rules | 2 +- packaging/debian/zeromq.dsc.obs | 2 +- packaging/redhat/zeromq.spec | 32 ++++++++++++++++++++++++++++++++ 4 files changed, 36 insertions(+), 2 deletions(-) diff --git a/packaging/debian/control b/packaging/debian/control index 2bcc6fce..878392d3 100644 --- a/packaging/debian/control +++ b/packaging/debian/control @@ -10,6 +10,7 @@ Build-Depends: debhelper (>= 9), libsodium-dev, libunwind-dev | libunwind8-dev | libunwind7-dev, libnss3-dev, + libgnutls28-dev, pkg-config, asciidoc-base | asciidoc, xmlto, Standards-Version: 3.9.8 @@ -40,6 +41,7 @@ Depends: libzmq5 (= ${binary:Version}), ${misc:Depends}, libsodium-dev, libunwind-dev | libunwind8-dev | libunwind7-dev, libnss3-dev, + libgnutls28-dev, Conflicts: libzmq-dev, libzmq5-dev Replaces: libzmq5-dev Provides: libzmq5-dev diff --git a/packaging/debian/rules b/packaging/debian/rules index 6a7b4ca5..b1e6abbd 100755 --- a/packaging/debian/rules +++ b/packaging/debian/rules @@ -43,7 +43,7 @@ override_dh_clean: rm -f config.log override_dh_auto_configure: - dh_auto_configure -- --with-pgm --with-libsodium --enable-drafts=$(DRAFTS) --with-libgssapi_krb5=yes --with-norm=yes --with-nss=yes + dh_auto_configure -- --with-pgm --with-libsodium --enable-drafts=$(DRAFTS) --with-libgssapi_krb5=yes --with-norm=yes --with-nss=yes --with-tls=yes override_dh_auto_test: ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) diff --git a/packaging/debian/zeromq.dsc.obs b/packaging/debian/zeromq.dsc.obs index 94c78973..57adae9a 100644 --- a/packaging/debian/zeromq.dsc.obs +++ b/packaging/debian/zeromq.dsc.obs @@ -6,7 +6,7 @@ Version: 4.3.3 Maintainer: libzmq Developers Homepage: http://www.zeromq.org/ Standards-Version: 3.9.8 -Build-Depends: debhelper (>= 9), dh-autoreconf, libkrb5-dev, libpgm-dev, libnorm-dev, libsodium-dev, libunwind-dev | libunwind8-dev | libunwind7-dev, libnss3-dev, pkg-config, asciidoc-base | asciidoc, xmlto +Build-Depends: debhelper (>= 9), dh-autoreconf, libkrb5-dev, libpgm-dev, libnorm-dev, libsodium-dev, libunwind-dev | libunwind8-dev | libunwind7-dev, libnss3-dev, libgnutls28-dev, pkg-config, asciidoc-base | asciidoc, xmlto Package-List: libzmq3-dev deb libdevel optional arch=any libzmq5 deb libs optional arch=any diff --git a/packaging/redhat/zeromq.spec b/packaging/redhat/zeromq.spec index f4c74e0b..44216097 100644 --- a/packaging/redhat/zeromq.spec +++ b/packaging/redhat/zeromq.spec @@ -56,6 +56,17 @@ BuildRequires: nss-devel %else %define NSS no %endif +%bcond_with tls +%if %{with tls} && ! 0%{?centos_version} < 700 +%if 0%{?suse_version} +BuildRequires: libgnutls-devel +%else +BuildRequires: gnutls-devel +%endif +%define TLS yes +%else +%define TLS no +%endif BuildRequires: gcc, make, gcc-c++, libstdc++-devel, asciidoc, xmlto Requires: libstdc++ @@ -95,6 +106,15 @@ Requires: libstdc++ %{?_with_nss:Requires: nss} %endif +%if ! 0%{?centos_version} < 700 +%if 0%{?suse_version} +%{?_with_tls:BuildRequires: libgnutls-devel} +%else +%{?_with_tls:BuildRequires: gnutls-devel} +%endif +%{?_with_tls:Requires: gnutls} +%endif + %ifarch pentium3 pentium4 athlon i386 i486 i586 i686 x86_64 %{!?_with_pic: %{!?_without_pic: %define _with_pic --with-pic}} %{!?_with_gnu_ld: %{!?_without_gnu_ld: %define _with_gnu_ld --with-gnu_ld}} @@ -150,6 +170,14 @@ Requires: mozilla-nss-devel Requires: nss-devel %endif %endif +%bcond_with tls +%if %{with tls} && ! 0%{?centos_version} < 700 +%if 0%{?suse_version} +Requires: libgnutls-devel +%else +Requires: gnutls-devel +%endif +%endif %description devel The 0MQ lightweight messaging kernel is a library which extends the @@ -192,6 +220,7 @@ autoreconf -fi --with-libsodium=%{SODIUM} \ --with-libgssapi_krb5=%{GSSAPI} \ --with-nss=%{NSS} \ + --with-tls=%{TLS} \ %{?_with_pic} \ %{?_without_pic} \ %{?_with_gnu_ld} \ @@ -244,6 +273,9 @@ autoreconf -fi %{_bindir}/curve_keygen %changelog +* Fri Oct 4 2019 Luca Boccassi +- Add macro for optional TLS dependency + * Wed Sep 11 2019 Luca Boccassi - Add macro for optional NSS dependency