commit:     4ac92215090531622c65e6ac10f961dc780156e7
Author:     Jakov Smolic <jakov.smolic <AT> sartura <DOT> hr>
AuthorDate: Mon Feb  1 12:22:55 2021 +0000
Commit:     Ben Kohler <bkohler <AT> gentoo <DOT> org>
CommitDate: Tue Feb  9 16:59:26 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ac92215

www-apache/mod_nss: Bump to 1.0.18

Closes: https://bugs.gentoo.org/707172
Closes: https://bugs.gentoo.org/742455

Signed-off-by: Jakov Smolic <jakov.smolic <AT> sartura.hr>
Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org>

 www-apache/mod_nss/Manifest                        |  1 +
 .../mod_nss/files/mod_nss-1.0.18-fno-common.patch  | 14 +++++
 www-apache/mod_nss/mod_nss-1.0.18.ebuild           | 64 ++++++++++++++++++++++
 3 files changed, 79 insertions(+)

diff --git a/www-apache/mod_nss/Manifest b/www-apache/mod_nss/Manifest
index 90c01aff6b2..e13e9e18848 100644
--- a/www-apache/mod_nss/Manifest
+++ b/www-apache/mod_nss/Manifest
@@ -1 +1,2 @@
 DIST mod_nss-1.0.12.tar.gz 171657 BLAKE2B 
75fbde10bb236536aeabc5c15d3d77d9ef4d6b0397dcab433cbfdffdfa2657a59ae2688f0904206897e7fd97e1282f50fe65df37a4cb3457c14c9647bb785fa3
 SHA512 
f3217f34a20818aea571e17529130290082933b32386a868c8c7f24eb3166bbace4f64d7d73a850c944e54f74342179fff6b9d8af824e0225feeb993aea1d99a
+DIST mod_nss-1.0.18.tar.gz 184594 BLAKE2B 
a2c4b07199bb694b4e5a87ec6bf12bbf32862d44a478da3eb7f374f273786a8d66e3c238fea8e3512fa4986366d44fc8ef4ff77d8965afeee716bcc0685040d0
 SHA512 
68fe061b40acbe07823ba220a67b0646855b7643e472e757f23b38074fab95aa1b99a3f525748d5dd363b8e278e5521cbacae49c0159700e33f2e1b6b0a0bb77

diff --git a/www-apache/mod_nss/files/mod_nss-1.0.18-fno-common.patch 
b/www-apache/mod_nss/files/mod_nss-1.0.18-fno-common.patch
new file mode 100644
index 00000000000..c6e7babc1d2
--- /dev/null
+++ b/www-apache/mod_nss/files/mod_nss-1.0.18-fno-common.patch
@@ -0,0 +1,14 @@
+https://bugs.gentoo.org/707172
+--- a/mod_nss.h
++++ b/mod_nss.h
+@@ -376,8 +376,8 @@ typedef struct {
+  */
+ 
+ /* pool and hash to store ServerName and NSSNickname pairs for SNI */
+-apr_pool_t *mp;
+-apr_hash_t *ht;
++extern apr_pool_t *mp;
++extern apr_hash_t *ht;
+ 
+ /* Compatibility between Apache 2.0.x and 2.2.x. The numeric version of
+  * the version first appeared in Apache 2.0.56-dev. I picked 2.0.55 as it

diff --git a/www-apache/mod_nss/mod_nss-1.0.18.ebuild 
b/www-apache/mod_nss/mod_nss-1.0.18.ebuild
new file mode 100644
index 00000000000..310b5c21508
--- /dev/null
+++ b/www-apache/mod_nss/mod_nss-1.0.18.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools apache-module
+
+DESCRIPTION="SSL/TLS module for the Apache HTTP server"
+HOMEPAGE="https://pagure.io/mod_nss";
+SRC_URI="https://releases.pagure.org/${PN}/${P}.tar.gz";
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+ecc"
+
+# https://bugs.gentoo.org/742455
+RESTRICT="test"
+
+DEPEND="
+       dev-libs/nspr
+       dev-libs/nss"
+RDEPEND="${DEPEND}
+       net-dns/bind-tools"
+BDEPEND="virtual/pkgconfig"
+
+APACHE2_MOD_CONF="47_${PN}"
+APACHE2_MOD_DEFINE="NSS"
+
+need_apache2
+
+PATCHES=( "${FILESDIR}"/${P}-fno-common.patch )
+
+src_prepare() {
+       default
+
+       # setup proper exec name
+       sed -i -e 's/certutil/nsscertutil/' gencert.in || die "sed failed"
+       eautoreconf
+}
+
+src_configure() {
+       econf $(use_enable ecc) --with-apxs=${APXS}
+}
+
+src_compile() {
+       # default src_compile fails:
+       # In file included from mod_nss.c:16:0:
+       # mod_nss.h:51:18: fatal error: nspr.h: No such file or directory
+       emake
+}
+
+src_install() {
+       # override broken build system
+       mv .libs/libmodnss.so .libs/"${PN}".so || die "cannot move lib"
+       dosbin gencert nss_pcache
+       dodoc docs/mod_nss.html
+       newbin migrate.pl nss_migrate
+       dodir /etc/apache2/nss
+       einstalldocs
+
+       APACHE_MODULESDIR="/usr/$(get_libdir)/apache2/modules"
+       apache-module_src_install
+}

Reply via email to