Code

RPM specfile: indentation + other minor adjustments
[collectd.git] / contrib / redhat / collectd.spec
1 #
2 # q: What is this ?
3 # a: A specfile for building RPM packages of current collectd releases, for
4 #    RHEL/CentOS versions 5, 6 and 7. By default all the plugins which are
5 #    buildable based on the libraries available in the distribution + the
6 #    EPEL repository, will be built. Plugins depending on external libs will
7 #    be packaged in separate RPMs.
8 #
9 # q: And how can I do that ?
10 # a: By following these instructions, using mock:
11 #
12 # - install and configure mock (https://fedoraproject.org/wiki/Projects/Mock)
13 #
14 # - enable the EPEL repository (http://dl.fedoraproject.org/pub/epel/) in the
15 #   configuration files for your target systems (/etc/mock/*.cfg).
16 #
17 # - copy this file in your ~/rpmbuild/SPECS/ directory
18 #
19 # - fetch the desired collectd release file from https://collectd.org/files/
20 #   and save it in your ~/rpmbuild/SOURCES/ directory
21 #
22 # - build the SRPM first:
23 #   mock -r centos-6-x86_64 --buildsrpm --spec ~/rpmbuild/SPECS/collectd.spec \
24 #     --sources ~/rpmbuild/SOURCES/
25 #
26 # - then build the RPMs:
27 #   mock -r centos-6-x86_64 --no-clean --rebuild \
28 #     /var/lib/mock/centos-6-x86_64/result/collectd-X.Y.Z-NN.src.rpm
29 #
30 # - you can also optionally enable/disable plugins which are disabled/enabled
31 #   by default:
32 #   mock -r centos-6-x86_64 --no-clean --without=java --with=oracle --rebuild \
33 #     /var/lib/mock/centos-6-x86_64/result/collectd-X.Y.Z-NN.src.rpm
34 #
36 %global _hardened_build 1
38 # plugins only buildable on RHEL6
39 # (NB: %{elN} macro is not available on RHEL < 6)
40 %{?el6:%global _has_libyajl 1}
41 %{?el6:%global _has_recent_libpcap 1}
42 %{?el6:%global _has_recent_sockios_h 1}
43 %{?el6:%global _has_recent_libganglia 1}
44 %{?el6:%global _has_working_libiptc 1}
45 %{?el6:%global _has_ip_vs_h 1}
46 %{?el6:%global _has_lvm2app_h 1}
47 %{?el6:%global _has_libmodbus 1}
48 %{?el6:%global _has_libudev 1}
49 %{?el6:%global _has_iproute 1}
50 %{?el6:%global _has_atasmart 1}
51 %{?el6:%global _has_hiredis 1}
53 %{?el7:%global _has_libyajl 1}
54 %{?el7:%global _has_recent_libpcap 1}
55 %{?el7:%global _has_recent_sockios_h 1}
56 %{?el7:%global _has_working_libiptc 1}
57 %{?el7:%global _has_ip_vs_h 1}
58 %{?el7:%global _has_lvm2app_h 1}
59 %{?el7:%global _has_libudev 1}
60 %{?el7:%global _has_recent_librrd 1}
61 %{?el7:%global _has_varnish4 1}
62 %{?el7:%global _has_broken_libmemcached 1}
63 %{?el7:%global _has_iproute 1}
64 %{?el7:%global _has_atasmart 1}
65 %{?el7:%global _has_hiredis 1}
67 # plugins enabled by default
68 %define with_aggregation 0%{!?_without_aggregation:1}
69 %define with_amqp 0%{!?_without_amqp:1}
70 %define with_apache 0%{!?_without_apache:1}
71 %define with_apcups 0%{!?_without_apcups:1}
72 %define with_ascent 0%{!?_without_ascent:1}
73 %define with_battery 0%{!?_without_battery:1}
74 %define with_bind 0%{!?_without_bind:1}
75 %define with_cgroups 0%{!?_without_cgroups:1}
76 %define with_conntrack 0%{!?_without_conntrack:1}
77 %define with_contextswitch 0%{!?_without_contextswitch:1}
78 %define with_cpu 0%{!?_without_cpu:1}
79 %define with_cpufreq 0%{!?_without_cpufreq:1}
80 %define with_csv 0%{!?_without_csv:1}
81 %define with_curl 0%{!?_without_curl:1}
82 %define with_curl_json 0%{!?_without_curl_json:0%{?_has_libyajl}}
83 %define with_curl_xml 0%{!?_without_curl_xml:1}
84 %define with_dbi 0%{!?_without_dbi:1}
85 %define with_df 0%{!?_without_df:1}
86 %define with_disk 0%{!?_without_disk:1}
87 %define with_dns 0%{!?_without_dns:0%{?_has_recent_libpcap}}
88 %define with_drbd 0%{!?_without_drbd:1}
89 %define with_email 0%{!?_without_email:1}
90 %define with_entropy 0%{!?_without_entropy:1}
91 %define with_ethstat 0%{!?_without_ethstat:0%{?_has_recent_sockios_h}}
92 %define with_exec 0%{!?_without_exec:1}
93 %define with_filecount 0%{!?_without_filecount:1}
94 %define with_fscache 0%{!?_without_fscache:1}
95 %define with_gmond 0%{!?_without_gmond:0%{?_has_recent_libganglia}}
96 %define with_hddtemp 0%{!?_without_hddtemp:1}
97 %define with_interface 0%{!?_without_interface:1}
98 %define with_ipmi 0%{!?_without_ipmi:1}
99 %define with_iptables 0%{!?_without_iptables:0%{?_has_working_libiptc}}
100 %define with_ipvs 0%{!?_without_ipvs:0%{?_has_ip_vs_h}}
101 %define with_irq 0%{!?_without_irq:1}
102 %define with_java 0%{!?_without_java:1}
103 %define with_virt 0%{!?_without_virt:1}
104 %define with_load 0%{!?_without_load:1}
105 %define with_logfile 0%{!?_without_logfile:1}
106 %define with_log_logstash 0%{!?_without_log_logstash:0%{?_has_libyajl}}
107 %define with_lvm 0%{!?_without_lvm:0%{?_has_lvm2app_h}}
108 %define with_madwifi 0%{!?_without_madwifi:1}
109 %define with_mbmon 0%{!?_without_mbmon:1}
110 %define with_md 0%{!?_without_md:1}
111 %define with_memcachec 0%{!?_without_memcachec:0%{!?_has_broken_libmemcached:1}}
112 %define with_memcached 0%{!?_without_memcached:1}
113 %define with_memory 0%{!?_without_memory:1}
114 %define with_multimeter 0%{!?_without_multimeter:1}
115 %define with_modbus 0%{!?_without_modbus:0%{?_has_libmodbus}}
116 %define with_mysql 0%{!?_without_mysql:1}
117 %define with_netlink 0%{!?_without_netlink:0%{?_has_iproute}}
118 %define with_network 0%{!?_without_network:1}
119 %define with_nfs 0%{!?_without_nfs:1}
120 %define with_nginx 0%{!?_without_nginx:1}
121 %define with_notify_desktop 0%{!?_without_notify_desktop:1}
122 %define with_notify_email 0%{!?_without_notify_email:1}
123 %define with_ntpd 0%{!?_without_ntpd:1}
124 %define with_numa 0%{!?_without_numa:1}
125 %define with_nut 0%{!?_without_nut:1}
126 %define with_olsrd 0%{!?_without_olsrd:1}
127 %define with_openldap 0%{!?_without_openldap:1}
128 %define with_openvpn 0%{!?_without_openvpn:1}
129 %define with_perl 0%{!?_without_perl:1}
130 %define with_pinba 0%{!?_without_pinba:1}
131 %define with_ping 0%{!?_without_ping:1}
132 %define with_postgresql 0%{!?_without_postgresql:1}
133 %define with_powerdns 0%{!?_without_powerdns:1}
134 %define with_processes 0%{!?_without_processes:1}
135 %define with_protocols 0%{!?_without_protocols:1}
136 %define with_python 0%{!?_without_python:1}
137 %define with_redis 0%{!?_without_redis:0%{?_has_hiredis}}
138 %define with_rrdcached 0%{!?_without_rrdcached:0%{?_has_recent_librrd}}
139 %define with_rrdtool 0%{!?_without_rrdtool:1}
140 %define with_sensors 0%{!?_without_sensors:1}
141 %define with_serial 0%{!?_without_serial:1}
142 %define with_smart 0%{!?_without_smart:0%{?_has_atasmart}}
143 %define with_snmp 0%{!?_without_snmp:1}
144 %define with_statsd 0%{!?_without_statsd:1}
145 %define with_swap 0%{!?_without_swap:1}
146 %define with_syslog 0%{!?_without_syslog:1}
147 %define with_table 0%{!?_without_table:1}
148 %define with_tail 0%{!?_without_tail:1}
149 %define with_tail_csv 0%{!?_without_tail_csv:1}
150 %define with_tcpconns 0%{!?_without_tcpconns:1}
151 %define with_teamspeak2 0%{!?_without_teamspeak2:1}
152 %define with_ted 0%{!?_without_ted:1}
153 %define with_thermal 0%{!?_without_thermal:1}
154 %define with_threshold 0%{!?_without_threshold:1}
155 %define with_unixsock 0%{!?_without_unixsock:1}
156 %define with_uptime 0%{!?_without_uptime:1}
157 %define with_users 0%{!?_without_users:1}
158 %define with_uuid 0%{!?_without_uuid:1}
159 %define with_varnish 0%{!?_without_varnish:0%{!?_has_varnish4:1}}
160 %define with_vmem 0%{!?_without_vmem:1}
161 %define with_vserver 0%{!?_without_vserver:1}
162 %define with_wireless 0%{!?_without_wireless:1}
163 %define with_write_graphite 0%{!?_without_write_graphite:1}
164 %define with_write_http 0%{!?_without_write_http:1}
165 %define with_write_redis 0%{!?_without_write_redis:0%{?_has_hiredis}}
166 %define with_write_riemann 0%{!?_without_write_riemann:1}
167 %define with_write_tsdb 0%{!?_without_write_tsdb:1}
168 %define with_zfs_arc 0%{!?_without_zfs_arc:1}
169 %define with_zookeeper 0%{!?_without_zookeeper:1}
171 # Plugins not built by default because of dependencies on libraries not
172 # available in RHEL or EPEL:
174 # plugin apple_sensors disabled, requires a Mac
175 %define with_apple_sensors 0%{!?_without_apple_sensors:0}
176 # plugin aquaero disabled, requires a libaquaero5
177 %define with_aquaero 0%{!?_without_aquaero:0}
178 # plugin barometer disabled, requires a libi2c
179 %define with_barometer 0%{!?_without_barometer:0}
180 # plugin lpar disabled, requires AIX
181 %define with_lpar 0%{!?_without_lpar:0}
182 # plugin mic disabled, requires Mic
183 %define with_mic 0%{!?_without_mic:0}
184 # plugin netapp disabled, requires libnetapp
185 %define with_netapp 0%{!?_without_netapp:0}
186 # plugin onewire disabled, requires libowfs
187 %define with_onewire 0%{!?_without_onewire:0}
188 # plugin oracle disabled, requires Oracle
189 %define with_oracle 0%{!?_without_oracle:0}
190 # plugin oracle disabled, requires BSD
191 %define with_pf 0%{!?_without_pf:0}
192 # plugin routeros disabled, requires librouteros
193 %define with_routeros 0%{!?_without_routeros:0}
194 # plugin sigrok disabled, requires libsigrok
195 %define with_sigrok 0%{!?_without_sigrok:0}
196 # plugin tape disabled, requires libkstat
197 %define with_tape 0%{!?_without_tape:0}
198 # plugin tokyotyrant disabled, requires tcrdb.h
199 %define with_tokyotyrant 0%{!?_without_tokyotyrant:0}
200 # plugin write_kafka disabled, requires librdkafka
201 %define with_write_kafka 0%{!?_without_write_kafka:0}
202 # plugin write_mongodb disabled, requires libmongoc
203 %define with_write_mongodb 0%{!?_without_write_mongodb:0}
204 # plugin xmms disabled, requires xmms
205 %define with_xmms 0%{!?_without_xmms:0}
207 Summary:        Statistics collection daemon for filling RRD files
208 Name:           collectd
209 Version:        5.4.0
210 Release:        1%{?dist}
211 URL:            http://collectd.org
212 Source:         http://collectd.org/files/%{name}-%{version}.tar.bz2
213 License:        GPLv2
214 Group:          System Environment/Daemons
215 BuildRoot:      %{_tmppath}/%{name}-%{version}-root
216 BuildRequires:  libgcrypt-devel, kernel-headers
217 Vendor:         collectd development team <collectd@verplant.org>
219 %if 0%{?el7:1}
220 Requires(pre):          initscripts
221 Requires(post):         systemd
222 Requires(preun):        systemd
223 Requires(postun):       systemd
224 %else
225         %if 0%{?el6:1}
226 Requires(pre):          initscripts
227 Requires(preun):        upstart
228 Requires(postun):       upstart
229         %else
230 Requires(post):         chkconfig
231 Requires(preun):        chkconfig, initscripts
232 Requires(postun):       initscripts
233         %endif
234 %endif
236 %description
237 collectd is a small daemon which collects system information periodically and
238 provides mechanisms to monitor and store the values in a variety of ways. It
239 is written in C for performance. Since the daemon doesn't need to start up
240 every time it wants to update the values it's very fast and easy on the
241 system. Also, the statistics are very fine grained since the files are updated
242 every 10 seconds by default.
244 %if %{with_amqp}
245 %package amqp
246 Summary:        AMQP plugin for collectd
247 Group:          System Environment/Daemons
248 Requires:       %{name}%{?_isa} = %{version}-%{release}
249 BuildRequires:  librabbitmq-devel
250 %description amqp
251 The AMQP plugin transmits or receives values collected by collectd via the
252 Advanced Message Queuing Protocol (AMQP).
253 %endif
255 %if %{with_apache}
256 %package apache
257 Summary:        Apache plugin for collectd
258 Group:          System Environment/Daemons
259 Requires:       %{name}%{?_isa} = %{version}-%{release}
260 BuildRequires:  curl-devel
261 %description apache
262 This plugin collects data provided by Apache's `mod_status'.
263 %endif
265 %if %{with_aquaero}
266 %package aquaero
267 Summary:        aquaero plugin for collectd
268 Group:          System Environment/Daemons
269 Requires:       %{name}%{?_isa} = %{version}-%{release}
270 %description aquaero
271 Various sensors in the Aquaero 5 watercooling board made by Aquacomputer.
272 %endif
274 %if %{with_ascent}
275 %package ascent
276 Summary:        Ascent plugin for collectd
277 Group:          System Environment/Daemons
278 Requires:       %{name}%{?_isa} = %{version}-%{release}
279 BuildRequires:  libxml2-devel, curl-devel
280 %description ascent
281 The Ascent plugin reads and parses the statistics page of Ascent, a free and
282 open-source server software for the game World of Warcraft by Blizzard
283 Entertainment.
284 %endif
286 %if %{with_barometer}
287 %package barometer
288 Summary:       barometer plugin for collectd
289 Group:         System Environment/Daemons
290 Requires:      %{name}%{?_isa} = %{version}-%{release}
291 %description barometer
292 Collects pressure and temperature from digital barometers.
293 %endif
295 %if %{with_bind}
296 %package bind
297 Summary:        Bind plugin for collectd
298 Group:          System Environment/Daemons
299 Requires:       %{name}%{?_isa} = %{version}-%{release}
300 BuildRequires:  libxml2-devel, curl-devel
301 %description bind
302 The BIND plugin retrieves this information that's encoded in XML and provided
303 via HTTP and submits the values to collectd.
304 %endif
306 %if %{with_curl}
307 %package curl
308 Summary:        Curl plugin for collectd
309 Group:          System Environment/Daemons
310 Requires:       %{name}%{?_isa} = %{version}-%{release}
311 BuildRequires:  curl-devel
312 %description curl
313 The cURL plugin uses libcurl to read files and then parses them according to
314 the configuration.
315 %endif
317 %if %{with_curl_json}
318 %package curl_json
319 Summary:        Curl_json plugin for collectd
320 Group:          System Environment/Daemons
321 Requires:       %{name}%{?_isa} = %{version}-%{release}
322 BuildRequires:  curl-devel, yajl-devel
323 %description curl_json
324 The cURL-JSON plugin queries JavaScript Object Notation (JSON) data using the
325 cURL library and parses it according to the user's configuration.
326 %endif
328 %if %{with_curl_xml}
329 %package curl_xml
330 Summary:        Curl_xml plugin for collectd
331 Group:          System Environment/Daemons
332 Requires:       %{name}%{?_isa} = %{version}-%{release}
333 BuildRequires:  curl-devel, libxml2-devel
334 %description curl_xml
335 The cURL-XML plugin reads files using libcurl and parses it as Extensible
336 Markup Language (XML).
337 %endif
339 %if %{with_dbi}
340 %package dbi
341 Summary:        DBI plugin for collectd
342 Group:          System Environment/Daemons
343 Requires:       %{name}%{?_isa} = %{version}-%{release}
344 BuildRequires:  libdbi-devel
345 %description dbi
346 The DBI plugin uses libdbi, a database abstraction library, to execute SQL
347 statements on a database and read back the result.
348 %endif
350 %if %{with_disk}
351 %package disk
352 Summary:        disk plugin for collectd
353 Group:          System Environment/Daemons
354 Requires:       %{name}%{?_isa} = %{version}-%{release}
355 %{?_has_libudev:BuildRequires:  libudev-devel}
356 %description disk
357 The "disk" plugin collects information about the usage of physical disks and
358 logical disks (partitions).
359 %endif
361 %if %{with_dns}
362 %package dns
363 Summary:        DNS plugin for collectd
364 Group:          System Environment/Daemons
365 Requires:       %{name}%{?_isa} = %{version}-%{release}, libpcap >= 1.0
366 BuildRequires:  libpcap-devel >= 1.0
367 %description dns
368 The DNS plugin has a similar functionality to dnstop: It uses libpcap to get a
369 copy of all traffic from/to port UDP/53 (that's the DNS port), interprets the
370 packets and collects statistics of your DNS traffic.
371 %endif
373 %if %{with_email}
374 %package email
375 Summary:        Email plugin for collectd
376 Group:          System Environment/Daemons
377 Requires:       %{name}%{?_isa} = %{version}-%{release}, spamassassin
378 %description email
379 This plugin collects data provided by spamassassin.
380 %endif
382 %if %{with_gmond}
383 %package gmond
384 Summary:        Gmond plugin for collectd
385 Group:          System Environment/Daemons
386 Requires:       %{name}%{?_isa} = %{version}-%{release}
387 BuildRequires:  ganglia-devel
388 %description gmond
389 The gmond plugin subscribes to a Multicast group to receive data from gmond,
390 the client daemon of the Ganglia project.
391 %endif
393 %if %{with_hddtemp}
394 %package hddtemp
395 Summary:        Hddtemp plugin for collectd
396 Group:          System Environment/Daemons
397 Requires:       %{name}%{?_isa} = %{version}-%{release}, hddtemp
398 %description hddtemp
399 The HDDTemp plugin collects the temperature of hard disks. The temperatures are
400 provided via SMART and queried by the external hddtemp daemon.
401 %endif
403 %if %{with_ipmi}
404 %package ipmi
405 Summary:        IPMI plugin for collectd
406 Group:          System Environment/Daemons
407 Requires:       %{name}%{?_isa} = %{version}-%{release}
408 BuildRequires:  OpenIPMI-devel
409 %description ipmi
410 The IPMI plugin uses the OpenIPMI library to read hardware sensors from servers
411 using the Intelligent Platform Management Interface (IPMI).
412 %endif
414 %if %{with_iptables}
415 %package iptables
416 Summary:        IPtables plugin for collectd
417 Group:          System Environment/Daemons
418 Requires:       %{name}%{?_isa} = %{version}-%{release}
419 BuildRequires:  iptables-devel
420 %description iptables
421 The IPtables plugin can gather statistics from your ip_tables based packet
422 filter (aka. firewall) for both the IPv4 and the IPv6 protocol. It can collect
423 the byte- and packet-counters of selected rules and submit them to collectd.
424 %endif
426 %if %{with_java}
427 %package java
428 Summary:        Java plugin for collectd
429 Group:          System Environment/Daemons
430 Requires:       %{name}%{?_isa} = %{version}-%{release}
431 BuildRequires:  java-devel, jpackage-utils
432 Requires:       java, jpackage-utils
433 %description java
434 This plugin for collectd allows plugins to be written in Java and executed
435 in an embedded JVM.
436 %endif
438 %if %{with_log_logstash}
439 %package log_logstash
440 Summary:       log_logstash plugin for collectd
441 Group:         System Environment/Daemons
442 Requires:      %{name}%{?_isa} = %{version}-%{release}
443 BuildRequires: yajl-devel
444 %description log_logstash
445 This plugin logs in logstash JSON format
446 %endif
448 %if %{with_lvm}
449 %package lvm
450 Summary:        LVM plugin for collectd
451 Group:          System Environment/Daemons
452 Requires:       %{name}%{?_isa} = %{version}-%{release}
453 BuildRequires:  lvm2-devel
454 %description lvm
455 This plugin collects size of “Logical Volumes” (LV) and “Volume Groups” (VG)
456 of Linux' “Logical Volume Manager” (LVM).
457 %endif
459 %if %{with_memcachec}
460 %package memcachec
461 Summary:        Memcachec plugin for collectd
462 Group:          System Environment/Daemons
463 Requires:       %{name}%{?_isa} = %{version}-%{release}
464 BuildRequires:  libmemcached-devel
465 %description memcachec
466 The Memcachec plugin uses libmemcached to read statistics from a Memcached
467 instance. Note that another plugin, named `memcached', exists and does a
468 similar job, without requiring the installation of libmemcached.
469 %endif
471 %if %{with_mic}
472 %package mic
473 Summary:        mic plugin for collectd
474 Group:          System Environment/Daemons
475 Requires:       %{name}%{?_isa} = %{version}-%{release}
476 %description mic
477 The mic plugin collects CPU usage, memory usage, temperatures and power
478 consumption from Intel Many Integrated Core (MIC) CPUs.
479 %endif
481 %if %{with_modbus}
482 %package modbus
483 Summary:       modbus plugin for collectd
484 Group:         System Environment/Daemons
485 Requires:      %{name}%{?_isa} = %{version}-%{release}
486 BuildRequires:  libmodbus-devel
487 %description modbus
488 The modbus plugin collects values from Modbus/TCP enabled devices
489 %endif
491 %if %{with_mysql}
492 %package mysql
493 Summary:        MySQL plugin for collectd
494 Group:          System Environment/Daemons
495 Requires:       %{name}%{?_isa} = %{version}-%{release}
496 BuildRequires:  mysql-devel
497 %description mysql
498 MySQL querying plugin. This plugin provides data of issued commands, called
499 handlers and database traffic.
500 %endif
502 %if %{with_netlink}
503 %package netlink
504 Summary:        netlink plugin for collectd
505 Group:          System Environment/Daemons
506 Requires:       %{name}%{?_isa} = %{version}-%{release}
507 BuildRequires:  libmnl-devel, iproute-devel
508 %description netlink
509 The netlink plugin collects detailed network interface and routing statistics.
510 %endif
512 %if %{with_nginx}
513 %package nginx
514 Summary:        Nginx plugin for collectd
515 Group:          System Environment/Daemons
516 Requires:       %{name}%{?_isa} = %{version}-%{release}
517 BuildRequires:  curl-devel
518 %description nginx
519 This plugin gets data provided by nginx.
520 %endif
522 %if %{with_notify_desktop}
523 %package notify_desktop
524 Summary:        Notify_desktop plugin for collectd
525 Group:          System Environment/Daemons
526 Requires:       %{name}%{?_isa} = %{version}-%{release}
527 BuildRequires:  libnotify-devel, gtk2-devel
528 %description notify_desktop
529 The Notify Desktop plugin uses libnotify to display notifications to the user
530 via the desktop notification specification, i. e. on an X display.
531 %endif
533 %if %{with_notify_email}
534 %package notify_email
535 Summary:        Notify_email plugin for collectd
536 Group:          System Environment/Daemons
537 Requires:       %{name}%{?_isa} = %{version}-%{release}
538 BuildRequires:  libesmtp-devel
539 %description notify_email
540 The Notify Email plugin uses libESMTP to send notifications to a configured
541 email address.
542 %endif
544 %if %{with_nut}
545 %package nut
546 Summary:        Nut plugin for collectd
547 Group:          System Environment/Daemons
548 Requires:       %{name}%{?_isa} = %{version}-%{release}
549 BuildRequires:  nut-devel
550 %description nut
551 This plugin for collectd provides Network UPS Tools support.
552 %endif
554 %if %{with_openldap}
555 %package openldap
556 Summary:       Openldap plugin for collectd
557 Group:         System Environment/Daemons
558 Requires:      %{name}%{?_isa} = %{version}-%{release}
559 BuildRequires: openldap-devel
560 %description openldap
561 This plugin reads monitoring information from OpenLDAP's cn=Monitor subtree.
562 %endif
564 %if %{with_perl}
565 %package perl
566 Summary:        Perl plugin for collectd
567 Group:          System Environment/Daemons
568 Requires:       %{name}%{?_isa} = %{version}-%{release}
569 Requires:       perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
570         %if 0%{?rhel} >= 6
571 BuildRequires:  perl-ExtUtils-Embed
572         %else
573 BuildRequires:  perl
574         %endif
575 %description perl
576 The Perl plugin embeds a Perl interpreter into collectd and exposes the
577 application programming interface (API) to Perl-scripts.
578 %endif
580 %if %{with_pinba}
581 %package pinba
582 Summary:        Pinba plugin for collectd
583 Group:          System Environment/Daemons
584 Requires:       %{name}%{?_isa} = %{version}-%{release}
585 BuildRequires:  protobuf-c-devel
586 %description pinba
587 The Pinba plugin receives and dispatches timing values from Pinba, a profiling
588 extension for PHP.
589 %endif
591 %if %{with_ping}
592 %package ping
593 Summary:        Ping plugin for collectd
594 Group:          System Environment/Daemons
595 Requires:       %{name}%{?_isa} = %{version}-%{release}
596 BuildRequires:  liboping-devel
597 %description ping
598 The Ping plugin measures network latency using ICMP “echo requests”, usually
599 known as “ping”.
600 %endif
602 %if %{with_postgresql}
603 %package postgresql
604 Summary:        PostgreSQL plugin for collectd
605 Group:          System Environment/Daemons
606 Requires:       %{name}%{?_isa} = %{version}-%{release}
607 BuildRequires:  postgresql-devel
608 %description postgresql
609 The PostgreSQL plugin connects to and executes SQL statements on a PostgreSQL
610 database.
611 %endif
613 %if %{with_python}
614 %package python
615 Summary:        Python plugin for collectd
616 Group:          System Environment/Daemons
617 Requires:       %{name}%{?_isa} = %{version}-%{release}
618         %if 0%{?rhel} >= 6
619 BuildRequires: python-devel
620         %else
621 BuildRequires: python26-devel
622         %endif
623 %description python
624 The Python plugin embeds a Python interpreter into collectd and exposes the
625 application programming interface (API) to Python-scripts.
626 %endif
628 %if %{with_redis}
629 %package redis
630 Summary:        Redis plugin for collectd
631 Group:          System Environment/Daemons
632 Requires:       %{name}%{?_isa} = %{version}-%{release}
633 BuildRequires:  hiredis-devel
634 %description redis
635 The Redis plugin connects to one or more instances of Redis, a key-value store,
636 and collects usage information using the hiredis library.
637 %endif
639 %if %{with_rrdcached}
640 %package rrdcached
641 Summary:        RRDCached plugin for collectd
642 Group:          System Environment/Daemons
643 Requires:       %{name}%{?_isa} = %{version}-%{release}, rrdtool >= 1.4
644 BuildRequires:  rrdtool-devel
645 %description rrdcached
646 The RRDCacheD plugin connects to the “RRD caching daemon”, rrdcached and
647 submits updates for RRD files to that daemon.
648 %endif
650 %if %{with_rrdtool}
651 %package rrdtool
652 Summary:        RRDtool plugin for collectd
653 Group:          System Environment/Daemons
654 Requires:       %{name}%{?_isa} = %{version}-%{release}
655 BuildRequires:  rrdtool-devel
656 %description rrdtool
657 The RRDtool plugin writes values to RRD-files using librrd.
658 %endif
660 %if %{with_sensors}
661 %package sensors
662 Summary:        Sensors plugin for collectd
663 Group:          System Environment/Daemons
664 Requires:       %{name}%{?_isa} = %{version}-%{release}
665 BuildRequires:  lm_sensors-devel
666 %description sensors
667 This plugin for collectd provides querying of sensors supported by lm_sensors.
668 %endif
670 %if %{with_sigrok}
671 %package sigrok
672 Summary:        sigrok plugin for collectd
673 Group:          System Environment/Daemons
674 Requires:       %{name}%{?_isa} = %{version}-%{release}
675 %description sigrok
676 Uses libsigrok as a backend, allowing any sigrok-supported device to have its
677 measurements fed to collectd. This includes multimeters, sound level meters,
678 thermometers, and much more.
679 %endif
681 %if %{with_smart}
682 %package smart
683 Summary:       SMART plugin for collectd
684 Group:         System Environment/Daemons
685 Requires:      %{name}%{?_isa} = %{version}-%{release}
686 BuildRequires: libatasmart-devel
687 %description smart
688 Collect SMART statistics, notably load cycle count, temperature and bad
689 sectors.
690 %endif
692 %if %{with_snmp}
693 %package snmp
694 Summary:        SNMP plugin for collectd
695 Group:          System Environment/Daemons
696 Requires:       %{name}%{?_isa} = %{version}-%{release}
697 BuildRequires:  net-snmp-devel
698 %description snmp
699 This plugin for collectd allows querying of network equipment using SNMP.
700 %endif
702 %if %{with_varnish}
703 %package varnish
704 Summary:        Varnish plugin for collectd
705 Group:          System Environment/Daemons
706 Requires:       %{name}%{?_isa} = %{version}-%{release}
707 BuildRequires:  varnish-libs-devel
708 %description varnish
709 The Varnish plugin collects information about Varnish, an HTTP accelerator.
710 %endif
712 %if %{with_virt}
713 %package virt
714 Summary:        Virt plugin for collectd
715 Group:          System Environment/Daemons
716 Requires:       %{name}%{?_isa} = %{version}-%{release}
717 BuildRequires:  libvirt-devel
718 %description virt
719 This plugin collects information from virtualized guests.
720 %endif
722 %if %{with_write_http}
723 %package write_http
724 Summary:        Write-HTTP plugin for collectd
725 Group:          System Environment/Daemons
726 Requires:       %{name}%{?_isa} = %{version}-%{release}
727 BuildRequires:  curl-devel
728 %description write_http
729 The Write-HTTP plugin sends the values collected by collectd to a web-server
730 using HTTP POST requests.
731 %endif
733 %if %{with_write_kafka}
734 %package write_kafka
735 Summary:       Write-kafka plugin for collectd
736 Group:         System Environment/Daemons
737 Requires:      %{name}%{?_isa} = %{version}-%{release}
738 BuildRequires: rdkafka-devel
739 %description write_kafka
740 The write_kafka plugin sends values to kafka, a distributed messaging system.
741 %endif
743 %if %{with_write_redis}
744 %package write_redis
745 Summary:        Write-Redis plugin for collectd
746 Group:          System Environment/Daemons
747 Requires:       %{name}%{?_isa} = %{version}-%{release}
748 BuildRequires:  hiredis-devel
749 %description write_redis
750 The Write Redis plugin stores values in Redis, a “data structures server”.
751 %endif
753 %if %{with_write_riemann}
754 %package write_riemann
755 Summary:        riemann plugin for collectd
756 Group:          System Environment/Daemons
757 Requires:       %{name}%{?_isa} = %{version}-%{release}
758 BuildRequires:  protobuf-c-devel
759 %description write_riemann
760 The riemann plugin submits values to Riemann, an event stream processor.
761 %endif
763 %package collection3
764 Summary:        Web-based viewer for collectd
765 Group:          System Environment/Daemons
766 Requires:       %{name}%{?_isa} = %{version}-%{release}
767 Requires: httpd
768 %description collection3
769 collection3 is a graphing front-end for the RRD files created by and filled
770 with collectd. It is written in Perl and should be run as an CGI-script.
771 Graphs are generated on-the-fly, so no cron job or similar is necessary.
773 %package php-collection
774 Summary:        collect php webfrontent
775 Group:          System Environment/Daemons
776 Requires:       collectd = %{version}-%{release}
777 Requires:       httpd
778 Requires:       php
779 Requires:       php-rrdtool
780 %description php-collection
781 PHP graphing frontend for RRD files created by and filled with collectd.
783 %package contrib
784 Summary:        Contrib files for collectd
785 Group:          System Environment/Daemons
786 Requires:       %{name}%{?_isa} = %{version}-%{release}
787 %description contrib
788 All the files found under contrib/ in the source tree are bundled in this
789 package.
791 %package -n libcollectdclient
792 Summary:        Collectd client library
793 Group:          System Environment/Daemons
794 %description -n libcollectdclient
795 Collectd client library
797 %package -n libcollectdclient-devel
798 Summary:        Development files for libcollectdclient
799 Group:          System Environment/Daemons
800 Requires:       pkgconfig
801 Requires:       libcollectdclient%{?_isa} = %{version}-%{release}
802 %description -n libcollectdclient-devel
803 Development files for libcollectdclient
806 %prep
807 %setup -q
809 %build
810 %if %{with_aggregation}
811 %define _with_aggregation --enable-aggregation
812 %else
813 %define _with_aggregation --disable-aggregation
814 %endif
816 %if %{with_amqp}
817 %define _with_amqp --enable-amqp
818 %else
819 %define _with_amqp --disable-amqp
820 %endif
822 %if %{with_apache}
823 %define _with_apache --enable-apache
824 %else
825 %define _with_apache --disable-apache
826 %endif
828 %if %{with_apcups}
829 %define _with_apcups --enable-apcups
830 %else
831 %define _with_apcups --disable-apcups
832 %endif
834 %if %{with_apple_sensors}
835 %define _with_apple_sensors --enable-apple_sensors
836 %else
837 %define _with_apple_sensors --disable-apple_sensors
838 %endif
840 %if %{with_aquaero}
841 %define _with_aquaero --enable-aquaero
842 %else
843 %define _with_aquaero --disable-aquaero
844 %endif
846 %if %{with_ascent}
847 %define _with_ascent --enable-ascent
848 %else
849 %define _with_ascent --disable-ascent
850 %endif
852 %if %{with_barometer}
853 %define _with_barometer --enable-barometer
854 %else
855 %define _with_barometer --disable-barometer
856 %endif
858 %if %{with_battery}
859 %define _with_battery --enable-battery
860 %else
861 %define _with_battery --disable-battery
862 %endif
864 %if %{with_bind}
865 %define _with_bind --enable-bind
866 %else
867 %define _with_bind --disable-bind
868 %endif
870 %if %{with_cgroups}
871 %define _with_cgroups --enable-cgroups
872 %else
873 %define _with_cgroups --disable-cgroups
874 %endif
876 %if %{with_conntrack}
877 %define _with_conntrack --enable-conntrack
878 %else
879 %define _with_conntrack --disable-conntrack
880 %endif
882 %if %{with_contextswitch}
883 %define _with_contextswitch --enable-contextswitch
884 %else
885 %define _with_contextswitch --disable-contextswitch
886 %endif
888 %if %{with_cpu}
889 %define _with_cpu --enable-cpu
890 %else
891 %define _with_cpu --disable-cpu
892 %endif
894 %if %{with_cpufreq}
895 %define _with_cpufreq --enable-cpufreq
896 %else
897 %define _with_cpufreq --disable-cpufreq
898 %endif
900 %if %{with_csv}
901 %define _with_csv --enable-csv
902 %else
903 %define _with_csv --disable-csv
904 %endif
906 %if %{with_curl}
907 %define _with_curl --enable-curl
908 %else
909 %define _with_curl --disable-curl
910 %endif
912 %if %{with_curl_json}
913 %define _with_curl_json --enable-curl_json
914 %else
915 %define _with_curl_json --disable-curl_json
916 %endif
918 %if %{with_curl_xml}
919 %define _with_curl_xml --enable-curl_xml
920 %else
921 %define _with_curl_xml --disable-curl_xml
922 %endif
924 %if %{with_dbi}
925 %define _with_dbi --enable-dbi
926 %else
927 %define _with_dbi --disable-dbi --without-libdbi
928 %endif
930 %if %{with_df}
931 %define _with_df --enable-df
932 %else
933 %define _with_df --disable-df
934 %endif
936 %if %{with_disk}
937 %define _with_disk --enable-disk
938 %else
939 %define _with_disk --disable-disk
940 %endif
942 %if %{with_dns}
943 %define _with_dns --enable-dns
944 %else
945 %define _with_dns --disable-dns
946 %endif
948 %if %{with_drbd}
949 %define _with_drbd --enable-drbd
950 %else
951 %define _with_drbd --disable-drbd
952 %endif
954 %if %{with_email}
955 %define _with_email --enable-email
956 %else
957 %define _with_email --disable-email
958 %endif
960 %if %{with_entropy}
961 %define _with_entropy --enable-entropy
962 %else
963 %define _with_entropy --disable-entropy
964 %endif
966 %if %{with_ethstat}
967 %define _with_ethstat --enable-ethstat
968 %else
969 %define _with_ethstat --disable-ethstat
970 %endif
972 %if %{with_exec}
973 %define _with_exec --enable-exec
974 %else
975 %define _with_exec --disable-exec
976 %endif
978 %if %{with_filecount}
979 %define _with_filecount --enable-filecount
980 %else
981 %define _with_filecount --disable-filecount
982 %endif
984 %if %{with_fscache}
985 %define _with_fscache --enable-fscache
986 %else
987 %define _with_fscache --disable-fscache
988 %endif
990 %if %{with_gmond}
991 %define _with_gmond --enable-gmond
992 %else
993 %define _with_gmond --disable-gmond
994 %endif
996 %if %{with_hddtemp}
997 %define _with_hddtemp --enable-hddtemp
998 %else
999 %define _with_hddtemp --disable-hddtemp
1000 %endif
1002 %if %{with_interface}
1003 %define _with_interface --enable-interface
1004 %else
1005 %define _with_interface --disable-interface
1006 %endif
1008 %if %{with_ipmi}
1009 %define _with_ipmi --enable-ipmi
1010 %else
1011 %define _with_ipmi --disable-ipmi
1012 %endif
1014 %if %{with_iptables}
1015 %define _with_iptables --enable-iptables
1016 %else
1017 %define _with_iptables --disable-iptables
1018 %endif
1020 %if %{with_ipvs}
1021 %define _with_ipvs --enable-ipvs
1022 %else
1023 %define _with_ipvs --disable-ipvs
1024 %endif
1026 %if %{with_irq}
1027 %define _with_irq --enable-irq
1028 %else
1029 %define _with_irq --disable-irq
1030 %endif
1032 %if %{with_java}
1033 %define _with_java --enable-java --with-java=%{java_home}/
1034 %else
1035 %define _with_java --disable-java
1036 %endif
1038 %if %{with_virt}
1039 %define _with_virt --enable-virt
1040 %else
1041 %define _with_virt --disable-virt
1042 %endif
1044 %if %{with_load}
1045 %define _with_load --enable-load
1046 %else
1047 %define _with_load --disable-load
1048 %endif
1050 %if %{with_logfile}
1051 %define _with_logfile --enable-logfile
1052 %else
1053 %define _with_logfile --disable-logfile
1054 %endif
1056 %if %{with_log_logstash}
1057 %define _with_log_logstash --enable-log_logstash
1058 %else
1059 %define _with_log_logstash --disable-log_logstash
1060 %endif
1062 %if %{with_lpar}
1063 %define _with_lpar --enable-lpar
1064 %else
1065 %define _with_lpar --disable-lpar
1066 %endif
1068 %if %{with_lvm}
1069 %define _with_lvm --enable-lvm
1070 %else
1071 %define _with_lvm --disable-lvm
1072 %endif
1074 %if %{with_madwifi}
1075 %define _with_madwifi --enable-madwifi
1076 %else
1077 %define _with_madwifi --disable-madwifi
1078 %endif
1080 %if %{with_mbmon}
1081 %define _with_mbmon --enable-mbmon
1082 %else
1083 %define _with_mbmon --disable-mbmon
1084 %endif
1086 %if %{with_md}
1087 %define _with_md --enable-md
1088 %else
1089 %define _with_md --disable-md
1090 %endif
1092 %if %{with_memcachec}
1093 %define _with_memcachec --enable-memcachec
1094 %else
1095 %define _with_memcachec --disable-memcachec
1096 %endif
1098 %if %{with_memcached}
1099 %define _with_memcached --enable-memcached
1100 %else
1101 %define _with_memcached --disable-memcached
1102 %endif
1104 %if %{with_memory}
1105 %define _with_memory --enable-memory
1106 %else
1107 %define _with_memory --disable-memory
1108 %endif
1110 %if %{with_mic}
1111 %define _with_mic --enable-mic
1112 %else
1113 %define _with_mic --disable-mic
1114 %endif
1116 %if %{with_modbus}
1117 %define _with_modbus --enable-modbus
1118 %else
1119 %define _with_modbus --disable-modbus
1120 %endif
1122 %if %{with_multimeter}
1123 %define _with_multimeter --enable-multimeter
1124 %else
1125 %define _with_multimeter --disable-multimeter
1126 %endif
1128 %if %{with_mysql}
1129 %define _with_mysql --enable-mysql
1130 %else
1131 %define _with_mysql --disable-mysql
1132 %endif
1134 %if %{with_netapp}
1135 %define _with_netapp --enable-netapp
1136 %else
1137 %define _with_netapp --disable-netapp
1138 %endif
1140 %if %{with_netlink}
1141 %define _with_netlink --enable-netlink
1142 %else
1143 %define _with_netlink --disable-netlink
1144 %endif
1146 %if %{with_network}
1147 %define _with_network --enable-network
1148 %else
1149 %define _with_network --disable-network
1150 %endif
1152 %if %{with_nfs}
1153 %define _with_nfs --enable-nfs
1154 %else
1155 %define _with_nfs --disable-nfs
1156 %endif
1158 %if %{with_nginx}
1159 %define _with_nginx --enable-nginx
1160 %else
1161 %define _with_nginx --disable-nginx
1162 %endif
1164 %if %{with_notify_desktop}
1165 %define _with_notify_desktop --enable-notify_desktop
1166 %else
1167 %define _with_notify_desktop --disable-notify_desktop
1168 %endif
1170 %if %{with_notify_email}
1171 %define _with_notify_email --enable-notify_email
1172 %else
1173 %define _with_notify_email --disable-notify_email --without-libesmpt
1174 %endif
1176 %if %{with_ntpd}
1177 %define _with_ntpd --enable-ntpd
1178 %else
1179 %define _with_ntpd --disable-ntpd
1180 %endif
1182 %if %{with_numa}
1183 %define _with_numa --enable-numa
1184 %else
1185 %define _with_numa --disable-numa
1186 %endif
1188 %if %{with_nut}
1189 %define _with_nut --enable-nut
1190 %else
1191 %define _with_nut --disable-nut
1192 %endif
1194 %if %{with_olsrd}
1195 %define _with_olsrd --enable-olsrd
1196 %else
1197 %define _with_olsrd --disable-olsrd
1198 %endif
1200 %if %{with_onewire}
1201 %define _with_onewire --enable-onewire
1202 %else
1203 %define _with_onewire --disable-onewire
1204 %endif
1206 %if %{with_openldap}
1207 %define _with_openldap --enable-openldap
1208 %else
1209 %define _with_openldap --disable-openldap
1210 %endif
1212 %if %{with_openvpn}
1213 %define _with_openvpn --enable-openvpn
1214 %else
1215 %define _with_openvpn --disable-openvpn
1216 %endif
1218 %if %{with_oracle}
1219 %define _with_oracle --enable-oracle
1220 %else
1221 %define _with_oracle --disable-oracle
1222 %endif
1224 %if %{with_perl}
1225 %define _with_perl --enable-perl --with-perl-bindings="INSTALLDIRS=vendor"
1226 %else
1227 %define _with_perl --disable-perl --without-libperl
1228 %endif
1230 %if %{with_pf}
1231 %define _with_pf --enable-pf
1232 %else
1233 %define _with_pf --disable-pf
1234 %endif
1236 %if %{with_pinba}
1237 %define _with_pinba --enable-pinba
1238 %else
1239 %define _with_pinba --disable-pinba
1240 %endif
1242 %if %{with_ping}
1243 %define _with_ping --enable-ping
1244 %else
1245 %define _with_ping --disable-ping
1246 %endif
1248 %if %{with_postgresql}
1249 %define _with_postgresql --enable-postgresql
1250 %else
1251 %define _with_postgresql --disable-postgresql
1252 %endif
1254 %if %{with_powerdns}
1255 %define _with_powerdns --enable-powerdns
1256 %else
1257 %define _with_powerdns --disable-powerdns
1258 %endif
1260 %if %{with_processes}
1261 %define _with_processes --enable-processes
1262 %else
1263 %define _with_processes --disable-processes
1264 %endif
1266 %if %{with_protocols}
1267 %define _with_protocols --enable-protocols
1268 %else
1269 %define _with_protocols --disable-protocols
1270 %endif
1272 %if %{with_python}
1273         %if 0%{?rhel} >= 6
1274 %define _with_python --enable-python
1275         %else
1276 %define _with_python --enable-python --with-python=%{_bindir}/python2.6
1277         %endif
1278 %else
1279 %define _with_python --disable-python
1280 %endif
1282 %if %{with_redis}
1283 %define _with_redis --enable-redis
1284 %else
1285 %define _with_redis --disable-redis
1286 %endif
1288 %if %{with_routeros}
1289 %define _with_routeros --enable-routeros
1290 %else
1291 %define _with_routeros --disable-routeros
1292 %endif
1294 %if %{with_rrdcached}
1295 %define _with_rrdcached --enable-rrdcached
1296 %else
1297 %define _with_rrdcached --disable-rrdcached
1298 %endif
1300 %if %{with_rrdtool}
1301 %define _with_rrdtool --enable-rrdtool
1302 %else
1303 %define _with_rrdtool --disable-rrdtool
1304 %endif
1306 %if %{with_sensors}
1307 %define _with_sensors --enable-sensors
1308 %else
1309 %define _with_sensors --disable-sensors
1310 %endif
1312 %if %{with_serial}
1313 %define _with_serial --enable-serial
1314 %else
1315 %define _with_serial --disable-serial
1316 %endif
1318 %if %{with_sigrok}
1319 %define _with_sigrok --enable-sigrok
1320 %else
1321 %define _with_sigrok --disable-sigrok
1322 %endif
1324 %if %{with_smart}
1325 %define _with_smart --enable-smart
1326 %else
1327 %define _with_smart --disable-smart
1328 %endif
1330 %if %{with_snmp}
1331 %define _with_snmp --enable-snmp
1332 %else
1333 %define _with_snmp --disable-snmp
1334 %endif
1336 %if %{with_statsd}
1337 %define _with_statsd --enable-statsd
1338 %else
1339 %define _with_statsd --disable-statsd
1340 %endif
1342 %if %{with_swap}
1343 %define _with_swap --enable-swap
1344 %else
1345 %define _with_swap --disable-swap
1346 %endif
1348 %if %{with_syslog}
1349 %define _with_syslog --enable-syslog
1350 %else
1351 %define _with_syslog --disable-syslog
1352 %endif
1354 %if %{with_table}
1355 %define _with_table --enable-table
1356 %else
1357 %define _with_table --disable-table
1358 %endif
1360 %if %{with_tail}
1361 %define _with_tail --enable-tail
1362 %else
1363 %define _with_tail --disable-tail
1364 %endif
1366 %if %{with_tail_csv}
1367 %define _with_tail_csv --enable-tail_csv
1368 %else
1369 %define _with_tail_csv --disable-tail_csv
1370 %endif
1372 %if %{with_tape}
1373 %define _with_tape --enable-tape
1374 %else
1375 %define _with_tape --disable-tape
1376 %endif
1378 %if %{with_tcpconns}
1379 %define _with_tcpconns --enable-tcpconns
1380 %else
1381 %define _with_tcpconns --disable-tcpconns
1382 %endif
1384 %if %{with_teamspeak2}
1385 %define _with_teamspeak2 --enable-teamspeak2
1386 %else
1387 %define _with_teamspeak2 --disable-teamspeak2
1388 %endif
1390 %if %{with_ted}
1391 %define _with_ted --enable-ted
1392 %else
1393 %define _with_ted --disable-ted
1394 %endif
1396 %if %{with_thermal}
1397 %define _with_thermal --enable-thermal
1398 %else
1399 %define _with_thermal --disable-thermal
1400 %endif
1402 %if %{with_threshold}
1403 %define _with_threshold --enable-threshold
1404 %else
1405 %define _with_threshold --disable-threshold
1406 %endif
1408 %if %{with_tokyotyrant}
1409 %define _with_tokyotyrant --enable-tokyotyrant
1410 %else
1411 %define _with_tokyotyrant --disable-tokyotyrant
1412 %endif
1414 %if %{with_unixsock}
1415 %define _with_unixsock --enable-unixsock
1416 %else
1417 %define _with_unixsock --disable-unixsock
1418 %endif
1420 %if %{with_uptime}
1421 %define _with_uptime --enable-uptime
1422 %else
1423 %define _with_uptime --disable-uptime
1424 %endif
1426 %if %{with_users}
1427 %define _with_users --enable-users
1428 %else
1429 %define _with_users --disable-users
1430 %endif
1432 %if %{with_uuid}
1433 %define _with_uuid --enable-uuid
1434 %else
1435 %define _with_uuid --disable-uuid
1436 %endif
1438 %if %{with_varnish}
1439 %define _with_varnish --enable-varnish
1440 %else
1441 %define _with_varnish --disable-varnish
1442 %endif
1444 %if %{with_vmem}
1445 %define _with_vmem --enable-vmem
1446 %else
1447 %define _with_vmem --disable-vmem
1448 %endif
1450 %if %{with_vserver}
1451 %define _with_vserver --enable-vserver
1452 %else
1453 %define _with_vserver --disable-vserver
1454 %endif
1456 %if %{with_wireless}
1457 %define _with_wireless --enable-wireless
1458 %else
1459 %define _with_wireless --disable-wireless
1460 %endif
1462 %if %{with_write_graphite}
1463 %define _with_write_graphite --enable-write_graphite
1464 %else
1465 %define _with_write_graphite --disable-write_graphite
1466 %endif
1468 %if %{with_write_http}
1469 %define _with_write_http --enable-write_http
1470 %else
1471 %define _with_write_http --disable-write_http
1472 %endif
1474 %if %{with_write_kafka}
1475 %define _with_write_kafka --enable-write_kafka
1476 %else
1477 %define _with_write_kafka --disable-write_kafka
1478 %endif
1480 %if %{with_write_mongodb}
1481 %define _with_write_mongodb --enable-write_mongodb
1482 %else
1483 %define _with_write_mongodb --disable-write_mongodb --without-libmongoc
1484 %endif
1486 %if %{with_write_redis}
1487 %define _with_write_redis --enable-write_redis
1488 %else
1489 %define _with_write_redis --disable-write_redis
1490 %endif
1492 %if %{with_write_riemann}
1493 %define _with_write_riemann --enable-write_riemann
1494 %else
1495 %define _with_write_riemann --disable-write_riemann
1496 %endif
1498 %if %{with_write_tsdb}
1499 %define _with_write_tsdb --enable-write_tsdb
1500 %else
1501 %define _with_write_tsdb --disable-write_tsdb
1502 %endif
1504 %if %{with_xmms}
1505 %define _with_xmms --enable-xmms
1506 %else
1507 %define _with_xmms --disable-xmms
1508 %endif
1510 %if %{with_zfs_arc}
1511 %define _with_zfs_arc --enable-zfs_arc
1512 %else
1513 %define _with_zfs_arc --disable-zfs_arc
1514 %endif
1516 %if %{with_zookeeper}
1517 %define _with_zookeeper --enable-zookeeper
1518 %else
1519 %define _with_zookeeper --disable-zookeeper
1520 %endif
1522 %configure CFLAGS="%{optflags} -DLT_LAZY_OR_NOW=\"RTLD_LAZY|RTLD_GLOBAL\"" \
1523         --disable-static \
1524         --without-included-ltdl \
1525         --enable-all-plugins=yes \
1526         --enable-match_empty_counter \
1527         --enable-match_hashed \
1528         --enable-match_regex \
1529         --enable-match_timediff \
1530         --enable-match_value \
1531         --enable-target_notification \
1532         --enable-target_replace \
1533         --enable-target_scale \
1534         --enable-target_set \
1535         --enable-target_v5upgrade \
1536         %{?_with_aggregation} \
1537         %{?_with_amqp} \
1538         %{?_with_apache} \
1539         %{?_with_apcups} \
1540         %{?_with_apple_sensors} \
1541         %{?_with_aquaero} \
1542         %{?_with_ascent} \
1543         %{?_with_barometer} \
1544         %{?_with_battery} \
1545         %{?_with_bind} \
1546         %{?_with_cgroups} \
1547         %{?_with_conntrack} \
1548         %{?_with_contextswitch} \
1549         %{?_with_cpu} \
1550         %{?_with_cpufreq} \
1551         %{?_with_csv} \
1552         %{?_with_curl} \
1553         %{?_with_curl_json} \
1554         %{?_with_curl_xml} \
1555         %{?_with_dbi} \
1556         %{?_with_df} \
1557         %{?_with_disk} \
1558         %{?_with_dns} \
1559         %{?_with_drbd} \
1560         %{?_with_email} \
1561         %{?_with_entropy} \
1562         %{?_with_ethstat} \
1563         %{?_with_exec} \
1564         %{?_with_filecount} \
1565         %{?_with_fscache} \
1566         %{?_with_gmond} \
1567         %{?_with_hddtemp} \
1568         %{?_with_interface} \
1569         %{?_with_ipmi} \
1570         %{?_with_iptables} \
1571         %{?_with_ipvs} \
1572         %{?_with_java} \
1573         %{?_with_virt} \
1574         %{?_with_log_logstash} \
1575         %{?_with_lpar} \
1576         %{?_with_lvm} \
1577         %{?_with_memcachec} \
1578         %{?_with_mic} \
1579         %{?_with_modbus} \
1580         %{?_with_multimeter} \
1581         %{?_with_mysql} \
1582         %{?_with_netapp} \
1583         %{?_with_netlink} \
1584         %{?_with_nginx} \
1585         %{?_with_notify_desktop} \
1586         %{?_with_notify_email} \
1587         %{?_with_nut} \
1588         %{?_with_onewire} \
1589         %{?_with_openldap} \
1590         %{?_with_oracle} \
1591         %{?_with_perl} \
1592         %{?_with_pf} \
1593         %{?_with_pinba} \
1594         %{?_with_ping} \
1595         %{?_with_postgresql} \
1596         %{?_with_python} \
1597         %{?_with_redis} \
1598         %{?_with_routeros} \
1599         %{?_with_rrdcached} \
1600         %{?_with_rrdtool} \
1601         %{?_with_sensors} \
1602         %{?_with_sigrok} \
1603         %{?_with_smart} \
1604         %{?_with_snmp} \
1605         %{?_with_tape} \
1606         %{?_with_tokyotyrant} \
1607         %{?_with_varnish} \
1608         %{?_with_write_http} \
1609         %{?_with_write_kafka} \
1610         %{?_with_write_mongodb} \
1611         %{?_with_write_redis} \
1612         %{?_with_xmms} \
1613         %{?_with_zfs_arc} \
1614         %{?_with_zookeeper} \
1615         %{?_with_irq} \
1616         %{?_with_load} \
1617         %{?_with_logfile} \
1618         %{?_with_madwifi} \
1619         %{?_with_mbmon} \
1620         %{?_with_md} \
1621         %{?_with_memcached} \
1622         %{?_with_memory} \
1623         %{?_with_network} \
1624         %{?_with_nfs} \
1625         %{?_with_ntpd} \
1626         %{?_with_numa} \
1627         %{?_with_olsrd} \
1628         %{?_with_openvpn} \
1629         %{?_with_powerdns} \
1630         %{?_with_processes} \
1631         %{?_with_protocols} \
1632         %{?_with_serial} \
1633         %{?_with_statsd} \
1634         %{?_with_swap} \
1635         %{?_with_syslog} \
1636         %{?_with_table} \
1637         %{?_with_tail} \
1638         %{?_with_tail_csv} \
1639         %{?_with_tcpconns} \
1640         %{?_with_teamspeak2} \
1641         %{?_with_ted} \
1642         %{?_with_thermal} \
1643         %{?_with_threshold} \
1644         %{?_with_unixsock} \
1645         %{?_with_uptime} \
1646         %{?_with_users} \
1647         %{?_with_uuid} \
1648         %{?_with_vmem} \
1649         %{?_with_vserver} \
1650         %{?_with_wireless}\
1651         %{?_with_write_graphite} \
1652         %{?_with_write_http} \
1653         %{?_with_write_riemann} \
1654         %{?_with_write_tsdb}
1657 %{__make} %{?_smp_mflags}
1660 %install
1661 rm -rf %{buildroot}
1662 %{__make} install DESTDIR=%{buildroot}
1663 %if 0%{?el7:1}
1664 %{__install} -Dp -m0644 contrib/systemd.collectd.service %{buildroot}%{_unitdir}/collectd.service
1665 %else
1666         %if 0%{?el6:1}
1667 %{__install} -Dp -m0644 contrib/upstart.collectd.conf %{buildroot}%{_sysconfdir}/init/collectd.conf
1668         %else
1669 %{__install} -Dp -m0755 contrib/redhat/init.d-collectd %{buildroot}%{_initrddir}/collectd
1670         %endif
1671 %endif
1672 %{__install} -Dp -m0644 src/collectd.conf %{buildroot}%{_sysconfdir}/collectd.conf
1673 %{__install} -d %{buildroot}%{_sharedstatedir}/collectd/
1674 %{__install} -d %{buildroot}%{_sysconfdir}/collectd.d/
1676 %{__mkdir} -p %{buildroot}%{_localstatedir}/www
1677 %{__mkdir} -p %{buildroot}/%{_sysconfdir}/httpd/conf.d
1679 %{__cp} -a contrib/collection3 %{buildroot}%{_localstatedir}/www
1680 %{__cp} -a contrib/redhat/collection3.conf %{buildroot}/%{_sysconfdir}/httpd/conf.d/
1682 %{__cp} -a contrib/php-collection %{buildroot}%{_localstatedir}/www
1683 %{__cp} -a contrib/redhat/php-collection.conf %{buildroot}/%{_sysconfdir}/httpd/conf.d/
1685 ### Clean up docs
1686 find contrib/ -type f -exec %{__chmod} a-x {} \;
1687 # *.la files shouldn't be distributed.
1688 rm -f %{buildroot}/%{_libdir}/{collectd/,}*.la
1690 # Move the Perl examples to a separate directory.
1691 mkdir perl-examples
1692 find contrib -name '*.p[lm]' -exec mv {} perl-examples/ \;
1694 # Remove Perl hidden .packlist files.
1695 find %{buildroot} -type f -name .packlist -delete
1696 # Remove Perl temporary file perllocal.pod
1697 find %{buildroot} -type f -name perllocal.pod -delete
1699 %if ! %{with_java}
1700 rm -f %{buildroot}%{_mandir}/man5/collectd-java.5*
1701 %endif
1703 %if ! %{with_perl}
1704 rm -f %{buildroot}%{_mandir}/man5/collectd-perl.5*
1705 rm -f %{buildroot}%{_mandir}/man3/Collectd::Unixsock.3pm*
1706 rm -fr perl-examples/
1707 rm -fr %{buildroot}/usr/lib/perl5/
1708 %endif
1710 %if ! %{with_python}
1711 rm -f %{buildroot}%{_mandir}/man5/collectd-python.5*
1712 %endif
1714 %if ! %{with_snmp}
1715 rm -f %{buildroot}%{_mandir}/man5/collectd-snmp.5*
1716 %endif
1719 %clean
1720 rm -rf %{buildroot}
1722 %pre
1723 %if 0%{?el7:1}%{?el6:1}
1724 # stop sysv-based instance before upgrading to upstart/systemd
1725 if [ $1 -eq 2 ] && [ -f /var/lock/subsys/collectd ]; then
1726         SYSTEMCTL_SKIP_REDIRECT=1 %{_initddir}/collectd stop >/dev/null 2>&1 || :
1727 fi
1728 %endif
1730 %post
1731 %if 0%{?el7:1}
1732 if [ $1 -eq 2 ]; then
1733         /usr/bin/systemctl daemon-reload >/dev/null 2>&1 || :
1734 fi
1735 %systemd_post collectd.service
1736 %else
1737         %if 0%{!?el6:1}
1738 /sbin/chkconfig --add collectd || :
1739         %endif
1740 %endif
1742 %preun
1743 %if 0%{?el7:1}
1744 %systemd_preun collectd.service
1745 %else
1746 # stop collectd only when uninstalling
1747 if [ $1 -eq 0 ]; then
1748         %if 0%{?el6:1}
1749         /sbin/initctl stop collectd >/dev/null 2>&1 || :
1750         %else
1751         /sbin/service collectd stop >/dev/null 2>&1 || :
1752         /sbin/chkconfig --del collectd || :
1753         %endif
1754 fi
1755 %endif
1757 %postun
1758 %if 0%{?el7:1}
1759 %systemd_postun_with_restart collectd.service
1760 %else
1761 # restart collectd only when upgrading
1762 if [ $1 -eq 1 ]; then
1763         %if 0%{?el6:1}
1764         if /sbin/initctl status collectd 2>/dev/null | grep -q 'running'; then
1765                 /sbin/initctl restart collectd >/dev/null 2>&1 || :
1766         else
1767                 /sbin/initctl start collectd >/dev/null 2>&1 || :
1768         fi
1769         %else
1770         /sbin/service collectd condrestart >/dev/null 2>&1 || :
1771         %endif
1772 fi
1773 %endif
1775 %post -n libcollectdclient -p /sbin/ldconfig
1776 %postun -n libcollectdclient -p /sbin/ldconfig
1779 %files
1780 %doc AUTHORS COPYING ChangeLog README
1781 %config(noreplace) %{_sysconfdir}/collectd.conf
1782 %if 0%{?el7:1}
1783 %{_unitdir}/collectd.service
1784 %else
1785         %if 0%{?el6:1}
1786 %{_sysconfdir}/init/collectd.conf
1787         %else
1788 %{_initrddir}/collectd
1789         %endif
1790 %endif
1791 %{_sbindir}/collectd
1792 %{_bindir}/collectd-nagios
1793 %{_bindir}/collectd-tg
1794 %{_bindir}/collectdctl
1795 %{_sbindir}/collectdmon
1796 %{_datadir}/collectd/
1797 %{_sharedstatedir}/collectd
1798 %{_mandir}/man1/collectd-nagios.1*
1799 %{_mandir}/man1/collectd.1*
1800 %{_mandir}/man1/collectdctl.1*
1801 %{_mandir}/man1/collectdmon.1*
1802 %{_mandir}/man1/collectd-tg.1*
1803 %{_mandir}/man5/collectd-email.5*
1804 %{_mandir}/man5/collectd-exec.5*
1805 %{_mandir}/man5/collectd-threshold.5*
1806 %{_mandir}/man5/collectd-unixsock.5*
1807 %{_mandir}/man5/collectd.conf.5*
1808 %{_mandir}/man5/types.db.5*
1810 # all plugins bundled with the main collectd package
1811 %{_libdir}/%{name}/match_empty_counter.so
1812 %{_libdir}/%{name}/match_hashed.so
1813 %{_libdir}/%{name}/match_regex.so
1814 %{_libdir}/%{name}/match_timediff.so
1815 %{_libdir}/%{name}/match_value.so
1816 %{_libdir}/%{name}/target_notification.so
1817 %{_libdir}/%{name}/target_replace.so
1818 %{_libdir}/%{name}/target_scale.so
1819 %{_libdir}/%{name}/target_set.so
1820 %{_libdir}/%{name}/target_v5upgrade.so
1822 %if %{with_aggregation}
1823 %{_libdir}/%{name}/aggregation.so
1824 %endif
1825 %if %{with_apcups}
1826 %{_libdir}/%{name}/apcups.so
1827 %endif
1828 %if %{with_battery}
1829 %{_libdir}/%{name}/battery.so
1830 %endif
1831 %if %{with_cgroups}
1832 %{_libdir}/%{name}/cgroups.so
1833 %endif
1834 %if %{with_conntrack}
1835 %{_libdir}/%{name}/conntrack.so
1836 %endif
1837 %if %{with_contextswitch}
1838 %{_libdir}/%{name}/contextswitch.so
1839 %endif
1840 %if %{with_cpu}
1841 %{_libdir}/%{name}/cpu.so
1842 %endif
1843 %if %{with_cpufreq}
1844 %{_libdir}/%{name}/cpufreq.so
1845 %endif
1846 %if %{with_csv}
1847 %{_libdir}/%{name}/csv.so
1848 %endif
1849 %if %{with_df}
1850 %{_libdir}/%{name}/df.so
1851 %endif
1852 %if %{with_drbd}
1853 %{_libdir}/%{name}/drbd.so
1854 %endif
1855 %if %{with_ethstat}
1856 %{_libdir}/%{name}/ethstat.so
1857 %endif
1858 %if %{with_entropy}
1859 %{_libdir}/%{name}/entropy.so
1860 %endif
1861 %if %{with_exec}
1862 %{_libdir}/%{name}/exec.so
1863 %endif
1864 %if %{with_filecount}
1865 %{_libdir}/%{name}/filecount.so
1866 %endif
1867 %if %{with_fscache}
1868 %{_libdir}/%{name}/fscache.so
1869 %endif
1870 %if %{with_interface}
1871 %{_libdir}/%{name}/interface.so
1872 %endif
1873 %if %{with_ipvs}
1874 %{_libdir}/%{name}/ipvs.so
1875 %endif
1876 %if %{with_irq}
1877 %{_libdir}/%{name}/irq.so
1878 %endif
1879 %if %{with_load}
1880 %{_libdir}/%{name}/load.so
1881 %endif
1882 %if %{with_logfile}
1883 %{_libdir}/%{name}/logfile.so
1884 %endif
1885 %if %{with_madwifi}
1886 %{_libdir}/%{name}/madwifi.so
1887 %endif
1888 %if %{with_mbmon}
1889 %{_libdir}/%{name}/mbmon.so
1890 %endif
1891 %if %{with_md}
1892 %{_libdir}/%{name}/md.so
1893 %endif
1894 %if %{with_memcached}
1895 %{_libdir}/%{name}/memcached.so
1896 %endif
1897 %if %{with_memory}
1898 %{_libdir}/%{name}/memory.so
1899 %endif
1900 %if %{with_multimeter}
1901 %{_libdir}/%{name}/multimeter.so
1902 %endif
1903 %if %{with_network}
1904 %{_libdir}/%{name}/network.so
1905 %endif
1906 %if %{with_nfs}
1907 %{_libdir}/%{name}/nfs.so
1908 %endif
1909 %if %{with_ntpd}
1910 %{_libdir}/%{name}/ntpd.so
1911 %endif
1912 %if %{with_numa}
1913 %{_libdir}/%{name}/numa.so
1914 %endif
1915 %if %{with_openvpn}
1916 %{_libdir}/%{name}/openvpn.so
1917 %endif
1918 %if %{with_olsrd}
1919 %{_libdir}/%{name}/olsrd.so
1920 %endif
1921 %if %{with_powerdns}
1922 %{_libdir}/%{name}/powerdns.so
1923 %endif
1924 %if %{with_processes}
1925 %{_libdir}/%{name}/processes.so
1926 %endif
1927 %if %{with_protocols}
1928 %{_libdir}/%{name}/protocols.so
1929 %endif
1930 %if %{with_serial}
1931 %{_libdir}/%{name}/serial.so
1932 %endif
1933 %if %{with_statsd}
1934 %{_libdir}/%{name}/statsd.so
1935 %endif
1936 %if %{with_swap}
1937 %{_libdir}/%{name}/swap.so
1938 %endif
1939 %if %{with_syslog}
1940 %{_libdir}/%{name}/syslog.so
1941 %endif
1942 %if %{with_table}
1943 %{_libdir}/%{name}/table.so
1944 %endif
1945 %if %{with_tail}
1946 %{_libdir}/%{name}/tail.so
1947 %endif
1948 %if %{with_tail_csv}
1949 %{_libdir}/%{name}/tail_csv.so
1950 %endif
1951 %if %{with_tcpconns}
1952 %{_libdir}/%{name}/tcpconns.so
1953 %endif
1954 %if %{with_teamspeak2}
1955 %{_libdir}/%{name}/teamspeak2.so
1956 %endif
1957 %if %{with_ted}
1958 %{_libdir}/%{name}/ted.so
1959 %endif
1960 %if %{with_thermal}
1961 %{_libdir}/%{name}/thermal.so
1962 %endif
1963 %if %{with_load}
1964 %{_libdir}/%{name}/threshold.so
1965 %endif
1966 %if %{with_unixsock}
1967 %{_libdir}/%{name}/unixsock.so
1968 %endif
1969 %if %{with_uptime}
1970 %{_libdir}/%{name}/uptime.so
1971 %endif
1972 %if %{with_users}
1973 %{_libdir}/%{name}/users.so
1974 %endif
1975 %if %{with_uuid}
1976 %{_libdir}/%{name}/uuid.so
1977 %endif
1978 %if %{with_vmem}
1979 %{_libdir}/%{name}/vmem.so
1980 %endif
1981 %if %{with_vserver}
1982 %{_libdir}/%{name}/vserver.so
1983 %endif
1984 %if %{with_wireless}
1985 %{_libdir}/%{name}/wireless.so
1986 %endif
1987 %if %{with_write_graphite}
1988 %{_libdir}/%{name}/write_graphite.so
1989 %endif
1990 %if %{with_write_tsdb}
1991 %{_libdir}/%{name}/write_tsdb.so
1992 %endif
1993 %if %{with_zfs_arc}
1994 %{_libdir}/%{name}/zfs_arc.so
1995 %endif
1996 %if %{with_zookeeper}
1997 %{_libdir}/%{name}/zookeeper.so
1998 %endif
2000 %files -n libcollectdclient-devel
2001 %{_includedir}/collectd/client.h
2002 %{_includedir}/collectd/network.h
2003 %{_includedir}/collectd/network_buffer.h
2004 %{_includedir}/collectd/lcc_features.h
2005 %{_libdir}/pkgconfig/libcollectdclient.pc
2007 %files -n libcollectdclient
2008 %{_libdir}/libcollectdclient.so
2009 %{_libdir}/libcollectdclient.so.*
2011 %if %{with_amqp}
2012 %files amqp
2013 %{_libdir}/%{name}/amqp.so
2014 %endif
2016 %if %{with_apache}
2017 %files apache
2018 %{_libdir}/%{name}/apache.so
2019 %endif
2021 %if %{with_aquaero}
2022 %files aquaero
2023 %{_libdir}/%{name}/aquaero.so
2024 %endif
2026 %if %{with_ascent}
2027 %files ascent
2028 %{_libdir}/%{name}/ascent.so
2029 %endif
2031 %if %{with_barometer}
2032 %files barometer
2033 %{_libdir}/%{name}/barometer.so
2034 %endif
2036 %if %{with_bind}
2037 %files bind
2038 %{_libdir}/%{name}/bind.so
2039 %endif
2041 %if %{with_curl}
2042 %files curl
2043 %{_libdir}/%{name}/curl.so
2044 %endif
2046 %if %{with_curl_json}
2047 %files curl_json
2048 %{_libdir}/%{name}/curl_json.so
2049 %endif
2051 %if %{with_curl_xml}
2052 %files curl_xml
2053 %{_libdir}/%{name}/curl_xml.so
2054 %endif
2056 %if %{with_disk}
2057 %files disk
2058 %{_libdir}/%{name}/disk.so
2059 %endif
2061 %if %{with_dns}
2062 %files dns
2063 %{_libdir}/%{name}/dns.so
2064 %endif
2066 %if %{with_dbi}
2067 %files dbi
2068 %{_libdir}/%{name}/dbi.so
2069 %endif
2071 %if %{with_email}
2072 %files email
2073 %{_libdir}/%{name}/email.so
2074 %endif
2076 %if %{with_gmond}
2077 %files gmond
2078 %{_libdir}/%{name}/gmond.so
2079 %endif
2081 %if %{with_hddtemp}
2082 %files hddtemp
2083 %{_libdir}/%{name}/hddtemp.so
2084 %endif
2086 %if %{with_ipmi}
2087 %files ipmi
2088 %{_libdir}/%{name}/ipmi.so
2089 %endif
2091 %if %{with_iptables}
2092 %files iptables
2093 %{_libdir}/%{name}/iptables.so
2094 %endif
2096 %if %{with_java}
2097 %files java
2098 %{_prefix}/share/collectd/java/collectd-api.jar
2099 %{_prefix}/share/collectd/java/generic-jmx.jar
2100 %{_libdir}/%{name}/java.so
2101 %{_mandir}/man5/collectd-java.5*
2102 %endif
2104 %if %{with_virt}
2105 %files virt
2106 %{_libdir}/%{name}/virt.so
2107 %endif
2109 %if %{with_log_logstash}
2110 %files log_logstash
2111 %{_libdir}/%{name}/log_logstash.so
2112 %endif
2114 %if %{with_lvm}
2115 %files lvm
2116 %{_libdir}/%{name}/lvm.so
2117 %endif
2119 %if %{with_memcachec}
2120 %files memcachec
2121 %{_libdir}/%{name}/memcachec.so
2122 %endif
2124 %if %{with_mic}
2125 %files mic
2126 %{_libdir}/%{name}/mic.so
2127 %endif
2129 %if %{with_modbus}
2130 %files modbus
2131 %{_libdir}/%{name}/modbus.so
2132 %endif
2134 %if %{with_mysql}
2135 %files mysql
2136 %{_libdir}/%{name}/mysql.so
2137 %endif
2139 %if %{with_netlink}
2140 %files netlink
2141 %{_libdir}/%{name}/netlink.so
2142 %endif
2144 %if %{with_nginx}
2145 %files nginx
2146 %{_libdir}/%{name}/nginx.so
2147 %endif
2149 %if %{with_notify_desktop}
2150 %files notify_desktop
2151 %{_libdir}/%{name}/notify_desktop.so
2152 %endif
2154 %if %{with_notify_email}
2155 %files notify_email
2156 %{_libdir}/%{name}/notify_email.so
2157 %endif
2159 %if %{with_nut}
2160 %files nut
2161 %{_libdir}/%{name}/nut.so
2162 %endif
2164 %if %{with_openldap}
2165 %files openldap
2166 %{_libdir}/%{name}/openldap.so
2167 %endif
2169 %if %{with_perl}
2170 %files perl
2171 %doc perl-examples/*
2172 %{perl_vendorlib}/Collectd.pm
2173 %{perl_vendorlib}/Collectd/
2174 %{_mandir}/man3/Collectd::Unixsock.3pm*
2175 %{_mandir}/man5/collectd-perl.5*
2176 %{_libdir}/%{name}/perl.so
2177 %endif
2179 %if %{with_pinba}
2180 %files pinba
2181 %{_libdir}/%{name}/pinba.so
2182 %endif
2184 %if %{with_ping}
2185 %files ping
2186 %{_libdir}/%{name}/ping.so
2187 %endif
2189 %if %{with_postgresql}
2190 %files postgresql
2191 %{_prefix}/share/collectd/postgresql_default.conf
2192 %{_libdir}/%{name}/postgresql.so
2193 %endif
2195 %if %{with_python}
2196 %files python
2197 %{_mandir}/man5/collectd-python*
2198 %{_libdir}/%{name}/python.so
2199 %endif
2201 %if %{with_redis}
2202 %files redis
2203 %{_libdir}/%{name}/redis.so
2204 %endif
2206 %if %{with_rrdcached}
2207 %files rrdcached
2208 %{_libdir}/%{name}/rrdcached.so
2209 %endif
2211 %if %{with_rrdtool}
2212 %files rrdtool
2213 %{_libdir}/%{name}/rrdtool.so
2214 %endif
2216 %if %{with_sensors}
2217 %files sensors
2218 %{_libdir}/%{name}/sensors.so
2219 %endif
2221 %if %{with_sigrok}
2222 %files sigrok
2223 %{_libdir}/%{name}/sigrok.so
2224 %endif
2226 %if %{with_smart}
2227 %files smart
2228 %{_libdir}/%{name}/smart.so
2229 %endif
2231 %if %{with_snmp}
2232 %files snmp
2233 %{_mandir}/man5/collectd-snmp.5*
2234 %{_libdir}/%{name}/snmp.so
2235 %endif
2237 %if %{with_varnish}
2238 %files varnish
2239 %{_libdir}/%{name}/varnish.so
2240 %endif
2242 %if %{with_write_http}
2243 %files write_http
2244 %{_libdir}/%{name}/write_http.so
2245 %endif
2247 %if %{with_write_kafka}
2248 %files write_kafka
2249 %{_libdir}/%{name}/write_kafka.so
2250 %endif
2252 %if %{with_write_redis}
2253 %files write_redis
2254 %{_libdir}/%{name}/write_redis.so
2255 %endif
2257 %if %{with_write_riemann}
2258 %files write_riemann
2259 %{_libdir}/%{name}/write_riemann.so
2260 %endif
2262 %files collection3
2263 %{_localstatedir}/www/collection3
2264 %{_sysconfdir}/httpd/conf.d/collection3.conf
2266 %files php-collection
2267 %{_localstatedir}/www/php-collection
2268 %{_sysconfdir}/httpd/conf.d/php-collection.conf
2270 %files contrib
2271 %doc contrib/
2273 %changelog
2274 # * TODO 5.5.0-1
2275 # - New upstream version
2276 # - New plugins enabled by default: drbd, log_logstash, write_tsdb, smart, openldap, redis, write_redis, zookeeper
2277 # - New plugins disabled by default: barometer, write_kafka
2278 # - Enable zfs_arc, now supported on Linux
2279 # - Install disk plugin in an dedicated package, as it depends on libudev
2281 * Mon Aug 19 2013 Marc Fournier <marc.fournier@camptocamp.com> 5.4.0-1
2282 - New upstream version
2283 - Build netlink plugin by default
2284 - Enable cgroups, lvm and statsd plugins
2285 - Enable (but don't build by default) mic, aquaero and sigrok plugins
2287 * Tue Aug 06 2013 Marc Fournier <marc.fournier@camptocamp.com> 5.3.1-1
2288 - New upstream version
2289 - Added RHEL5 support:
2290   * conditionally disable plugins not building on this platform
2291   * add/specify some build dependencies and options
2292   * replace some RPM macros not available on this platform
2293 - Removed duplicate --enable-aggregation
2294 - Added some comments & usage examples
2295 - Replaced a couple of "Buildrequires" by "BuildRequires"
2296 - Enabled modbus plugin on RHEL6
2297 - Enabled netlink plugin on RHEL6 and RHEL7
2298 - Allow perl plugin to build on RHEL5
2299 - Add support for RHEL7
2301 * Wed Apr 10 2013 Marc Fournier <marc.fournier@camptocamp.com> 5.3.0-1
2302 - New upstream version
2303 - Enabled write_riemann plugin
2304 - Enabled tail_csv plugin
2305 - Installed collectd-tc manpage
2307 * Fri Jan 11 2013 Marc Fournier <marc.fournier@camptocamp.com> 5.2.0-3
2308 - remove dependency on libstatgrab, which isn't required on linux
2310 * Thu Jan 03 2013 Marc Fournier <marc.fournier@camptocamp.com> 5.2.0-2
2311 - collection3 and php-collection viewers are now in separate packages
2313 * Fri Dec 21 2012 Marc Fournier <marc.fournier@camptocamp.com> 5.2.0-1
2314 - New upstream version
2315 - Enabled aggregation plugin
2316 - Installed collectd-tc
2317 - Added network.h and network_buffer.h to libcollectdclient-devel
2318 - Moved libxml2-devel and libcurl-devel BRs to relevant plugins sections
2319 - Moved libcollectdclient.so from libcollectdclient-devel to libcollectdclient
2320 - Added rrdcached and redis plugin descriptions
2321 - Mentioned new pf plugin in disabled plugins list
2323 * Sun Nov 18 2012 Ruben Kerkhof <ruben@tilaa.nl> 5.1.0-3
2324 - Follow Fedora Packaging Guidelines in java subpackage
2326 * Sat Nov 17 2012 Ruben Kerkhof <ruben@tilaa.nl> 5.1.0-2
2327 - Move perl stuff to perl_vendorlib
2328 - Replace hardcoded paths with macros
2329 - Remove unnecessary Requires
2330 - Removed .a and .la files
2331 - Some other small cleanups
2333 * Fri Nov 16 2012 Marc Fournier <marc.fournier@camptocamp.com> 5.1.0-1
2334 - New upstream version
2335 - Changes to support 5.1.0
2336 - Enabled all buildable plugins based on libraries available on EL6 + EPEL
2337 - All plugins requiring external libraries are now shipped in separate
2338   packages.
2339 - No longer treat Java plugin as an exception, correctly set $JAVA_HOME during
2340   the build process + ensure build deps are installed.
2341 - Dropped per-plugin configuration files, as they tend to diverge from upstream
2342   defaults.
2343 - Moved perl stuff to /usr/share/perl5/
2344 - Don't alter Interval and ReadThreads by default, let the user change this
2345   himself.
2346 - Initscript improvements:
2347   * checks configuration before (re)starting, based on debian's initscript
2348   * use /etc/sysconfig instdead of /etc/default
2349   * include optional $ARGS in arguments passed to collectd.
2350 - Drop collection.cgi from main package, as it's been obsoleted by collection3
2351 - Moved contrib/ to its own package, to avoid cluttering the main package with
2352   non-essential stuff.
2353 - Replaced BuildPrereq by BuildRequires
2355 * Mon Jan 03 2011 Monetate <jason.stelzer@monetate.com> 5.0.1
2356 - New upstream version
2357 - Changes to support 5.0.1
2359 * Mon Jan 04 2010 Rackspace <stu.hood@rackspace.com> 4.9.0
2360 - New upstream version
2361 - Changes to support 4.9.0
2362 - Added support for Java/GenericJMX plugin
2364 * Mon Mar 17 2008 RightScale <support@rightscale.com> 4.3.1
2365 - New upstream version
2366 - Changes to support 4.3.1
2367 - Added More Prereqs to support more plugins
2368 - Added support for perl plugin
2370 * Mon Aug 06 2007 Kjell Randa <Kjell.Randa@broadpark.no> 4.0.6
2371 - New upstream version
2373 * Wed Jul 25 2007 Kjell Randa <Kjell.Randa@broadpark.no> 4.0.5
2374 - New major releas
2375 - Changes to support 4.0.5
2377 * Thu Jan 11 2007 Iain Lea <iain@bricbrac.de> 3.11.0-0
2378 - fixed spec file to build correctly on fedora core
2379 - added improved init.d script to work with chkconfig
2380 - added %%post and %%postun to call chkconfig automatically
2382 * Sun Jul 09 2006 Florian octo Forster <octo@verplant.org> 3.10.0-1
2383 - New upstream version
2385 * Sun Jun 25 2006 Florian octo Forster <octo@verplant.org> 3.9.4-1
2386 - New upstream version
2388 * Thu Jun 01 2006 Florian octo Forster <octo@verplant.org> 3.9.3-1
2389 - New upstream version
2391 * Tue May 09 2006 Florian octo Forster <octo@verplant.org> 3.9.2-1
2392 - New upstream version
2394 * Tue May 09 2006 Florian octo Forster <octo@verplant.org> 3.8.5-1
2395 - New upstream version
2397 * Fri Apr 21 2006 Florian octo Forster <octo@verplant.org> 3.9.1-1
2398 - New upstream version
2400 * Fri Apr 14 2006 Florian octo Forster <octo@verplant.org> 3.9.0-1
2401 - New upstream version
2402 - Added the `apache' package.
2404 * Tue Mar 14 2006 Florian octo Forster <octo@verplant.org> 3.8.2-1
2405 - New upstream version
2407 * Mon Mar 13 2006 Florian octo Forster <octo@verplant.org> 3.8.1-1
2408 - New upstream version
2410 * Thu Mar 09 2006 Florian octo Forster <octo@verplant.org> 3.8.0-1
2411 - New upstream version
2413 * Sat Feb 18 2006 Florian octo Forster <octo@verplant.org> 3.7.2-1
2414 - Include `tape.so' so the build doesn't terminate because of missing files..
2415 - New upstream version
2417 * Sat Feb 04 2006 Florian octo Forster <octo@verplant.org> 3.7.1-1
2418 - New upstream version
2420 * Mon Jan 30 2006 Florian octo Forster <octo@verplant.org> 3.7.0-1
2421 - New upstream version
2422 - Removed the extra `hddtemp' package
2424 * Tue Jan 24 2006 Florian octo Forster <octo@verplant.org> 3.6.2-1
2425 - New upstream version
2427 * Fri Jan 20 2006 Florian octo Forster <octo@verplant.org> 3.6.1-1
2428 - New upstream version
2430 * Fri Jan 20 2006 Florian octo Forster <octo@verplant.org> 3.6.0-1
2431 - New upstream version
2432 - Added config file, `collectd.conf(5)', `df.so'
2433 - Added package `collectd-mysql', dependency on `mysqlclient10 | mysql'
2435 * Wed Dec 07 2005 Florian octo Forster <octo@verplant.org> 3.5.0-1
2436 - New upstream version
2438 * Sat Nov 26 2005 Florian octo Forster <octo@verplant.org> 3.4.0-1
2439 - New upstream version
2441 * Sat Nov 05 2005 Florian octo Forster <octo@verplant.org> 3.3.0-1
2442 - New upstream version
2444 * Wed Oct 26 2005 Florian octo Forster <octo@verplant.org> 3.2.0-1
2445 - New upstream version
2446 - Added statement to remove the `*.la' files. This fixes a problem when
2447   `Unpackaged files terminate build' is in effect.
2448 - Added `processes.so*' to the main package
2450 * Fri Oct 14 2005 Florian octo Forster <octo@verplant.org> 3.1.0-1
2451 - New upstream version
2452 - Added package `collectd-hddtemp'
2454 * Fri Sep 30 2005 Florian octo Forster <octo@verplant.org> 3.0.0-1
2455 - New upstream version
2456 - Split the package into `collectd' and `collectd-sensors'
2458 * Fri Sep 16 2005 Florian octo Forster <octo@verplant.org> 2.1.0-1
2459 - New upstream version
2461 * Sat Sep 10 2005 Florian octo Forster <octo@verplant.org> 2.0.0-1
2462 - New upstream version
2464 * Mon Aug 29 2005 Florian octo Forster <octo@verplant.org> 1.8.0-1
2465 - New upstream version
2467 * Thu Aug 25 2005 Florian octo Forster <octo@verplant.org> 1.7.0-1
2468 - New upstream version
2470 * Sun Aug 21 2005 Florian octo Forster <octo@verplant.org> 1.6.0-1
2471 - New upstream version
2473 * Sun Jul 17 2005 Florian octo Forster <octo@verplant.org> 1.5.1-1
2474 - New upstream version
2476 * Sun Jul 17 2005 Florian octo Forster <octo@verplant.org> 1.5-1
2477 - New upstream version
2479 * Mon Jul 11 2005 Florian octo Forster <octo@verplant.org> 1.4.2-1
2480 - New upstream version
2482 * Sat Jul 09 2005 Florian octo Forster <octo@verplant.org> 1.4-1
2483 - Built on RedHat 7.3