From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Fri, 30 Aug 2024 15:28:08 +0200 Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1sk1fc-00Evra-1o for lore@lore.pengutronix.de; Fri, 30 Aug 2024 15:28:08 +0200 Received: from localhost ([127.0.0.1] helo=metis.whiteo.stw.pengutronix.de) by metis.whiteo.stw.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1sk1fc-0005gT-0J; Fri, 30 Aug 2024 15:28:08 +0200 Received: from smtp120.ord1d.emailsrvr.com ([184.106.54.120]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sk1fE-0005br-Gi for ptxdist@pengutronix.de; Fri, 30 Aug 2024 15:27:45 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mev.co.uk; s=20221208-6x11dpa4; t=1725024462; bh=u3+PJFbYOIH+PRKr39wiRHnD9XmwUPJmO+AoEuI+x6c=; h=From:To:Subject:Date:From; b=agBvN+7VLMke3ukUZVSyszXfXJp/KRAlbbd4k345VEeVDBiPBIlbpcUxogEnaeyIo m4mLi7+pX8mAr6KibsUYnSeIskEfuzmVd5nymOK5iOs/NvfJVJq7fMJMTOGRsM5vFC 7E8smSZSHJTl2zGCXlde3nhg7uGpgrm0MTQzwLQg= X-Auth-ID: abbotti@mev.co.uk Received: by smtp8.relay.ord1d.emailsrvr.com (Authenticated sender: abbotti-AT-mev.co.uk) with ESMTPSA id 20BB3C006D; Fri, 30 Aug 2024 09:27:42 -0400 (EDT) From: Ian Abbott To: ptxdist@pengutronix.de Date: Fri, 30 Aug 2024 14:27:22 +0100 Message-ID: <20240830132722.65713-1-abbotti@mev.co.uk> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Classification-ID: 24cb3764-45e0-41b6-8a12-2503c70f5929-1-1 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on metis.whiteo.stw.pengutronix.de X-Spam-Level: X-Spam-Status: No, score=-3.2 required=4.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Subject: [ptxdist] [PATCH] nginx: Allow ngx_http_charset_module to be built X-BeenThere: ptxdist@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Cc: Ian Abbott Sender: "ptxdist" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: ptxdist-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false Add a configuration option to build the http charset module. It allows a charset to be specified in the HTTP "Content-Type" header, for example for setting the charset to "utf-8". It can also do charset conversions with some limitations, but the nginx.make file has not been modified to install any of the supplied conversion tables. Signed-off-by: Ian Abbott --- rules/nginx.in | 8 ++++++++ rules/nginx.make | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/rules/nginx.in b/rules/nginx.in index ca043460c..6ee8a2ec1 100644 --- a/rules/nginx.in +++ b/rules/nginx.in @@ -41,6 +41,14 @@ config NGINX_HTTP_AUTOINDEX_MODULE ngx_http_autoindex_module processes requests ending with the slash character and produces a directory listing. +config NGINX_HTTP_CHARSET_MODULE + bool + prompt "ngx_http_charset_module" + help + ngx_http_charset_module adds a charset to the "Content-Type" + response header field. The module can convert data from one + charset to another with some limitations. + config NGINX_HTTP_FASTCGI_MODULE bool prompt "ngx_http_fastcgi_module" diff --git a/rules/nginx.make b/rules/nginx.make index 5b5669de0..85df855e1 100644 --- a/rules/nginx.make +++ b/rules/nginx.make @@ -68,7 +68,7 @@ NGINX_CONF_OPT := \ $(call ptx/ifdef, PTXCONF_NGINX_HTTP_V2_MODULE,--with-http_v2_module) \ --with-http_sub_module \ $(call ptx/ifdef, PTXCONF_NGINX_HTTP_GZIP_STATIC_MODULE,--with-http_gzip_static_module) \ - --without-http_charset_module \ + $(call ptx/ifdef, PTXCONF_NGINX_HTTP_CHARSET_MODULE,,--without-http_charset_module) \ $(call ptx/ifdef, PTXCONF_NGINX_HTTP_GZIP_MODULE,,--without-http_gzip_module) \ --without-http_ssi_module \ --without-http_userid_module \ -- 2.43.0