commit:     1656166d46043268667a74535bfa6530d2e2bf6c
Author:     Zurab Kvachadze <zurabid2016 <AT> gmail <DOT> com>
AuthorDate: Fri Oct 24 23:22:10 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Oct 31 15:00:15 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1656166d

www-nginx/ngx-naxsi: Bump 1.7 -> 1.7-r1, link libinjection correctly

Adds a patch that correctly sets the linking flags.

Additionally, this revbump also installs documentation Markdown pages.
The Markdown pages are not compressed because they form one interlinked
document, which will most likely be read in a browser/other Markdown
renderer that probably does not support compressed Markdown.

Closes: https://bugs.gentoo.org/964736
Signed-off-by: Zurab Kvachadze <zurabid2016 <AT> gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/44322
Closes: https://github.com/gentoo/gentoo/pull/44322
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/ngx-naxsi-1.7-use-ngx_module_libs.patch  | 30 ++++++++++++++++++++++
 ...gx-naxsi-1.7.ebuild => ngx-naxsi-1.7-r1.ebuild} |  6 +++++
 2 files changed, 36 insertions(+)

diff --git a/www-nginx/ngx-naxsi/files/ngx-naxsi-1.7-use-ngx_module_libs.patch 
b/www-nginx/ngx-naxsi/files/ngx-naxsi-1.7-use-ngx_module_libs.patch
new file mode 100644
index 000000000000..6a655c037a70
--- /dev/null
+++ b/www-nginx/ngx-naxsi/files/ngx-naxsi-1.7-use-ngx_module_libs.patch
@@ -0,0 +1,30 @@
+From dab752e2d55b35c73617acc9179d2164ccf95541 Mon Sep 17 00:00:00 2001
+From: Zurab Kvachadze <[email protected]>
+Date: Sat, 25 Oct 2025 00:27:17 +0200
+Subject: [PATCH] naxsi_src/config: Set the correct variable to link to system
+ libinjection
+
+ngx_module_libs should be used for specifying external libraries to link
+with.
+
+Signed-off-by: Zurab Kvachadze <[email protected]>
+---
+ naxsi_src/config | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/naxsi_src/config b/naxsi_src/config
+index 0b8d438..cd27c20 100644
+--- a/config
++++ b/config
+@@ -49,7 +49,7 @@ if [ "$LIBINJECTION_FOUND" != "0" ]; then
+ else
+     echo "Using system libinjection"
+     CFLAGS="$CFLAGS $LIBINJECTION_CFLAGS"
+-    ngx_feature_libs="$LIBINJECTION_LIBS"
++    ngx_module_libs="$LIBINJECTION_LIBS"
+ fi
+ 
+ # NGINX module condfiguration.
+-- 
+2.49.1
+

diff --git a/www-nginx/ngx-naxsi/ngx-naxsi-1.7.ebuild 
b/www-nginx/ngx-naxsi/ngx-naxsi-1.7-r1.ebuild
similarity index 84%
rename from www-nginx/ngx-naxsi/ngx-naxsi-1.7.ebuild
rename to www-nginx/ngx-naxsi/ngx-naxsi-1.7-r1.ebuild
index ed04df91b186..9fd5a8493ceb 100644
--- a/www-nginx/ngx-naxsi/ngx-naxsi-1.7.ebuild
+++ b/www-nginx/ngx-naxsi/ngx-naxsi-1.7-r1.ebuild
@@ -24,8 +24,14 @@ KEYWORDS="~amd64"
 DEPEND="dev-libs/libinjection:="
 RDEPEND="${DEPEND}"
 
+PATCHES=(
+       "${FILESDIR}/${PN}-1.7-use-ngx_module_libs.patch"
+)
+
 src_install() {
        nginx-module_src_install
        insinto /etc/nginx/naxsi
        doins -r "${NGINX_MOD_S}"/../naxsi_rules/*
+       docompress -x "/usr/share/doc/${PF}"
+       dodoc -r "${NGINX_MOD_S}"/../docs/*
 }

Reply via email to