From 7bfae932f73e6929fd4fc0afd04e81199c58df00 Mon Sep 17 00:00:00 2001 From: Mark Linimon Date: Fri, 12 Jul 2019 02:25:07 +0000 Subject: Prepare for powerpc-on-clang by deleting hard-coded tests for libstdc++.so as a stand-in for "are we running on gcc". For people already testing powerpc on clang, it is possible that they already have both compilers in base. Thus, the assumption that "gcc is in base" (e.g. libstdc++.so exists) always means "force use of GCC" is already broken. It will be for everyone on -CURRENT once the switch is made. While here, standardize on compiler:c++11-lang instead of -lib (they are equivalent these days), pet portlint, and do some other cleanup. Approved by: portmgr (tier-2 blanket) --- security/clamav/Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'security/clamav') diff --git a/security/clamav/Makefile b/security/clamav/Makefile index f4282d01975b..dfa58f8d7000 100644 --- a/security/clamav/Makefile +++ b/security/clamav/Makefile @@ -15,7 +15,7 @@ LICENSE_FILE= ${WRKSRC}/COPYING LIB_DEPENDS= libltdl.so:devel/libltdl \ libcurl.so:ftp/curl -USES= cpe gmake gnome libtool ncurses pathfix pkgconfig ssl +USES= compiler cpe gmake gnome libtool ncurses pathfix pkgconfig ssl USE_RC_SUBR= clamav-clamd clamav-freshclam USE_LDCONFIG= yes @@ -144,6 +144,8 @@ SED_CONF= -E -e 's|^\#?(Example)$$|\#\1|' \ -e 's|^\#?(MilterSocket) */tmp.*$$|\1 ${CLAMAV_MILTER_SOCKET}|' \ -e 's|^\#?(ClamdSocket).*$$|\1 unix:${CLAMAV_CLAMD_SOCKET}|' +.include + post-patch: @${REINPLACE_CMD} -e 's|%%PTHREAD_LIBS%%|-lthr|g' \ -e 's|LC_REVISION=22|LC_REVISION=24|' \ @@ -152,7 +154,7 @@ post-patch: ${WRKSRC}/etc/clamd.conf.sample \ ${WRKSRC}/etc/freshclam.conf.sample \ ${WRKSRC}/etc/clamav-milter.conf.sample -.if exists(/usr/lib/libstdc++.so) +.if ${CHOSEN_COMPILER_TYPE} == gcc @${REINPLACE_CMD} -e 's|-Wno-logical-op-parentheses||' \ -e 's|-Wno-dangling-else||' \ ${WRKSRC}/libclamav/Makefile.am \ @@ -184,4 +186,4 @@ post-install: ${STAGEDIR}${RUNDIR} (cd ${WRKSRC}/docs/html; ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR}/html) -.include +.include -- cgit v1.2.3