git: e2a6ef9db93f - 2023Q1 - cad/verilator: Fix wrong PYTHON3 path in installed makefile

From: Yuri Victorovich <yuri_at_FreeBSD.org>
Date: Tue, 21 Feb 2023 17:33:38 UTC
The branch 2023Q1 has been updated by yuri:

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

commit e2a6ef9db93f0be02fad90d43550a608ccd07795
Author:     Yuri Victorovich <yuri@FreeBSD.org>
AuthorDate: 2023-02-21 16:09:51 +0000
Commit:     Yuri Victorovich <yuri@FreeBSD.org>
CommitDate: 2023-02-21 17:33:32 +0000

    cad/verilator: Fix wrong PYTHON3 path in installed makefile
    
    PR:             269737
    Reported by:    Joel Bodenmann <jbo@insane.engineer>
    
    (cherry picked from commit ce5ece11624823e643d415eabd3f7c1bc7995e5a)
---
 cad/verilator/Makefile | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/cad/verilator/Makefile b/cad/verilator/Makefile
index 99f30d42f600..d00ef47395dc 100644
--- a/cad/verilator/Makefile
+++ b/cad/verilator/Makefile
@@ -1,6 +1,7 @@
 PORTNAME=	verilator
 DISTVERSIONPREFIX=	v
 DISTVERSION=	5.006
+PORTREVISION=	1
 CATEGORIES=	cad
 
 MAINTAINER=	yuri@FreeBSD.org
@@ -48,8 +49,10 @@ LEAK_CHECKS_CXXFLAGS=		-DVL_LEAK_CHECKS
 LEAK_CHECKS_BROKEN=		compilation will be fixed in the next release
 
 post-patch:
-	${REINPLACE_CMD} -e 's|@pkgconfigdir@|${PREFIX}/libdata/pkgconfig|' \
-	    ${WRKSRC}/Makefile.in
+	@${REINPLACE_CMD} -e 's|AC_PATH_PROG(PYTHON3,python3)|AC_PATH_PROG(PYTHON3,${PYTHON_VERSION})|' \
+		${WRKSRC}/configure.ac # hack-workaround for https://github.com/verilator/verilator/issues/3970
+	@${REINPLACE_CMD} -e 's|@pkgconfigdir@|${PREFIX}/libdata/pkgconfig|' \
+		${WRKSRC}/Makefile.in
 
 pre-configure:
 	cd ${WRKSRC} && \