diff --git a/www/nginx-acme/Makefile b/www/nginx-acme/Makefile index a85fc8cdc07a..c48493a86ee8 100644 --- a/www/nginx-acme/Makefile +++ b/www/nginx-acme/Makefile @@ -1,76 +1,77 @@ PORTNAME= acme PORTVERSION= 0.1.1 PORTREVISION= 6 CATEGORIES= www MASTER_SITES= https://github.com/nginx/nginx-${PORTNAME}/releases/download/v${PORTVERSION}/:acme \ https://nginx.org/download/:nginx DISTFILES= nginx-${PORTNAME}-${DISTVERSION}.tar.gz:acme \ nginx-${NGINX_VERSION_DEFAULT}.tar.gz:nginx \ nginx-${NGINX_VERSION_DEVEL}.tar.gz:nginx MAINTAINER= joneum@FreeBSD.org COMMENT= ACME module for NGINX WWW= https://github.com/nginx/nginx-acme LICENSE= APACHE20 LICENSE_FILE= ${WRKSRC}/LICENSE LIB_DEPENDS+= libpcre2-8.so:devel/pcre2 FLAVORS= default devel FLAVOR?= default USES= cargo cpe llvm:lib,noexport ssl default_PKGNAMEPREFIX= nginx- devel_PKGNAMEPREFIX= nginx-devel- PKGNAMEPREFIX= ${${FLAVOR}_PKGNAMEPREFIX} WRKSRC= ${WRKDIR}/nginx-${PORTNAME}-${PORTVERSION} default_CONFLICTS_INSTALL= nginx-devel-${PORTNAME} devel_CONFLICTS_INSTALL= nginx-${PORTNAME} CONFLICTS_INSTALL= ${${FLAVOR}_CONFLICTS_INSTALL} .include "${.CURDIR}/../nginx/version.mk" NGINX_VERSION_DEFAULT:= ${NGINX_VERSION} .undef NGINX_VERSION .include "${.CURDIR}/../nginx-devel/version.mk" NGINX_VERSION_DEVEL:= ${NGINX_VERSION} .if ${FLAVOR} == devel RUN_DEPENDS= ${LOCALBASE}/sbin/nginx:www/nginx-devel .else RUN_DEPENDS= ${LOCALBASE}/sbin/nginx:www/nginx .endif .if ${FLAVOR} == devel NGINX_VERSION= ${NGINX_VERSION_DEVEL} +EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src_conf_order.rs-devel .else NGINX_VERSION= ${NGINX_VERSION_DEFAULT} .endif CPE_VENDOR= f5 CPE_PRODUCT= nginx-acme CARGO_ENV+= NGINX_BUILD_DIR=${WRKDIR}/nginx-${NGINX_VERSION}/objs NGX_CONFIGURE_ARGS= --with-compat \ --with-cc-opt="-I ${LOCALBASE}/include" \ --with-ld-opt="-L ${LOCALBASE}/lib" \ --with-http_ssl_module .include "${.CURDIR}/Makefile.cargo" PLIST_FILES= libexec/nginx/ngx_http_acme_module.so pre-configure: ( cd ${WRKDIR}/nginx-${NGINX_VERSION} && \ ${SETENV} ${CONFIGURE_ENV} ${CONFIGURE_CMD} ${NGX_CONFIGURE_ARGS} ) do-install: ${MKDIR} ${STAGEDIR}${PREFIX}/libexec/nginx/ ${INSTALL_DATA} ${WRKDIR}/target/release/libnginx_acme.so \ ${STAGEDIR}${PREFIX}/libexec/nginx/ngx_http_acme_module.so .include diff --git a/www/nginx-acme/files/extra-patch-src_conf_order.rs-devel b/www/nginx-acme/files/extra-patch-src_conf_order.rs-devel new file mode 100644 index 000000000000..9284fb470a46 --- /dev/null +++ b/www/nginx-acme/files/extra-patch-src_conf_order.rs-devel @@ -0,0 +1,11 @@ +--- src/conf/order.rs.orig 2026-01-06 14:12:56.622627000 +0100 ++++ src/conf/order.rs 2026-01-06 14:14:51.810902000 +0100 +@@ -249,7 +249,7 @@ fn validate_host(pool: &Pool, mut host: ngx_str_t) -> + + fn validate_host(pool: &Pool, mut host: ngx_str_t) -> Result { + let mut pool = pool.clone(); +- let rc = Status(unsafe { nginx_sys::ngx_http_validate_host(&mut host, pool.as_mut(), 1) }); ++ let rc = Status(unsafe { nginx_sys::ngx_http_validate_host(&mut host, std::ptr::null_mut(), pool.as_mut(), 1) }); + if rc != Status::NGX_OK { + return Err(rc); + }