Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Nov 2020 23:40:06 +0000 (UTC)
From:      Yuri Victorovich <yuri@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r553877 - head/security/tor
Message-ID:  <202011012340.0A1Ne6Cs088821@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: yuri
Date: Sun Nov  1 23:40:06 2020
New Revision: 553877
URL: https://svnweb.freebsd.org/changeset/ports/553877

Log:
  security/tor: Fix build when both TCMALLOC=yes and STATIC_TOR=yes
  
  Also:
  * Remove unnecessary REINPLACE_CMD-patching commands
  * Simplify CONFLICTS_INSTALL

Modified:
  head/security/tor/Makefile

Modified: head/security/tor/Makefile
==============================================================================
--- head/security/tor/Makefile	Sun Nov  1 23:36:53 2020	(r553876)
+++ head/security/tor/Makefile	Sun Nov  1 23:40:06 2020	(r553877)
@@ -39,7 +39,7 @@ PLIST_SUB=	USER="${USERS}" GROUP="${GROUPS}"
 GROUPS=		_tor
 USERS=		_tor
 
-CONFLICTS_INSTALL=	tor-devel-[0-9]*
+CONFLICTS_INSTALL=	tor-devel
 
 STATIC_TOR_USES=	ssl:build
 STATIC_TOR_USES_OFF=	ssl
@@ -86,6 +86,7 @@ TOR_ZSTD_LIBS=		-lzstd
 CONFIGURE_ARGS+=	--with-malloc=tcmalloc
 .if ${PORT_OPTIONS:MSTATIC_TOR}
 BUILD_DEPENDS+=		${LOCALBASE}/lib/libtcmalloc.a:devel/google-perftools
+LDFLAGS+=		-lc++ -lm # required by libtcmalloc.a and isn't cocered by google-perftools' `pkg-config --libs libtcmalloc` output
 .else
 LIB_DEPENDS+=		libtcmalloc.so:devel/google-perftools
 .endif
@@ -98,14 +99,6 @@ post-patch:
 		${WRKSRC}/src/config/torrc.*.in \
 		${WRKSRC}/doc/tor.1.* \
 		${WRKSRC}/doc/tor.html.in
-
-post-patch-STATIC_TOR-off:
-	@${REINPLACE_CMD} -e "s@-ltcmalloc@${LOCALBASE}/lib/libtcmalloc.so@" \
-		${WRKSRC}/configure
-
-post-patch-STATIC_TOR-on:
-	@${REINPLACE_CMD} -e "s@-ltcmalloc@${LOCALBASE}/lib/libtcmalloc.a@" \
-		${WRKSRC}/configure
 
 post-install:
 	@${MKDIR} ${STAGEDIR}/var/log/tor ${STAGEDIR}/var/run/tor ${STAGEDIR}/var/db/tor



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