git: 66b818ff501f - main - www/squid: Fix build with MIT KRB5 in 15-PRERELEASE

From: Cy Schubert <cy_at_FreeBSD.org>
Date: Sun, 10 Aug 2025 04:36:43 UTC
The branch main has been updated by cy:

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

commit 66b818ff501ff4872ac5688f291a091569ed38e5
Author:     Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2025-08-10 04:28:28 +0000
Commit:     Cy Schubert <cy@FreeBSD.org>
CommitDate: 2025-08-10 04:36:25 +0000

    www/squid: Fix build with MIT KRB5 in 15-PRERELEASE
    
    15-CURRENT has replaced Heimdal 1.5.2 with MIT KRB5 1.21 (soon to be
    1.22). Detect MIT KRB5 and adjust accordingly.
---
 www/squid/Makefile | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/www/squid/Makefile b/www/squid/Makefile
index 788c344ee596..5e4b45f12be3 100644
--- a/www/squid/Makefile
+++ b/www/squid/Makefile
@@ -1,5 +1,6 @@
 PORTNAME=	squid
 DISTVERSION=	6.14
+PORTREVISION=	1
 CATEGORIES=	www
 MASTER_SITES=	https://github.com/${PORTNAME}-cache/${PORTNAME}/releases/download/${PORTNAME:tu}_${DISTVERSION:S|.|_|g}/
 
@@ -149,8 +150,12 @@ FS_DISKD_VARS=			DISKIO_MODULES+=DiskDaemon \
 FS_ROCK_VARS=			STORAGE_SCHEMES+=rock
 GSSAPI_BASE_USES=		gssapi
 GSSAPI_BASE_CONFIGURE_ON=	${GSSAPI_CONFIGURE_ARGS} \
-				--with-heimdal-krb5=${GSSAPIBASEDIR} \
 				krb5_config=${GSSAPIBASEDIR}/bin/krb5-config
+.if exits(/usr/libexec/krb5kdc)
+GSSAPI_BASE_CONFIGURE_ON+=	--with-mit-krb5=${GSSAPIBASEDIR}
+.else
+GSSAPI_BASE_CONFIGURE_ON+=	--with-heimdal-krb5=${GSSAPIBASEDIR}
+.endif
 GSSAPI_BASE_PLIST_SUB=		AUTH_KERB=""
 GSSAPI_HEIMDAL_USES=		gssapi:heimdal
 GSSAPI_HEIMDAL_CONFIGURE_ON=	${GSSAPI_CONFIGURE_ARGS} \