From feld@feld.me  Tue Apr 10 22:46:57 2012
Return-Path: <feld@feld.me>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 0D1A71065670
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 10 Apr 2012 22:46:57 +0000 (UTC)
	(envelope-from feld@feld.me)
Received: from feld.me (unknown [IPv6:2607:f4e0:100:300::2])
	by mx1.freebsd.org (Postfix) with ESMTP id D00CC8FC19
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 10 Apr 2012 22:46:56 +0000 (UTC)
Received: from feld by feld.me with local (Exim 4.77 (FreeBSD))
	(envelope-from <feld@feld.me>)
	id 1SHjpw-000FsB-6M; Tue, 10 Apr 2012 17:46:56 -0500
Message-Id: <E1SHjpw-000FsB-6M@feld.me>
Date: Tue, 10 Apr 2012 17:46:56 -0500
From: Mark Felder <feld@feld.me>
To: FreeBSD-gnats-submit@freebsd.org
Cc: ports@bsdserwis.com
Subject: [PATCH] net-mgmt/collectd: add routeros support
X-Send-Pr-Version: 3.113
X-GNATS-Notify: ports@bsdserwis.com

>Number:         166831
>Category:       ports
>Synopsis:       [PATCH] net-mgmt/collectd: add routeros support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    dhn
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Apr 10 22:50:00 UTC 2012
>Closed-Date:    Thu Apr 12 05:45:42 UTC 2012
>Last-Modified:  Thu Apr 12 05:50:12 UTC 2012
>Originator:     Mark Felder
>Release:        FreeBSD 9.0-STABLE amd64
>Organization:
>Environment:
System: FreeBSD mwi1.coffeenet.org 9.0-STABLE FreeBSD 9.0-STABLE #1 r230267: Tue Jan 17 15:11:44 CST
>Description:

Add routeros support

Port maintainer (ports@bsdserwis.com) is cc'd.

Generated with FreeBSD Port Tools 0.99_4 (mode: change, diff: suffix)
>How-To-Repeat:
>Fix:

--- collectd-4.10.4_2.patch begins here ---
diff -ruN --exclude=CVS ../collectd.orig/Makefile ./Makefile
--- ../collectd.orig/Makefile	2012-02-10 23:21:35.000000000 -0600
+++ ./Makefile	2012-04-10 17:43:45.000000000 -0500
@@ -7,7 +7,7 @@
 
 PORTNAME=	collectd
 PORTVERSION=	4.10.4
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	net-mgmt
 MASTER_SITES=	http://collectd.org/files/
 
@@ -41,6 +41,7 @@
 		PGSQL		"Input: PostgreSQL" 				Off \
 		PING		"Input: Network latency (liboping)" 		On  \
 		PYTHON		"Input: Python plugin"				Off  \
+		ROUTEROS	"Input: RouterOS plugin"			Off  \
 		SNMP		"Input: SNMP" 					On  \
 		TOKYOTYRANT	"Input: Tokyotyrant database"			Off \
 		XMMS		"Input: XMMS" 					Off \
@@ -105,7 +106,6 @@
 		--disable-perl \
 		--disable-pinba \
 		--disable-protocols \
-		--disable-routeros \
 		--disable-sensors \
 		--disable-serial \
 		--disable-table \
@@ -333,6 +333,15 @@
 PLIST_SUB+=	PYTHON="@comment "
 .endif
 
+.if defined(WITH_ROUTEROS)
+LIB_DEPENDS+=	routeros:${PORTSDIR}/net/librouteros
+CONFIGURE_ARGS+=--enable-routeros --with-librouteros=${LOCALBASE}
+PLIST_SUB+=     ROUTEROS=""
+.else
+CONFIGURE_ARGS+=--disable-routeros --without-librouteros
+PLIST_SUB+=	ROUTEROS="@comment "
+.endif
+
 .if defined(WITH_RRDTOOL)
 LIB_DEPENDS+=	rrd:${PORTSDIR}/databases/rrdtool
 CONFIGURE_ARGS+=--enable-rrdtool
diff -ruN --exclude=CVS ../collectd.orig/files/patch-configure.in ./files/patch-configure.in
--- ../collectd.orig/files/patch-configure.in	2012-01-09 15:13:47.000000000 -0600
+++ ./files/patch-configure.in	2012-04-10 16:47:38.000000000 -0500
@@ -1,6 +1,15 @@
---- configure.in.orig	2011-10-14 22:46:13.000000000 +0200
-+++ configure.in	2012-01-08 13:56:06.000000000 +0100
-@@ -1541,9 +1541,6 @@
+--- configure.in.orig	2011-10-14 12:49:49.000000000 -0800
++++ configure.in	2012-03-20 08:09:25.000000000 -0800
+@@ -98,7 +98,7 @@
+ fi
+ 
+ # Where to install .pc files.
+-pkgconfigdir="${libdir}/pkgconfig"
++pkgconfigdir="${prefix}/libdata/pkgconfig"
+ AC_SUBST(pkgconfigdir)
+ 
+ # Check for standards compliance mode
+@@ -1745,9 +1745,6 @@
  		[with_libgcrypt="yes"],
  		[with_libgcrypt="no (symbol gcry_md_hash_buffer not found)"])
  
@@ -10,16 +19,16 @@
  fi
  
  CPPFLAGS="$SAVE_CPPFLAGS"
-@@ -2960,7 +2957,7 @@
+@@ -3165,7 +3162,7 @@
  if test "x$with_python" = "xyes"
  then
  	AC_MSG_CHECKING([for Python LIBS])
 -	python_library_flags=`echo "import distutils.sysconfig;import sys;sys.stdout.write(distutils.sysconfig.get_config_vars(\"BLDLIBRARY\").__getitem__(0))" | "$with_python_prog" 2>&1`
-+	python_library_flags=`echo "import distutils.sysconfig;import sys;sys.stdout.write(distutils.sysconfig.get_config_vars(\"LIBDIR\").__getitem__(0)+\"/\"+distutils.sysconfig.get_config_vars(\"BLDLIBRARY\").__getitem__(0))" | "$with_python_prog" 2>&1`
++	python_library_flags=`echo "import distutils.sysconfig;import sys;sys.stdout.write(distutils.sysconfig.get_config_var(\"LINKFORSHARED\")+\" -L\"+distutils.sysconfig.get_config_vars(\"LIBDIR\").__getitem__(0)+\" -l\"+distutils.sysconfig.get_config_vars(\"BLDLIBRARY\").__getitem__(0).replace(\"lib\", \"\").replace(\".a\", \"\"))" | "$with_python_prog" 2>&1`
  	python_config_status=$?
  
  	if test "$python_config_status" -ne 0 || test "x$python_library_flags" = "x"
-@@ -2975,7 +2972,7 @@
+@@ -3180,7 +3177,7 @@
  if test "x$with_python" = "xyes"
  then
  	LDFLAGS="-L$python_library_path $LDFLAGS"
diff -ruN --exclude=CVS ../collectd.orig/pkg-plist ./pkg-plist
--- ../collectd.orig/pkg-plist	2011-12-26 10:33:51.000000000 -0600
+++ ./pkg-plist	2012-04-10 16:46:59.000000000 -0500
@@ -77,6 +77,8 @@
 %%PYTHON%%lib/collectd/python.so
 lib/collectd/processes.so
 lib/collectd/processes.la
+%%ROUTEROS%%lib/collectd/routeros.la
+%%ROUTEROS%%lib/collectd/routeros.so
 %%RRD%%lib/collectd/rrdtool.la
 %%RRD%%lib/collectd/rrdtool.so
 %%RRDCACHED%%lib/collectd/rrdcached.la
--- collectd-4.10.4_2.patch ends here ---

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->feedback 
State-Changed-By: edwin 
State-Changed-When: Tue Apr 10 22:50:16 UTC 2012 
State-Changed-Why:  
Awaiting maintainers feedback (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=166831 

From: Edwin Groothuis <edwin@FreeBSD.org>
To: ports@bsdserwis.com
Cc: bug-followup@FreeBSD.org
Subject: Re: ports/166831: [PATCH] net-mgmt/collectd: add routeros support
Date: Tue, 10 Apr 2012 22:50:14 UT

 Maintainer of net-mgmt/collectd,
 
 Please note that PR ports/166831 has just been submitted.
 
 If it contains a patch for an upgrade, an enhancement or a bug fix
 you agree on, reply to this email stating that you approve the patch
 and a committer will take care of it.
 
 The full text of the PR can be found at:
     http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/166831
 
 -- 
 Edwin Groothuis via the GNATS Auto Assign Tool
 edwin@FreeBSD.org

From: Krzysztof Stryjek <ports@bsdserwis.com>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/166831: [PATCH] net-mgmt/collectd: add routeros support
Date: Wed, 11 Apr 2012 09:52:28 +0200

 --cmJC7u66zC7hs+87
 Content-Type: text/plain; charset=iso-8859-2
 Content-Disposition: inline
 Content-Transfer-Encoding: quoted-printable
 
 Hello,
 
 On Tue, Apr 10, 2012 at 10:50:14PM +0000, Edwin Groothuis wrote:
 > Maintainer of net-mgmt/collectd,
 >=20
 > Please note that PR ports/166831 has just been submitted.
 >=20
 > If it contains a patch for an upgrade, an enhancement or a bug fix
 > you agree on, reply to this email stating that you approve the patch
 > and a committer will take care of it.
 >=20
 > The full text of the PR can be found at:
 >     http://www.freebsd.org/cgi/query-pr.cgi?pr=3Dports/166831
 >=20
 > --=20
 > Edwin Groothuis via the GNATS Auto Assign Tool
 > edwin@FreeBSD.org
 >=20
 Yes, I approve this patch.
 
 Greetings,
 --=20
 Krzysztof Stryjek
 UNIX administrator/Juniper Networks Specialist
 email: wtp (at) bsdserwis (dot) com
 http://www.linkedin.com/in/KrzysztofStryjek
 GPG fingerprint: 8BD7 40CE 8994 0BBE CE6C  91CD 1292 8959 DC61 0E76
 
 In theory, there is no difference between theory and practice.
 In practice, there is.
 
 --cmJC7u66zC7hs+87
 Content-Type: application/pgp-signature
 
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.19 (FreeBSD)
 
 iEYEARECAAYFAk+FODwACgkQEpKJWdxhDnbQ0wCglQt+URYY/S4e2/mupJHG4eMm
 D0YAoM+UGToyZRQF4aZ700hm6WlZ+mF3
 =MyCN
 -----END PGP SIGNATURE-----
 
 --cmJC7u66zC7hs+87--
State-Changed-From-To: feedback->open 
State-Changed-By: crees 
State-Changed-When: Wed Apr 11 08:10:03 UTC 2012 
State-Changed-Why:  
Maintainer has approved. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=166831 
Responsible-Changed-From-To: freebsd-ports-bugs->dhn 
Responsible-Changed-By: dhn 
Responsible-Changed-When: Wed Apr 11 09:56:48 UTC 2012 
Responsible-Changed-Why:  
I'll take it. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=166831 
State-Changed-From-To: open->closed 
State-Changed-By: dhn 
State-Changed-When: Thu Apr 12 05:45:40 UTC 2012 
State-Changed-Why:  
Committed, with minor changes. Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=166831 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/166831: commit references a PR
Date: Thu, 12 Apr 2012 05:44:28 +0000 (UTC)

 dhn         2012-04-12 05:44:15 UTC
 
   FreeBSD ports repository
 
   Modified files:
     net-mgmt/collectd    Makefile pkg-plist 
     net-mgmt/collectd/files patch-configure.in 
   Log:
   - Add RouterOS support
   
   PR:             ports/166831
   Submitted by:   Mark Felder <feld@feld.me>
   Approved by:    Krzysztof Stryjek <ports@bsdserwis.com> (maintainer)
   
   Revision  Changes    Path
   1.38      +11 -2     ports/net-mgmt/collectd/Makefile
   1.3       +15 -6     ports/net-mgmt/collectd/files/patch-configure.in
   1.14      +2 -0      ports/net-mgmt/collectd/pkg-plist
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
