Lines 1-14
Link Here
|
1 |
# Copyright 1999-2014 Gentoo Foundation |
1 |
# Copyright 1999-2015 Gentoo Foundation |
2 |
# Distributed under the terms of the GNU General Public License v2 |
2 |
# Distributed under the terms of the GNU General Public License v2 |
3 |
# $Id$ |
3 |
# $Id$ |
4 |
|
4 |
|
5 |
EAPI="5" |
5 |
EAPI="5" |
6 |
|
6 |
|
7 |
GENTOO_DEPEND_ON_PERL="no" |
7 |
GENTOO_DEPEND_ON_PERL="no" |
|
|
8 |
JAVA_PKG_OPT_USE="collectd_plugins_java" |
8 |
# XXX: 5.4.1-r0 stated 2* but it builds fine against 3.4 |
9 |
# XXX: 5.4.1-r0 stated 2* but it builds fine against 3.4 |
9 |
PYTHON_COMPAT=( python2_7 ) |
10 |
PYTHON_COMPAT=( python2_7 ) |
10 |
|
11 |
|
11 |
inherit autotools base eutils linux-info multilib perl-app python-single-r1 systemd user |
12 |
inherit autotools base eutils java-pkg-opt-2 linux-info multilib perl-app python-single-r1 systemd user |
12 |
|
13 |
|
13 |
DESCRIPTION="A a daemon which collects system statistic and provides mechanisms to store the values" |
14 |
DESCRIPTION="A a daemon which collects system statistic and provides mechanisms to store the values" |
14 |
|
15 |
|
Lines 69-75
Link Here
|
69 |
collectd_plugins_gmond? ( sys-cluster/ganglia ) |
70 |
collectd_plugins_gmond? ( sys-cluster/ganglia ) |
70 |
collectd_plugins_ipmi? ( >=sys-libs/openipmi-2.0.16-r1 ) |
71 |
collectd_plugins_ipmi? ( >=sys-libs/openipmi-2.0.16-r1 ) |
71 |
collectd_plugins_iptables? ( >=net-firewall/iptables-1.4.13 ) |
72 |
collectd_plugins_iptables? ( >=net-firewall/iptables-1.4.13 ) |
72 |
collectd_plugins_java? ( virtual/jre dev-java/java-config-wrapper ) |
|
|
73 |
collectd_plugins_libvirt? ( app-emulation/libvirt dev-libs/libxml2 ) |
73 |
collectd_plugins_libvirt? ( app-emulation/libvirt dev-libs/libxml2 ) |
74 |
collectd_plugins_lvm? ( sys-fs/lvm2 ) |
74 |
collectd_plugins_lvm? ( sys-fs/lvm2 ) |
75 |
collectd_plugins_memcachec? ( dev-libs/libmemcached ) |
75 |
collectd_plugins_memcachec? ( dev-libs/libmemcached ) |
Lines 106-116
Link Here
|
106 |
|
106 |
|
107 |
DEPEND="${COMMON_DEPEND} |
107 |
DEPEND="${COMMON_DEPEND} |
108 |
virtual/pkgconfig |
108 |
virtual/pkgconfig |
|
|
109 |
collectd_plugins_java? ( >=virtual/jdk-1.6 ) |
109 |
kernel_linux? ( |
110 |
kernel_linux? ( |
110 |
collectd_plugins_vserver? ( sys-kernel/vserver-sources ) |
111 |
collectd_plugins_vserver? ( sys-kernel/vserver-sources ) |
111 |
)" |
112 |
)" |
112 |
|
113 |
|
113 |
RDEPEND="${COMMON_DEPEND} |
114 |
RDEPEND="${COMMON_DEPEND} |
|
|
115 |
collectd_plugins_java? ( >=virtual/jre-1.6 ) |
114 |
collectd_plugins_syslog? ( virtual/logger ) |
116 |
collectd_plugins_syslog? ( virtual/logger ) |
115 |
selinux? ( sec-policy/selinux-collectd )" |
117 |
selinux? ( sec-policy/selinux-collectd )" |
116 |
|
118 |
|
Lines 204-209
Link Here
|
204 |
fi |
206 |
fi |
205 |
fi |
207 |
fi |
206 |
|
208 |
|
|
|
209 |
java-pkg-opt-2_pkg_setup |
207 |
use collectd_plugins_python && python-single-r1_pkg_setup |
210 |
use collectd_plugins_python && python-single-r1_pkg_setup |
208 |
|
211 |
|
209 |
enewgroup collectd |
212 |
enewgroup collectd |
Lines 222-227
Link Here
|
222 |
# fix installdirs for perl, bug 444360 |
225 |
# fix installdirs for perl, bug 444360 |
223 |
sed -i -e 's/INSTALL_BASE=$(DESTDIR)$(prefix) //' bindings/Makefile.am || die |
226 |
sed -i -e 's/INSTALL_BASE=$(DESTDIR)$(prefix) //' bindings/Makefile.am || die |
224 |
|
227 |
|
|
|
228 |
if use collectd_plugins_java; then |
229 |
# Set javac -source and -target flags according to (R)DEPEND. |
230 |
sed -i -e "s/\$(JAVAC)/\0 $(java-pkg_javac-args)/g" bindings/java/Makefile.am || die |
231 |
fi |
232 |
|
225 |
rm -r libltdl || die |
233 |
rm -r libltdl || die |
226 |
|
234 |
|
227 |
eautoreconf |
235 |
eautoreconf |
Lines 290-298
Link Here
|
290 |
fi |
298 |
fi |
291 |
done |
299 |
done |
292 |
|
300 |
|
293 |
# Need JAVA_HOME for java. |
301 |
# JAVA_HOME is set by eclasses. |
294 |
if use collectd_plugins_java; then |
302 |
if use collectd_plugins_java; then |
295 |
myconf+=" --with-java=$(java-config -g JAVA_HOME)" |
303 |
myconf+=" --with-java" |
296 |
fi |
304 |
fi |
297 |
|
305 |
|
298 |
# Need libiptc ONLY for iptables. If we try to use it otherwise bug 340109 happens. |
306 |
# Need libiptc ONLY for iptables. If we try to use it otherwise bug 340109 happens. |
Lines 320-325
Link Here
|
320 |
|
328 |
|
321 |
find "${D}/usr/" -name "*.la" -exec rm -f {} + |
329 |
find "${D}/usr/" -name "*.la" -exec rm -f {} + |
322 |
|
330 |
|
|
|
331 |
use collectd_plugins_java && java-pkg_regjar "${ED}"/usr/share/${PN}/java/*.jar |
323 |
# use collectd_plugins_ping && setcap cap_net_raw+ep ${D}/usr/sbin/collectd |
332 |
# use collectd_plugins_ping && setcap cap_net_raw+ep ${D}/usr/sbin/collectd |
324 |
# we cannot do this yet |
333 |
# we cannot do this yet |
325 |
|
334 |
|