git: 295a84d82e21 - main - emulators/citra: Fix build with llvm16

From: Muhammad Moinur Rahman <bofh_at_FreeBSD.org>
Date: Sun, 06 Aug 2023 20:30:32 UTC
The branch main has been updated by bofh:

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

commit 295a84d82e2170abb4fc04a3faff427a8621ae9a
Author:     Muhammad Moinur Rahman <bofh@FreeBSD.org>
AuthorDate: 2023-08-06 19:46:26 +0000
Commit:     Muhammad Moinur Rahman <bofh@FreeBSD.org>
CommitDate: 2023-08-06 20:30:19 +0000

    emulators/citra: Fix build with llvm16
    
    Approved by:    portmgr (blanket)
    Sponsored by:   The FreeBSD Foundation
---
 emulators/citra/Makefile | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/emulators/citra/Makefile b/emulators/citra/Makefile
index 5731ac4e5588..e5d902cdfbd3 100644
--- a/emulators/citra/Makefile
+++ b/emulators/citra/Makefile
@@ -92,15 +92,21 @@ QT5_PLIST_FILES=bin/${PORTNAME}-qt \
 		share/man/man6/${PORTNAME}-qt.6.gz \
 		share/mime/packages/${PORTNAME}.xml
 
+.include <bsd.port.pre.mk>
+
 post-patch:
 	@${REINPLACE_CMD} -e '/check_submodules_present()/d' \
 		${WRKSRC}/CMakeLists.txt
 	@${REINPLACE_CMD} -e 's/@GIT_BRANCH@/master/' \
 		-e 's/@GIT_DESC@/${GH_TAGNAME}/' \
 		${WRKSRC}/src/common/scm_rev.cpp.in
+.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 160
+	@${REINPLACE_CMD} -e 's|std::unary_function|std::__unary_function|' \
+		${WRKSRC}/externals/boost/boost/container_hash/hash.hpp
+.endif
 
 post-configure:
 	@${CP} ${DISTFILES:M*\:gamedb:C/\:.*//:S,^,${_DISTDIR},} \
 		${BUILD_WRKSRC}/dist/compatibility_list/
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>