Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 23 Jul 2023 15:53:12 GMT
From:      Muhammad Moinur Rahman <bofh@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: fc66d1726d5b - main - graphics/anttweakbar: Fix build with llvm16
Message-ID:  <202307231553.36NFrCW9008922@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by bofh:

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

commit fc66d1726d5bbcd802b4e41ed73d43f82608dcad
Author:     Muhammad Moinur Rahman <bofh@FreeBSD.org>
AuthorDate: 2023-07-23 12:25:45 +0000
Commit:     Muhammad Moinur Rahman <bofh@FreeBSD.org>
CommitDate: 2023-07-23 15:53:02 +0000

    graphics/anttweakbar: Fix build with llvm16
    
    - Pet portclippy
    
    Approved by:    portmgr (blanket)
    Sponsored by:   The FreeBSD Foundation
---
 graphics/anttweakbar/Makefile | 23 +++++++++++++++--------
 1 file changed, 15 insertions(+), 8 deletions(-)

diff --git a/graphics/anttweakbar/Makefile b/graphics/anttweakbar/Makefile
index 64630175e6cd..046e1d0b0028 100644
--- a/graphics/anttweakbar/Makefile
+++ b/graphics/anttweakbar/Makefile
@@ -12,26 +12,33 @@ WWW=		http://anttweakbar.sourceforge.net/doc/
 LICENSE=	ZLIB
 LICENSE_FILE=	${WRKSRC}/../License.txt
 
-USES=		dos2unix gl xorg zip
+USES=		dos2unix gl localbase:ldflags xorg zip
+DOS2UNIX_FILES=	Makefile LoadOGLCore.h TwPrecomp.h
 USE_GL=		gl glu
-USE_XORG=	x11
 USE_LDCONFIG=	yes
+USE_XORG=	x11
 
-WRKSRC=		${WRKDIR}/AntTweakBar
-WRKSRC_SUBDIR=	src
-
-DOS2UNIX_FILES=	Makefile LoadOGLCore.h TwPrecomp.h
-
-LDFLAGS+=	-L${LOCALBASE}/lib -lX11
+LDFLAGS+=	-lX11
 
 BINARY_ALIAS=	gcc=${CC}
 
+WRKSRC=		${WRKDIR}/AntTweakBar
+WRKSRC_SUBDIR=	src
+
 PLIST_FILES=	include/AntTweakBar.h \
 		lib/libAntTweakBar.a \
 		lib/libAntTweakBar.so \
 		lib/libAntTweakBar.so.${DISTVERSION:R} \
 		lib/libAntTweakBar.so.${DISTVERSION}
 
+.include <bsd.port.options.mk>
+
+post-patch:
+.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400091
+	@${REINPLACE_CMD} -e 's|public binary_function|public __binary_function|' \
+		${WRKSRC}/TwMgr.cpp
+.endif
+
 do-install:
 	${INSTALL_DATA} ${WRKSRC}/../include/AntTweakBar.h ${STAGEDIR}${PREFIX}/include
 	${INSTALL_DATA} ${WRKSRC}/../lib/libAntTweakBar.a ${STAGEDIR}${PREFIX}/lib



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202307231553.36NFrCW9008922>