pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/www/nginx



Module Name:    pkgsrc
Committed By:   osa
Date:           Wed Sep 10 10:57:32 UTC 2025

Modified Files:
        pkgsrc/www/nginx: Makefile PLIST distinfo options.mk
Added Files:
        pkgsrc/www/nginx/patches: extra-patch-ngx_brotli_filter_config

Log Message:
www/nginx-devel: add third-party brotli module

Merge recent changes from www/nginx-devel.

Bump PKGREVISION.


To generate a diff of this commit:
cvs rdiff -u -r1.181 -r1.182 pkgsrc/www/nginx/Makefile
cvs rdiff -u -r1.20 -r1.21 pkgsrc/www/nginx/PLIST
cvs rdiff -u -r1.136 -r1.137 pkgsrc/www/nginx/distinfo
cvs rdiff -u -r1.120 -r1.121 pkgsrc/www/nginx/options.mk
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/www/nginx/patches/extra-patch-ngx_brotli_filter_config

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/www/nginx/Makefile
diff -u pkgsrc/www/nginx/Makefile:1.181 pkgsrc/www/nginx/Makefile:1.182
--- pkgsrc/www/nginx/Makefile:1.181     Sat Aug 30 22:46:31 2025
+++ pkgsrc/www/nginx/Makefile   Wed Sep 10 10:57:32 2025
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.181 2025/08/30 22:46:31 wiz Exp $
+# $NetBSD: Makefile,v 1.182 2025/09/10 10:57:32 osa Exp $
 
 DISTNAME=      nginx-1.28.0
-PKGREVISION=   6
+PKGREVISION=   7
 CATEGORIES=    www
 MASTER_SITES=  https://nginx.org/download/
 DISTFILES=     ${DEFAULT_DISTFILES}
@@ -107,6 +107,9 @@ SOEXT=              so
 PLIST_SUBST+=  SOEXT=${SOEXT}
 
 post-patch:
+.if !empty(PKG_OPTIONS:Mnginx-brotli)
+       cd ${WRKSRC} && ${PATCH} < ${PATCHDIR}/extra-patch-ngx_brotli_filter_config
+.endif
 .if !empty(PKG_OPTIONS:Mnginx-gssapi)
        ${SED} -i.bak '4d;5d;6d' ${WRKDIR}/${GSSAPI_DISTNAME}/config
 .endif

Index: pkgsrc/www/nginx/PLIST
diff -u pkgsrc/www/nginx/PLIST:1.20 pkgsrc/www/nginx/PLIST:1.21
--- pkgsrc/www/nginx/PLIST:1.20 Wed Nov 13 11:03:07 2024
+++ pkgsrc/www/nginx/PLIST      Wed Sep 10 10:57:32 2025
@@ -1,6 +1,8 @@
-@comment $NetBSD: PLIST,v 1.20 2024/11/13 11:03:07 wiz Exp $
+@comment $NetBSD: PLIST,v 1.21 2025/09/10 10:57:32 osa Exp $
 ${PLIST.dso}${PLIST.ndk}libexec/nginx/ndk_http_module.so
 ${PLIST.dso}${PLIST.arrayvar}libexec/nginx/ngx_http_array_var_module.so
+${PLIST.dso}${PLIST.brotli}libexec/nginx/ngx_http_brotli_filter_module.so
+${PLIST.dso}${PLIST.brotli}libexec/nginx/ngx_http_brotli_static_module.so
 ${PLIST.dso}${PLIST.gssapi}libexec/nginx/ngx_http_auth_spnego_module.so
 ${PLIST.dso}${PLIST.cprg}libexec/nginx/ngx_http_cache_purge_module.so
 ${PLIST.dso}${PLIST.dav}libexec/nginx/ngx_http_dav_ext_module.so

Index: pkgsrc/www/nginx/distinfo
diff -u pkgsrc/www/nginx/distinfo:1.136 pkgsrc/www/nginx/distinfo:1.137
--- pkgsrc/www/nginx/distinfo:1.136     Sat Aug 16 15:52:43 2025
+++ pkgsrc/www/nginx/distinfo   Wed Sep 10 10:57:32 2025
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.136 2025/08/16 15:52:43 osa Exp $
+$NetBSD: distinfo,v 1.137 2025/09/10 10:57:32 osa Exp $
 
 BLAKE2s (1ac658f44afc9240f13e9d6c1c9d5a7816299e8e.patch) = 6c3880dc781886fb1f4190fa9b8f1459246cc5d157aaed3b9a24cc7abaf7c5a1
 SHA512 (1ac658f44afc9240f13e9d6c1c9d5a7816299e8e.patch) = b780bea19736f5db844f11b0b407c159cc6ba7326b50177cefde6f8ee875238d3618e50d29b132a66fe98103cb5656f33895e5989d98d4cdc26cfeaa7f12865f
@@ -15,6 +15,9 @@ Size (encrypted-session-nginx-module-0.0
 BLAKE2s (form-input-nginx-module-0.12.tar.gz) = b08fc95c3e15bfdc0846e2d1e8157171954f353bd301f4ac4aca56113620e91d
 SHA512 (form-input-nginx-module-0.12.tar.gz) = 1c5c5ab74156cac09da44a2dcdd84f7c03c9919a23a847e63613e00e3781ecd73d5ad12446174b4fdef9d064257a31570a8dbcccc00d8266f7048e3dcde0362e
 Size (form-input-nginx-module-0.12.tar.gz) = 11090 bytes
+BLAKE2s (google-ngx_brotli-a71f931_GH.tar.gz) = c30d6cbd94abb6f5c1d48275ed964e32f43d9cadd602f95b227a40e62dadbd0d
+SHA512 (google-ngx_brotli-a71f931_GH.tar.gz) = 1cb73a89b53b29d37cbc4d811d5d5cd7b051ec4db98900f593abc8d5b53761b95713212e083334785d9625d4705a78ed476113b244476a9cd5f46dcd9f1177ff
+Size (google-ngx_brotli-a71f931_GH.tar.gz) = 16376 bytes
 BLAKE2s (headers-more-nginx-module-0.38.tar.gz) = cef0db963a951c8e33f2fadadcd262552a266f876d1f2585703392da292933df
 SHA512 (headers-more-nginx-module-0.38.tar.gz) = 90948a79b88bbe2004dc1a53a5189474405787d518ba4e0ee802992b29372f3d08a3a1cf3dc0d5a2089de38b3a99e6133a4d6ac2feaf018f7b23600d7ef23948
 Size (headers-more-nginx-module-0.38.tar.gz) = 29472 bytes

Index: pkgsrc/www/nginx/options.mk
diff -u pkgsrc/www/nginx/options.mk:1.120 pkgsrc/www/nginx/options.mk:1.121
--- pkgsrc/www/nginx/options.mk:1.120   Sun Aug 31 11:15:46 2025
+++ pkgsrc/www/nginx/options.mk Wed Sep 10 10:57:32 2025
@@ -1,9 +1,9 @@
-# $NetBSD: options.mk,v 1.120 2025/08/31 11:15:46 wiz Exp $
+# $NetBSD: options.mk,v 1.121 2025/09/10 10:57:32 osa Exp $
 
 CODELOAD_SITE_GITHUB=          https://codeload.github.com/
 
 PKG_OPTIONS_VAR=       PKG_OPTIONS.nginx
-PKG_SUPPORTED_OPTIONS= nginx-array-var nginx-auth-request nginx-cache-purge nginx-dav nginx-debug
+PKG_SUPPORTED_OPTIONS= nginx-array-var nginx-auth-request nginx-brotli nginx-cache-purge nginx-dav nginx-debug
 PKG_SUPPORTED_OPTIONS+=        nginx-dso nginx-echo nginx-encrypted-session nginx-flv nginx-form-input
 PKG_SUPPORTED_OPTIONS+=        nginx-geoip nginx-geoip2 nginx-gssapi nginx-gtools nginx-gzip nginx-headers-more nginx-http2
 PKG_SUPPORTED_OPTIONS+=        nginx-http3 nginx-image-filter nginx-luajit nginx-mail-proxy nginx-memcache
@@ -11,10 +11,10 @@ PKG_SUPPORTED_OPTIONS+=     nginx-naxsi ngin
 PKG_SUPPORTED_OPTIONS+=        nginx-secure-link nginx-set-misc nginx-slice nginx-ssl nginx-status
 PKG_SUPPORTED_OPTIONS+=        nginx-stream-ssl-preread nginx-sts nginx-sub nginx-upload nginx-uwsgi nginx-vts
 
-PKG_SUGGESTED_OPTIONS= nginx-auth-request nginx-gzip nginx-http2 nginx-http3 nginx-memcache nginx-realip
-PKG_SUGGESTED_OPTIONS+=        nginx-slice nginx-status nginx-ssl nginx-uwsgi
+PKG_SUGGESTED_OPTIONS= nginx-auth-request nginx-brotli nginx-gzip nginx-http2 nginx-http3 nginx-memcache
+PKG_SUGGESTED_OPTIONS+=        nginx-realip nginx-slice nginx-status nginx-ssl nginx-uwsgi
 
-PLIST_VARS+=           arrayvar cprg dav dso echo encses forminput geoip2
+PLIST_VARS+=           arrayvar brotli cprg dav dso echo encses forminput geoip2
 PLIST_VARS+=           gssapi headmore imagefilter lua mail naxsi nchan ndk njs
 PLIST_VARS+=           perl redis rtmp setmisc stream sts upload uwsgi vts
 
@@ -98,6 +98,24 @@ SUBST_SED.fix-ssl=   -e 's,/usr/pkg,${BUIL
 SUBST_NOOP_OK.fix-ssl= yes
 .endif
 
+.if !empty(PKG_OPTIONS:Mnginx-brotli) || make(makesum) || make(mdi) || make(distclean)
+.include "../../archivers/brotli/buildlink3.mk"
+BROTLI_GH_ACCOUNT=             google
+BROTLI_GH_PROJECT=             ngx_brotli
+BROTLI_VERSION=                        a71f931
+BROTLI_DISTNAME=               ${BROTLI_GH_PROJECT}-${BROTLI_VERSION}
+BROTLI_DISTFILE=               ${BROTLI_GH_ACCOUNT}-${BROTLI_DISTNAME}_GH.tar.gz
+SITES.${BROTLI_DISTFILE}=      -${CODELOAD_SITE_GITHUB:=${BROTLI_GH_ACCOUNT}/${BROTLI_GH_PROJECT}/tar.gz/${BROTLI_VERSION}?dummy=${BROTLI_DISTFILE}}
+DISTFILES+=                    ${BROTLI_DISTFILE}
+DSO_EXTMODS+=                  brotli
+SUBST_CLASSES+=                        fix-brotli
+SUBST_STAGE.fix-brotli=                pre-configure
+SUBST_FILES.fix-brotli=                ../${BROTLI_DISTNAME}/filter/config
+SUBST_SED.fix-brotli=          -e 's,%%PREFIX%%,${BUILDLINK_PREFIX.brotli},g'
+SUBST_NOOP_OK.fix-brotli=      yes
+PLIST.brotli=                  yes
+.endif
+
 .if !empty(PKG_OPTIONS:Mnginx-dav) || make(makesum) || make(mdi) || make(distclean)
 DAV_VERSION=           3.0.0
 DAV_DISTNAME=          nginx-dav-ext-module-3.0.0

Added files:

Index: pkgsrc/www/nginx/patches/extra-patch-ngx_brotli_filter_config
diff -u /dev/null pkgsrc/www/nginx/patches/extra-patch-ngx_brotli_filter_config:1.1
--- /dev/null   Wed Sep 10 10:57:32 2025
+++ pkgsrc/www/nginx/patches/extra-patch-ngx_brotli_filter_config       Wed Sep 10 10:57:32 2025
@@ -0,0 +1,40 @@
+--- ../ngx_brotli-a71f931/filter/config.orig   2023-10-09 02:44:27.000000000 -0400
++++ ../ngx_brotli-a71f931/filter/config        2025-09-08 09:29:11.776714842 -0400
+@@ -42,33 +42,16 @@
+ ngx_module_type=HTTP_FILTER
+ ngx_module_name=ngx_http_brotli_filter_module
+ 
+-brotli="$ngx_addon_dir/deps/brotli/c"
+-if [ ! -f "$brotli/include/brotli/encode.h" ]; then
+-cat << END
+-
+-$0: error: \
+-Brotli library is missing from the $brotli directory.
+-
+-Please make sure that the git submodule has been checked out:
+-
+-    cd $ngx_addon_dir && git submodule update --init && cd $PWD
+-
+-END
+-    exit 1
+-fi
+-
+-BROTLI_OUTPUT_DIRECTORY="$brotli/../out"
+-BROTLI_ENC_H="$brotli/include/brotli/encode.h \
+-              $brotli/include/brotli/port.h \
+-              $brotli/include/brotli/types.h"
++BROTLI_ENC_H="%%PREFIX%%/include/brotli/encode.h \
++              %%PREFIX%%/include/brotli/port.h \
++              %%PREFIX%%/include/brotli/types.h"
+ 
+ 
+ ngx_module_incs="$brotli/include"
+ ngx_module_deps="$BROTLI_ENC_H"
+ ngx_module_srcs="$BROTLI_MODULE_SRC_DIR/ngx_http_brotli_filter_module.c"
+-ngx_module_libs="-L$BROTLI_OUTPUT_DIRECTORY -lbrotlienc -lbrotlicommon -lm"
++ngx_module_libs="-L%%PREFIX%%/lib -lbrotlienc -lbrotlicommon -lm"
+ ngx_module_order="$ngx_module_name \
+-                  ngx_pagespeed \
+                   ngx_http_postpone_filter_module \
+                   ngx_http_ssi_filter_module \
+                   ngx_http_charset_filter_module \



Home | Main Index | Thread Index | Old Index