git: ea5eba5c4dac - main - shells/zsh: cache the utx.active location

From: Baptiste Daroussin <bapt_at_FreeBSD.org>
Date: Thu, 06 Apr 2023 13:10:52 UTC
The branch main has been updated by bapt:

URL: https://cgit.FreeBSD.org/ports/commit/?id=ea5eba5c4dace0b04f8f6bb3d1bc697f03bacc79

commit ea5eba5c4dace0b04f8f6bb3d1bc697f03bacc79
Author:     Baptiste Daroussin <bapt@FreeBSD.org>
AuthorDate: 2023-04-06 13:07:15 +0000
Commit:     Baptiste Daroussin <bapt@FreeBSD.org>
CommitDate: 2023-04-06 13:10:43 +0000

    shells/zsh: cache the utx.active location
    
    On fresh jails or chroot the /var/run/utx.active might not exist (like
    in poudriere for example) but configure script is looking for its
    existance to determine its existance and activate the build of the
    utmx logging feature internally.
    
    Caching it makes the configure script always build the logging features.
    
    While here, make ZSH_VER use the distversion, which fixes the usecase of
    building snapshots of zsh via the port.
    
    PR:     268714
    Reported by:    okiddle@yahoo.co.uk
---
 shells/zsh/Makefile | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/shells/zsh/Makefile b/shells/zsh/Makefile
index c5c96d432069..57c3ba91ad30 100644
--- a/shells/zsh/Makefile
+++ b/shells/zsh/Makefile
@@ -1,6 +1,6 @@
 PORTNAME=	zsh
 DISTVERSION=	5.9
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	shells
 MASTER_SITES=	https://www.zsh.org/pub/ \
 		SF \
@@ -39,7 +39,8 @@ CONFIGURE_ARGS+=--disable-site-fndir \
 		--enable-additional-fpath=${DATADIR}/site-functions
 
 CONFIGURE_ENV+=	zsh_cv_sys_path_dev_fd=no \
-		ac_cv_header_sys_capability_h=no
+		ac_cv_header_sys_capability_h=no \
+		zsh_cv_path_utmpx=/var/run/utx.active
 
 GNU_CONFIGURE=	yes
 CPPFLAGS+=	-DBOOL_DEFINED
@@ -76,7 +77,7 @@ DOCS_DISTFILES=	${DISTNAME}-doc${EXTRACT_SUFX}:doc
 PORTDOCS=	*
 PORTEXAMPLES=	zlogin zshenv zshrc
 
-ZSH_VER=	${PORTVERSION}
+ZSH_VER=	${DISTVERSION}
 PLIST_SUB+=	ZSH_VER="${ZSH_VER}"
 SUB_FILES=	pkg-message