From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Feb 12 11:30:01 2014 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B28A5BE6 for ; Wed, 12 Feb 2014 11:30:01 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8C56F16FE for ; Wed, 12 Feb 2014 11:30:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id s1CBU1Nn081006 for ; Wed, 12 Feb 2014 11:30:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.8/8.14.8/Submit) id s1CBU1ME081004; Wed, 12 Feb 2014 11:30:01 GMT (envelope-from gnats) Resent-Date: Wed, 12 Feb 2014 11:30:01 GMT Resent-Message-Id: <201402121130.s1CBU1ME081004@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Renato Botelho Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 154C9A8F for ; Wed, 12 Feb 2014 11:27:04 +0000 (UTC) Received: from newred.freebsd.org (cgiserv.freebsd.org [IPv6:2001:1900:2254:206a::50:4]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id F2E4116D3 for ; Wed, 12 Feb 2014 11:27:03 +0000 (UTC) Received: from cgiserv.freebsd.org ([127.0.1.6]) by newred.freebsd.org (8.14.7/8.14.7) with ESMTP id s1CBR3xJ071356 for ; Wed, 12 Feb 2014 11:27:03 GMT (envelope-from nobody@cgiserv.freebsd.org) Received: (from nobody@localhost) by cgiserv.freebsd.org (8.14.7/8.14.7/Submit) id s1CBR3Rb071353; Wed, 12 Feb 2014 11:27:03 GMT (envelope-from nobody) Message-Id: <201402121127.s1CBR3Rb071353@cgiserv.freebsd.org> Date: Wed, 12 Feb 2014 11:27:03 GMT From: Renato Botelho To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: ports/186687: [patch] net-im/imspector: Modernize and add an option to build PLUGINS X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Feb 2014 11:30:01 -0000 >Number: 186687 >Category: ports >Synopsis: [patch] net-im/imspector: Modernize and add an option to build PLUGINS >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Feb 12 11:30:01 UTC 2014 >Closed-Date: >Last-Modified: >Originator: Renato Botelho >Release: 11-CURRENT >Organization: ESF LLC >Environment: FreeBSD fbsd1 11.0-CURRENT FreeBSD 11.0-CURRENT #1 r261771: Tue Feb 11 14:45:17 BRST 2014 root@fbsd1:/usr/obj/usr/src/sys/GARGA amd64 >Description: - Replace USE_GMAKE by USES=gmake - Use OPTIONS helpers - Support STAGING - Pet portlint - Add a new option, off by default, to build PLUGINS >How-To-Repeat: >Fix: Patch attached with submission follows: Index: Makefile =================================================================== --- Makefile (revision 343883) +++ Makefile (working copy) @@ -13,8 +13,7 @@ LICENSE= GPLv2 CFLAGS+= -fPIC -I ${LOCALBASE}/include -DHAVE_SSL -USE_GMAKE= YES -USES= iconv +USES= iconv gmake USE_OPENSSL= YES USE_LDCONFIG= ${LOCALBASE}/lib/imspector @@ -24,19 +23,20 @@ MAKE_ENV+= ETCDIR=${ETCDIR} -OPTIONS_DEFINE= IPFW -OPTIONS_DEFAULT= IPFW +OPTIONS_DEFINE= IPFW PLUGINS +OPTIONS_DEFAULT=IPFW +OPTIONS_SUB= yes + IPFW_DESC= Add IPFW support +PLUGINS_DESC= Build plugins -NO_STAGE= yes +IPFW_CFLAGS= -DIPFW_TRANSPARENT=1 +PLUGINS_USE= MYSQL=yes SQLITE=yes PGSQL=yes + .include -.if ${PORT_OPTIONS:MIPFW} -CFLAGS+= -DIPFW_TRANSPARENT=1 -.endif - post-extract: - ${MV} ${WRKDIR}/${PORTNAME} ${WRKSRC} + @${MV} ${WRKDIR}/${PORTNAME} ${WRKSRC} post-patch: @${REINPLACE_CMD} -e 's,%%PREFIX%%,${PREFIX},g' \ @@ -46,12 +46,9 @@ ${WRKSRC}/sslstate.cpp @${REINPLACE_CMD} -e 's,%%ICONV_LIB%%,${ICONV_LIB},' \ ${WRKSRC}/Makefile +.if ${PORT_OPTIONS:MPLUGINS} + @${REINPLACE_CMD} -e 's,#ADD_PLUGINS,ADD_PLUGINS,' \ + ${WRKSRC}/Makefile +.endif -post-install: -.for f in ${CONFIG_FILES} - @if [ ! -f ${ETCDIR}/${f} ]; then \ - ${CP} -p ${ETCDIR}/${f}.sample ${ETCDIR}/${f} ; \ - fi -.endfor - .include Index: files/patch-Makefile =================================================================== --- files/patch-Makefile (revision 343883) +++ files/patch-Makefile (working copy) @@ -1,5 +1,5 @@ ---- Makefile.orig 2008-12-22 15:03:15.000000000 +0300 -+++ Makefile 2011-06-14 14:26:22.072210675 +0400 +--- Makefile.orig 2010-02-23 14:20:33.000000000 -0300 ++++ Makefile 2014-02-11 21:23:19.000000000 -0200 @@ -1,5 +1,5 @@ -DESTDIR = / -PREFIX = /usr @@ -46,7 +46,7 @@ yahooprotocolplugin.so: yahooprotocolplugin.o libimspector.so $(CXX) yahooprotocolplugin.o libimspector.so $(PLUGIN_FLAGS) ircprotocolplugin.so: ircprotocolplugin.o libimspector.so -@@ -162,15 +162,15 @@ +@@ -162,17 +162,17 @@ install: imspector libimspector.so $(PLUGINS) -mkdir -p $(DESTDIR)/$(PREFIX)/sbin -mkdir -p $(DESTDIR)/$(PREFIX)/lib/imspector @@ -62,10 +62,14 @@ - -install imspector.conf $(DESTDIR)/$(PREFIX)/etc/imspector/imspector.conf - -install badwords.txt $(DESTDIR)/$(PREFIX)/etc/imspector/badwords.txt - -install acl.txt $(DESTDIR)/$(PREFIX)/etc/imspector/acl.txt +- -mkdir -p /var/log/imspector +- -mkdir -p /var/lib/imspector + -mkdir -p $(DESTDIR)/$(ETCDIR) + -${BSD_INSTALL_DATA} imspector.conf $(DESTDIR)/$(ETCDIR)/imspector.conf.sample + -${BSD_INSTALL_DATA} badwords.txt $(DESTDIR)/$(ETCDIR)/badwords.txt.sample + -${BSD_INSTALL_DATA} acl.txt $(DESTDIR)/$(ETCDIR)/acl.txt.sample - -mkdir -p /var/log/imspector - -mkdir -p /var/lib/imspector ++ -mkdir -p $(DESTDIR)/var/log/imspector ++ -mkdir -p $(DESTDIR)/var/lib/imspector + install-cert: + -mkdir -p $(DESTDIR)/$(PREFIX)/etc/imspector Index: pkg-plist =================================================================== --- pkg-plist (revision 343883) +++ pkg-plist (working copy) @@ -23,6 +23,11 @@ lib/imspector/miscfilterplugin.so lib/imspector/msnprotocolplugin.so lib/imspector/yahooprotocolplugin.so +%%PLUGINS%%lib/imspector/dbfilterplugin.so +%%PLUGINS%%lib/imspector/dbresponderplugin.so +%%PLUGINS%%lib/imspector/mysqlloggingplugin.so +%%PLUGINS%%lib/imspector/postgresqlloggingplugin.so +%%PLUGINS%%lib/imspector/sqliteloggingplugin.so lib/libimspector.so sbin/imspector @dirrmtry %%ETCDIR%% @@ -31,4 +36,4 @@ @dirrmtry lib/imspector @dirrmtry lib @dirrmtry log/imspector -@cwd +@cwd >Release-Note: >Audit-Trail: >Unformatted: