[100086] users/raimue/ports/sysutils/collectd

raimue at macports.org raimue at macports.org
Tue Nov 27 05:23:17 PST 2012


Revision: 100086
          https://trac.macports.org/changeset/100086
Author:   raimue at macports.org
Date:     2012-11-27 05:23:17 -0800 (Tue, 27 Nov 2012)
Log Message:
-----------
sysutils/collectd:
Update to version 5.2.0

This port does not work with MacPorts 2.1.2 as the list of selected variant is
too long to be encoded into a single filename for the archive (a workaround is
in trunk).

Modified Paths:
--------------
    users/raimue/ports/sysutils/collectd/Portfile
    users/raimue/ports/sysutils/collectd/files/dep-gen.sh

Removed Paths:
-------------
    users/raimue/ports/sysutils/collectd/files/patch-src-Makefile.am.patch
    users/raimue/ports/sysutils/collectd/files/patch-src-network.c.patch

Modified: users/raimue/ports/sysutils/collectd/Portfile
===================================================================
--- users/raimue/ports/sysutils/collectd/Portfile	2012-11-27 12:59:13 UTC (rev 100085)
+++ users/raimue/ports/sysutils/collectd/Portfile	2012-11-27 13:23:17 UTC (rev 100086)
@@ -4,6 +4,11 @@
 PortSystem          1.0
 
 name                collectd
+version             5.2.0
+categories          sysutils net
+platforms           darwin
+license             GPL-2
+maintainers         cal raimue openmaintainer
 description         flexible daemon periodically collecting system statistics data
 long_description    \
     collectd is a daemon which collects system performance statistics \
@@ -12,24 +17,25 @@
 
 homepage            http://collectd.org/
 master_sites        http://collectd.org/files/
-use_bzip2           yes
-version             5.0.3
-checksums           rmd160  aa33a349a82c63c6afc06ce0dbbd419175e42e45 \
-                    sha256  563d75c9b0a642077785a9f48424765c4d354b9fd69d4fa9e906ff3fd321736d
+use_bzip2 yes
 
-categories          sysutils net
-platforms           darwin
-license             GPL-2
+checksums           sha1 2176c80f804559edb3ef3a4dfea459e67f6cecbe \
+                    sha256 3f8dd235b8e2493a4ad558e3cd15b89007a0deaaef5481782d1e8e048dd43e4f
 
-maintainers         cal openmaintainer
+# collectd uses -Werror in their CFLAGS, which turns the warnings about unused
+# command line arguments generated by clang into errors. Suppress these
+# warnings when clang is used.
+if [string match *clang* ${configure.compiler}] {
+    configure.cflags-append -Qunused-arguments
+}
 
-patchfiles          patch-src-network.c.patch \
-                    patch-src-Makefile.am.patch
+#######################################################
+# WARNING: This list is generated by files/dep-gen.sh #
+#          Take care when editing manually!           #
+#######################################################
 
-use_automake        yes
-
-# enable all matches and targets, disable all the rest
-configure.args      \
+# enable all matches and targets, disable all other plugins
+configure.args \
     --enable-match_empty_counter \
     --enable-match_hashed \
     --enable-match_regex \
@@ -40,106 +46,113 @@
     --enable-target_scale \
     --enable-target_set \
     --enable-target_v5upgrade \
+    --disable-numa \
+    --disable-hddtemp \
+    --disable-exec \
+    --disable-uptime \
+    --disable-nginx \
+    --disable-cpufreq \
+    --disable-xmms \
+    --disable-thermal \
     --disable-mbmon \
-    --disable-amqp \
-    --disable-apache \
-    --disable-apcups \
-    --disable-apple_sensors \
-    --disable-ascent \
-    --disable-battery \
-    --disable-bind \
-    --disable-conntrack \
-    --disable-contextswitch \
-    --disable-cpufreq \
-    --disable-cpu \
-    --disable-csv \
-    --disable-curl \
-    --disable-curl_json \
-    --disable-curl_xml \
-    --disable-dbi \
-    --disable-df \
-    --disable-disk \
-    --disable-dns \
-    --disable-email \
-    --disable-entropy \
-    --disable-exec \
-    --disable-filecount \
-    --disable-fscache \
     --disable-gmond \
-    --disable-hddtemp \
-    --disable-interface \
-    --disable-ipmi \
+    --disable-tail \
+    --disable-notify_desktop \
+    --disable-ipvs \
+    --disable-protocols \
     --disable-iptables \
-    --disable-ipvs \
+    --disable-redis \
     --disable-irq \
-    --disable-java \
-    --disable-libvirt \
+    --disable-df \
+    --disable-perl \
+    --disable-ethstat \
+    --disable-write_graphite \
+    --disable-table \
+    --disable-logfile \
+    --disable-ipmi \
+    --disable-bind \
+    --disable-postgresql \
+    --disable-openvpn \
+    --disable-apcups \
+    --disable-swap \
+    --disable-interface \
+    --disable-contextswitch \
+    --disable-tcpconns \
+    --disable-onewire \
     --disable-load \
-    --disable-logfile \
-    --disable-lpar \
-    --disable-madwifi \
-    --disable-memcachec \
-    --disable-memcached \
-    --disable-memory \
-    --disable-modbus \
-    --disable-multimeter \
-    --disable-mysql \
-    --disable-netapp \
+    --disable-routeros \
     --disable-netlink \
-    --disable-network \
+    --disable-dns \
+    --disable-aggregation \
+    --disable-vserver \
     --disable-nfs \
-    --disable-nginx \
-    --disable-notify_desktop \
-    --disable-notify_email \
+    --disable-email \
+    --disable-zfs_arc \
+    --disable-tokyotyrant \
     --disable-ntpd \
-    --disable-nut \
-    --disable-olsrd \
-    --disable-onewire \
-    --disable-openvpn \
-    --disable-oracle \
-    --disable-perl \
-    --disable-pinba \
-    --disable-ping \
-    --disable-postgresql \
-    --disable-powerdns \
+    --disable-netapp \
+    --disable-ascent \
     --disable-processes \
-    --disable-protocols \
-    --disable-python \
-    --disable-redis \
-    --disable-routeros \
-    --disable-rrdcached \
-    --disable-rrdtool \
+    --disable-serial \
     --disable-sensors \
-    --disable-serial \
-    --disable-snmp \
-    --disable-swap \
-    --disable-syslog \
-    --disable-table \
-    --disable-tail \
-    --disable-tape \
-    --disable-tcpconns \
+    --disable-write_mongodb \
+    --disable-ted \
     --disable-teamspeak2 \
-    --disable-ted \
-    --disable-thermal \
+    --disable-curl_json \
+    --disable-java \
+    --disable-uuid \
     --disable-threshold \
-    --disable-tokyotyrant \
+    --disable-amqp \
+    --disable-olsrd \
+    --disable-network \
+    --disable-dbi \
+    --disable-curl_xml \
+    --disable-vmem \
+    --disable-varnish \
+    --disable-madwifi \
+    --disable-multimeter \
+    --disable-syslog \
+    --disable-filecount \
+    --disable-snmp \
+    --disable-ping \
+    --disable-csv \
     --disable-unixsock \
-    --disable-uptime \
+    --disable-curl \
+    --disable-disk \
+    --disable-write_http \
     --disable-users \
-    --disable-uuid \
-    --disable-varnish \
-    --disable-vmem \
-    --disable-vserver \
+    --disable-tape \
+    --disable-apple_sensors \
+    --disable-memory \
+    --disable-mysql \
+    --disable-memcachec \
+    --disable-md \
+    --disable-entropy \
+    --disable-memcached \
+    --disable-lpar \
+    --disable-rrdtool \
+    --disable-rrdcached \
+    --disable-pinba \
+    --disable-pf \
+    --disable-modbus \
     --disable-wireless \
-    --disable-write_http \
+    --disable-powerdns \
+    --disable-libvirt \
     --disable-write_redis \
-    --disable-xmms \
-    --disable-zfs_arc
+    --disable-nut \
+    --disable-notify_email \
+    --disable-fscache \
+    --disable-python \
+    --disable-oracle \
+    --disable-cpu \
+    --disable-apache \
+    --disable-conntrack \
+    --disable-battery \
 
-#######################################################
-# WARNING: This list is generated by files/dep-gen.sh #
-#          Take care when editing manually!           #
-#######################################################
+variant numa description {NUMA virtual memory statistics} {
+    configure.args-delete --disable-numa
+    configure.args-append --enable-numa
+}
 
 variant hddtemp description {Query hddtempd} {
     configure.args-delete --disable-hddtemp
@@ -207,22 +220,22 @@
     configure.args-delete --disable-perl
     configure.args-append --enable-perl
 
-    pre-configure {
-        set perl5bin "${prefix}/bin/perl5"
-        if {[string first "true" [exec ${perl5bin} -V:useshrplib]] == -1} {
-            ui_error "${name} requires perl5 to be installed with the +shared variant."
-            return -code error "perl5 must be +shared"
-        }
-        if {[string first "define" [exec ${perl5bin} -V:usethreads]] == -1} {
-            ui_error "${name} requires perl5 to be installed with the +threads variant."
-            return -code error "perl5 must be +threads"
-        }
-    }
+    configure.args-append --with-perl=${prefix}/bin/perl5.16
 
-    depends_lib-delete port:perl5.12
-    depends_lib-append port:perl5.12
+    depends_lib-delete port:perl5.16
+    depends_lib-append port:perl5.16
 }
 
+variant ethstat description {Stats from NIC driver} {
+    configure.args-delete --disable-ethstat
+    configure.args-append --enable-ethstat
+}
+
+variant write_graphite description {Graphite / Carbon output plugin} {
+    configure.args-delete --disable-write_graphite
+    configure.args-append --enable-write_graphite
+}
+
 variant table description {Parsing of tabular data} {
     configure.args-delete --disable-table
     configure.args-append --enable-table
@@ -292,6 +305,11 @@
     depends_lib-append port:libpcap
 }
 
+variant aggregation description {Aggregation plugin} {
+    configure.args-delete --disable-aggregation
+    configure.args-append --enable-aggregation
+}
+
 variant email description {EMail statistics} {
     configure.args-delete --disable-email
     configure.args-append --enable-email
@@ -310,6 +328,11 @@
     depends_lib-append port:curl port:libxml2
 }
 
+variant write_mongodb description {MongoDB output plugin} {
+    configure.args-delete --disable-write_mongodb
+    configure.args-append --enable-write_mongodb
+}
+
 variant ted description {Read The Energy Detective values} {
     configure.args-delete --disable-ted
     configure.args-append --enable-ted
@@ -467,6 +490,9 @@
 variant memcached description {memcached statistics} {
     configure.args-delete --disable-memcached
     configure.args-append --enable-memcached
+
+    depends_lib-delete port:libmemcached
+    depends_lib-append port:libmemcached
 }
 
 variant lpar description {AIX logical partitions statistics} {
@@ -490,6 +516,11 @@
     depends_lib-append port:rrdtool
 }
 
+variant pf description {BSD packet filter (PF) statistics} {
+    configure.args-delete --disable-pf
+    configure.args-append --enable-pf
+}
+
 variant powerdns description {PowerDNS statistics} {
     configure.args-delete --disable-powerdns
     configure.args-append --enable-powerdns
@@ -523,6 +554,8 @@
     configure.args-delete --disable-python
     configure.args-append --enable-python
 
+    configure.args-append --with-python=${prefix}/bin/python2.7
+
     depends_lib-delete port:python27
     depends_lib-append port:python27
 }

Modified: users/raimue/ports/sysutils/collectd/files/dep-gen.sh
===================================================================
--- users/raimue/ports/sysutils/collectd/files/dep-gen.sh	2012-11-27 12:59:13 UTC (rev 100085)
+++ users/raimue/ports/sysutils/collectd/files/dep-gen.sh	2012-11-27 13:23:17 UTC (rev 100086)
@@ -1,10 +1,26 @@
 #!/usr/bin/env bash
 # portfile generator for collectd plugins and their dependencies
 
-# this list is generated from collectd's ./configure output by applying the following regex:
+# these lists are generated from collectd's ./configure output by applying the following regex:
 # s/\v\s*--enable-(\w+)\s+(.*)$/[\1]="\2"/
+
+declare -a OPTIONS_ENABLE
+OPTIONS_ENABLE=(
+	match_empty_counter
+	match_hashed
+	match_regex
+	match_timediff
+	match_value
+	target_notification
+	target_replace
+	target_scale
+	target_set
+	target_v5upgrade
+)
+
 declare -A PLUGINS
 PLUGINS=(
+	[aggregation]="Aggregation plugin"
 	[amqp]="AMQP output plugin"
 	[apache]="Apache httpd statistics"
 	[apcups]="Statistics of UPSes by APC"
@@ -26,6 +42,7 @@
 	[dns]="DNS traffic analysis"
 	[email]="EMail statistics"
 	[entropy]="Entropy statistics"
+	[ethstat]="Stats from NIC driver"
 	[exec]="Execution of external programs"
 	[filecount]="Count files in directories"
 	[fscache]="fscache statistics"
@@ -43,6 +60,7 @@
 	[lpar]="AIX logical partitions statistics"
 	[madwifi]="Madwifi wireless statistics"
 	[mbmon]="Query mbmond"
+	[md]="md (Linux software RAID) devices"
 	[memcachec]="memcachec statistics"
 	[memcached]="memcached statistics"
 	[memory]="Memory usage"
@@ -57,12 +75,14 @@
 	[notify_desktop]="Desktop notifications"
 	[notify_email]="Email notifier"
 	[ntpd]="NTPd statistics"
+	[numa]="NUMA virtual memory statistics"
 	[nut]="Network UPS tools statistics"
 	[olsrd]="olsrd statistics"
 	[onewire]="OneWire sensor statistics"
 	[openvpn]="OpenVPN client statistics"
 	[oracle]="Oracle plugin"
 	[perl]="Embed a Perl interpreter"
+	[pf]="BSD packet filter (PF) statistics"
 	[pinba]="Pinba statistics"
 	[ping]="Network latency statistics"
 	[postgresql]="PostgreSQL database statistics"
@@ -96,8 +116,10 @@
 	[vmem]="Virtual memory statistics"
 	[vserver]="Linux VServer statistics"
 	[wireless]="Wireless statistics"
+	[write_graphite]="Graphite / Carbon output plugin"
 	[write_http]="HTTP output plugin"
 	[write_redis]="Redis output plugin"
+	[write_mongodb]="MongoDB output plugin"
 	[xmms]="XMMS statistics"
 	[zfs_arc]="ZFS ARC statistics"
 )
@@ -118,6 +140,7 @@
 	[ipmi]="port:openipmithread"
 	[libvirt]="port:libvirt port:libxml2"
 	[memcachec]="port:libmemcached"
+	[memcached]="port:libmemcached"
 	[modbus]="port:libmodbus"
 	[mysql]="path:lib/mysql5/mysql/libmysqlclient.dylib:mysql5"
 	[netapp]="port:libnetapp"
@@ -128,7 +151,7 @@
 	[notify_email]="port:libesmtp"
 	[nut]="port:nut"
 	[onewire]="port:libowcapi"
-	[perl]="port:perl5.12" # needs +shared +threads!
+	[perl]="port:perl5.16"
 	[pinba]="port:protobuf-c port:protoc-c"
 	[ping]="port:liboping"
 	[postgresql]="port:postgresql91"
@@ -159,6 +182,7 @@
 	[ipvs]=1		# Linux only
 	[irq]=1			# Linux only
 	[madwifi]=1		# Linux only
+	[md]=1			# Linux only
 	[modbus]=1		# requires libmodbus, which is not available
 	[netapp]=1		# requires libnetapp, which is not available
 	[netlink]=1		# requires libnetlink, which is not available
@@ -234,18 +258,11 @@
 
 declare -A EXTRA_CODE
 read -r -d '' PERL_EXTRA <<'EOF'
-    pre-configure {
-        set perl5bin "${prefix}/bin/perl5"
-        if {[string first "true" [exec ${perl5bin} -V:useshrplib]] == -1} {
-            ui_error "${name} requires perl5 to be installed with the +shared variant."
-            return -code error "perl5 must be +shared"
-        }
-        if {[string first "define" [exec ${perl5bin} -V:usethreads]] == -1} {
-            ui_error "${name} requires perl5 to be installed with the +threads variant."
-            return -code error "perl5 must be +threads"
-        }
-    }
+    configure.args-append --with-perl=${prefix}/bin/perl5.16
 EOF
+read -r -d '' PYTHON_EXTRA <<'EOF'
+    configure.args-append --with-python=${prefix}/bin/python2.7
+EOF
 read -r -d '' JAVA_EXTRA <<'EOF'
     pre-configure {
         ui_warn "Compiling with Java will probably fail; if you want to make it work, read `Configuring with libjvm' in README in the upstream git"
@@ -257,6 +274,7 @@
 EOF
 EXTRA_CODE=(
 	[perl]="$PERL_EXTRA"
+	[python]="$PYTHON_EXTRA"
 	[java]="$JAVA_EXTRA"
 	[network]="$NETWORK_EXTRA"
 )
@@ -268,7 +286,17 @@
 echo "#######################################################"
 echo
 
+echo "# enable all matches and targets, disable all other plugins"
+echo "configure.args \\"
+for option in ${OPTIONS_ENABLE[@]}; do
+	echo "    --enable-$option \\"
+done
 for plugin in ${!PLUGINS[@]}; do
+	echo "    --disable-$plugin \\"
+done
+echo
+
+for plugin in ${!PLUGINS[@]}; do
 	if [ -z "${OSX_BLACKLIST[$plugin]}" ]; then
 		printf "variant %s description {%s} {\n" "$plugin" "${PLUGINS[$plugin]}"
 		printf "    configure.args-delete --disable-$plugin\n"

Deleted: users/raimue/ports/sysutils/collectd/files/patch-src-Makefile.am.patch
===================================================================
--- users/raimue/ports/sysutils/collectd/files/patch-src-Makefile.am.patch	2012-11-27 12:59:13 UTC (rev 100085)
+++ users/raimue/ports/sysutils/collectd/files/patch-src-Makefile.am.patch	2012-11-27 13:23:17 UTC (rev 100086)
@@ -1,11 +0,0 @@
---- src/Makefile.am.orig	2012-03-10 02:30:26.000000000 +0100
-+++ src/Makefile.am	2012-03-10 02:30:32.000000000 +0100
-@@ -85,7 +85,7 @@
- 
- if BUILD_WITH_OWN_LIBOCONFIG
- collectd_LDADD += $(LIBLTDL) liboconfig/liboconfig.la
--collectd_DEPENDENCIES += $(LIBLTDL) liboconfig/liboconfig.la
-+collectd_DEPENDENCIES += liboconfig/liboconfig.la
- else
- collectd_LDADD += -loconfig
- endif

Deleted: users/raimue/ports/sysutils/collectd/files/patch-src-network.c.patch
===================================================================
--- users/raimue/ports/sysutils/collectd/files/patch-src-network.c.patch	2012-11-27 12:59:13 UTC (rev 100085)
+++ users/raimue/ports/sysutils/collectd/files/patch-src-network.c.patch	2012-11-27 13:23:17 UTC (rev 100086)
@@ -1,29 +0,0 @@
---- src/network.c.orig	2012-03-10 02:11:29.000000000 +0100
-+++ src/network.c	2012-03-10 02:13:01.000000000 +0100
-@@ -705,7 +705,7 @@
- 
- 	exp_size = 3 * sizeof (uint16_t)
- 		+ pkg_numval * (sizeof (uint8_t) + sizeof (value_t));
--	if ((buffer_len < 0) || (buffer_len < exp_size))
-+	if (buffer_len < exp_size)
- 	{
- 		WARNING ("network plugin: parse_part_values: "
- 				"Packet too short: "
-@@ -790,7 +790,7 @@
- 
- 	uint16_t pkg_length;
- 
--	if ((buffer_len < 0) || ((size_t) buffer_len < exp_size))
-+	if ((size_t) buffer_len < exp_size)
- 	{
- 		WARNING ("network plugin: parse_part_number: "
- 				"Packet too short: "
-@@ -829,7 +829,7 @@
- 
- 	uint16_t pkg_length;
- 
--	if ((buffer_len < 0) || (buffer_len < header_size))
-+	if (buffer_len < header_size)
- 	{
- 		WARNING ("network plugin: parse_part_string: "
- 				"Packet too short: "
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20121127/73b864e9/attachment-0001.html>


More information about the macports-changes mailing list