Skip to content

Commit

Permalink
x11-toolkits/plib: Fix build with llvm16
Browse files Browse the repository at this point in the history
- Utilize USES=localbase
- Pet portclippy
- Adopt port

Sponsored by:	The FreeBSD Foundation
  • Loading branch information
5u623l20 committed Jun 24, 2023
1 parent abdfb41 commit 611b86a
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions x11-toolkits/plib/Makefile
Expand Up @@ -4,25 +4,31 @@ PORTREVISION= 8
CATEGORIES= x11-toolkits
MASTER_SITES= http://plib.sourceforge.net/dist/

MAINTAINER= ports@FreeBSD.org
MAINTAINER= bofh@FreeBSD.org
COMMENT= Portable library for joystick/sound/OpenGL GUI/3D math
WWW= http://plib.sourceforge.net/

LICENSE= LGPL20
LICENSE_FILE= ${WRKSRC}/COPYING

USES= cpe gl gmake xorg
USES= cpe gl gmake localbase:ldflags xorg
CPE_VENDOR= ${PORTNAME}_project
USE_XORG= xt xi xmu xext x11
USE_GL= glu
USE_XORG= xt xi xmu xext x11

GNU_CONFIGURE= yes

CXXFLAGS+= -fPIC
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -lpthread -L${LOCALBASE}/lib
LDFLAGS+= -lpthread

EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src-js-jsBSD.cxx

.include <bsd.port.options.mk>

.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400091
CPPFLAGS+= -Dregister=
.endif

post-patch:
@${REINPLACE_CMD} -e 's|-lpthread||g ; \
s|-ldl||g ; \
Expand Down

0 comments on commit 611b86a

Please sign in to comment.