From 330b772dc0b59671cb55ed36856d876868bc94b7 Mon Sep 17 00:00:00 2001 From: orbea Date: Sat, 16 Mar 2024 08:32:32 -0700 Subject: www-apache/mod_jk: fix global symbols The libtool -export-symbols-regex flag controls which symbols are exported globally in the library, but GNU libtool silently drops many unknown flags... Closes: https://bugs.gentoo.org/914237 Upstream-Commit: https://github.com/apache/tomcat-connectors/commit/ecd005d0792441c4510dc4c2d9348979ab71ddcc Signed-off-by: orbea Closes: https://github.com/gentoo/gentoo/pull/35781 Signed-off-by: Conrad Kostecki --- .../files/mod_jk-1.2.49-export-symbols-regex.patch | 40 +++++++++++ www-apache/mod_jk/mod_jk-1.2.49-r1.ebuild | 82 ++++++++++++++++++++++ www-apache/mod_jk/mod_jk-1.2.49.ebuild | 79 --------------------- 3 files changed, 122 insertions(+), 79 deletions(-) create mode 100644 www-apache/mod_jk/files/mod_jk-1.2.49-export-symbols-regex.patch create mode 100644 www-apache/mod_jk/mod_jk-1.2.49-r1.ebuild delete mode 100644 www-apache/mod_jk/mod_jk-1.2.49.ebuild (limited to 'www-apache') diff --git a/www-apache/mod_jk/files/mod_jk-1.2.49-export-symbols-regex.patch b/www-apache/mod_jk/files/mod_jk-1.2.49-export-symbols-regex.patch new file mode 100644 index 000000000000..1dd05d9c70ed --- /dev/null +++ b/www-apache/mod_jk/files/mod_jk-1.2.49-export-symbols-regex.patch @@ -0,0 +1,40 @@ +https://bugs.gentoo.org/914237 +https://github.com/apache/tomcat-connectors/commit/ecd005d0792441c4510dc4c2d9348979ab71ddcc + +From ecd005d0792441c4510dc4c2d9348979ab71ddcc Mon Sep 17 00:00:00 2001 +From: Rainer Jung +Date: Fri, 10 Nov 2023 11:38:04 +0100 +Subject: [PATCH] BZ 68117: Fix typo and escaping in libtool flag introduced in + 1.2.49. + +--- + apache-2.0/Makefile.apxs.in | 2 +- + apache-2.0/Makefile.in | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/apache-2.0/Makefile.apxs.in b/apache-2.0/Makefile.apxs.in +index 36aeada1c..161616502 100644 +--- a/apache-2.0/Makefile.apxs.in ++++ b/apache-2.0/Makefile.apxs.in +@@ -21,7 +21,7 @@ top_builddir=@top_builddir@ + APXS=@APXS@ + APXSCFLAGS=@APXSCFLAGS@ + APXSLDFLAGS=@APXSLDFLAGS@ +-JKLDFLAGS=-export-symbols-regex ^jk_module$ ++JKLDFLAGS=-export-symbols-regex ^jk_module\$$ + + COMMON=common + JK_INCL=-DUSE_APACHE_MD5 -I${top_builddir}/${COMMON} -I ${top_srcdir}/${COMMON} +diff --git a/apache-2.0/Makefile.in b/apache-2.0/Makefile.in +index e63f5c921..a9327743b 100644 +--- a/apache-2.0/Makefile.in ++++ b/apache-2.0/Makefile.in +@@ -23,7 +23,7 @@ MKDIR=@MKDIR@ + APXSCFLAGS=@APXSCFLAGS@ + APXSCPPFLAGS=@APXSCPPFLAGS@ + APXSLDFLAGS=@APXSLDFLAGS@ +-JKLDFLAGS=-export-symbols-regexp ^jk_module$ ++JKLDFLAGS=-export-symbols-regex ^jk_module\$$ + + CC=@CC@ + SHELL=@SHELL@ diff --git a/www-apache/mod_jk/mod_jk-1.2.49-r1.ebuild b/www-apache/mod_jk/mod_jk-1.2.49-r1.ebuild new file mode 100644 index 000000000000..4356eed57aec --- /dev/null +++ b/www-apache/mod_jk/mod_jk-1.2.49-r1.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +MY_P="tomcat-connectors-${PV#-*}-src" + +inherit apache-module autotools verify-sig + +DESCRIPTION="Provides an AJP Apache2-JK-connector for the Tomcat servlet engine" +HOMEPAGE="https://tomcat.apache.org/connectors-doc/" +SRC_URI="mirror://apache/tomcat/tomcat-connectors/jk/${MY_P}.tar.gz + verify-sig? ( https://downloads.apache.org/tomcat/tomcat-connectors/jk/tomcat-connectors-${PV}-src.tar.gz.asc )" +S="${WORKDIR}/${MY_P}/native" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc x86" + +DEPEND="dev-libs/apr:1=" +RDEPEND="${DEPEND}" +BDEPEND=" + dev-lang/perl + verify-sig? ( sec-keys/openpgp-keys-apache-tomcat-connectors ) +" + +PATCHES=( + "${FILESDIR}/${PN}-1.2.49-export-symbols-regex.patch" #914237 + "${FILESDIR}/${PN}-1.2.49-musl.patch" +) + +APACHE2_MOD_FILE="${S}/apache-2.0/${PN}.so" +APACHE2_MOD_DEFINE="JK" +VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/openpgp-keys/tomcat-connectors.apache.org.asc" + +need_apache2 + +pkg_setup() { + # Calling depend.apache_pkg_setup fails because we do not have + # "apache2" in IUSE but the function expects this in order to call + # _init_apache2_late which sets the APACHE_MODULESDIR variable. + _init_apache2 + _init_apache2_late +} + +src_prepare() { + default + + # Don't add '-Wl,' as prefix for CFLAGS, as linker will fail + sed -e '/JK_PREFIX_IF_MISSING/d' -i configure.ac || die + eautoreconf + + # Adjust confpath and logpath for Gentoo + local logs_path="/var/log/apache2" + sed -e "s|conf|${APACHE_CONFDIR}|g" -e "s|logs|${logs_path}|g" -i ../conf/httpd-jk.conf || die +} + +src_configure() { + local myeconfargs=( + --disable-static + --with-apxs="${APXS}" + ) + + econf "${myeconfargs[@]}" +} + +src_compile() { + LIBTOOL="/bin/sh $(pwd)/libtool --silent" + default +} + +src_install() { + apache-module_src_install + + insinto "${APACHE_CONFDIR}" + doins "${S}"/../conf/*.properties + + insinto "${APACHE_MODULES_CONFDIR}" + newins ../conf/httpd-jk.conf 88_mod_jk.conf + + einstalldocs +} diff --git a/www-apache/mod_jk/mod_jk-1.2.49.ebuild b/www-apache/mod_jk/mod_jk-1.2.49.ebuild deleted file mode 100644 index f11868d35b60..000000000000 --- a/www-apache/mod_jk/mod_jk-1.2.49.ebuild +++ /dev/null @@ -1,79 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -MY_P="tomcat-connectors-${PV#-*}-src" - -inherit apache-module autotools verify-sig - -DESCRIPTION="Provides an AJP Apache2-JK-connector for the Tomcat servlet engine" -HOMEPAGE="https://tomcat.apache.org/connectors-doc/" -SRC_URI="mirror://apache/tomcat/tomcat-connectors/jk/${MY_P}.tar.gz - verify-sig? ( https://downloads.apache.org/tomcat/tomcat-connectors/jk/tomcat-connectors-${PV}-src.tar.gz.asc )" -S="${WORKDIR}/${MY_P}/native" - -LICENSE="Apache-2.0" -SLOT="0" -KEYWORDS="amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc x86" - -DEPEND="dev-libs/apr:1=" -RDEPEND="${DEPEND}" -BDEPEND=" - dev-lang/perl - verify-sig? ( sec-keys/openpgp-keys-apache-tomcat-connectors ) -" - -PATCHES=( "${FILESDIR}/${PN}-1.2.49-musl.patch" ) - -APACHE2_MOD_FILE="${S}/apache-2.0/${PN}.so" -APACHE2_MOD_DEFINE="JK" -VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/openpgp-keys/tomcat-connectors.apache.org.asc" - -need_apache2 - -pkg_setup() { - # Calling depend.apache_pkg_setup fails because we do not have - # "apache2" in IUSE but the function expects this in order to call - # _init_apache2_late which sets the APACHE_MODULESDIR variable. - _init_apache2 - _init_apache2_late -} - -src_prepare() { - default - - # Don't add '-Wl,' as prefix for CFLAGS, as linker will fail - sed -e '/JK_PREFIX_IF_MISSING/d' -i configure.ac || die - eautoreconf - - # Adjust confpath and logpath for Gentoo - local logs_path="/var/log/apache2" - sed -e "s|conf|${APACHE_CONFDIR}|g" -e "s|logs|${logs_path}|g" -i ../conf/httpd-jk.conf || die -} - -src_configure() { - local myeconfargs=( - --disable-static - --with-apxs="${APXS}" - ) - - econf "${myeconfargs[@]}" -} - -src_compile() { - LIBTOOL="/bin/sh $(pwd)/libtool --silent" - default -} - -src_install() { - apache-module_src_install - - insinto "${APACHE_CONFDIR}" - doins "${S}"/../conf/*.properties - - insinto "${APACHE_MODULES_CONFDIR}" - newins ../conf/httpd-jk.conf 88_mod_jk.conf - - einstalldocs -} -- cgit v1.2.3-65-gdbad