diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2012-07-21 15:14:27 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2012-07-21 15:14:27 +0000 |
commit | 9cef0005fd27f10cbe4df9b5f1dd383f174f3dbd (patch) | |
tree | 3ddb2040b0705f29cc7ba518fcf56cbe7b2e754a /net-analyzer | |
parent | Let it compile against glib-2.32 (diff) | |
download | gentoo-2-9cef0005fd27f10cbe4df9b5f1dd383f174f3dbd.tar.gz gentoo-2-9cef0005fd27f10cbe4df9b5f1dd383f174f3dbd.tar.bz2 gentoo-2-9cef0005fd27f10cbe4df9b5f1dd383f174f3dbd.zip |
Support fcron as well as vixie-cron and dcron (with a separate crontab); crontabs are created in the ebuild instead of using files to avoid wasting space on sync; use -j1 for make as well as install until parallel build is cleaned consistently; add a patch to not display cgroup_root in the df plugin output; backport a fix for the non-cgi munin-graph building; stop pkg_config if minimal USE flag is enabled. Drop ppc keyword for missing dependencies.
(Portage version: 2.2.0_alpha118/cvs/Linux x86_64)
Diffstat (limited to 'net-analyzer')
-rw-r--r-- | net-analyzer/munin/ChangeLog | 13 | ||||
-rw-r--r-- | net-analyzer/munin/munin-2.0.2-r1.ebuild (renamed from net-analyzer/munin/munin-2.0.2.ebuild) | 74 |
2 files changed, 76 insertions, 11 deletions
diff --git a/net-analyzer/munin/ChangeLog b/net-analyzer/munin/ChangeLog index 11a4494f1a44..2c53d2e1c1b6 100644 --- a/net-analyzer/munin/ChangeLog +++ b/net-analyzer/munin/ChangeLog @@ -1,6 +1,17 @@ # ChangeLog for net-analyzer/munin # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/ChangeLog,v 1.76 2012/07/20 18:10:54 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/ChangeLog,v 1.77 2012/07/21 15:14:27 flameeyes Exp $ + +*munin-2.0.2-r1 (21 Jul 2012) + + 21 Jul 2012; Diego E. Pettenò <flameeyes@gentoo.org> +munin-2.0.2-r1.ebuild, + -munin-2.0.2.ebuild: + Support fcron as well as vixie-cron and dcron (with a separate crontab); + crontabs are created in the ebuild instead of using files to avoid wasting + space on sync; use -j1 for make as well as install until parallel build is + cleaned consistently; add a patch to not display cgroup_root in the df plugin + output; backport a fix for the non-cgi munin-graph building; stop pkg_config + if minimal USE flag is enabled. Drop ppc keyword for missing dependencies. 20 Jul 2012; Diego E. Pettenò <flameeyes@gentoo.org> munin-2.0.2.ebuild: Log-Log4perl is used by the node, so depend on it even with USE=-minimal; only diff --git a/net-analyzer/munin/munin-2.0.2.ebuild b/net-analyzer/munin/munin-2.0.2-r1.ebuild index 55c5155b2842..19151700b266 100644 --- a/net-analyzer/munin/munin-2.0.2.ebuild +++ b/net-analyzer/munin/munin-2.0.2-r1.ebuild @@ -1,10 +1,10 @@ # Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/munin-2.0.2.ebuild,v 1.5 2012/07/20 18:10:54 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/munin-2.0.2-r1.ebuild,v 1.1 2012/07/21 15:14:27 flameeyes Exp $ EAPI=4 -PATCHSET=7 +PATCHSET=9 inherit eutils user versionator java-pkg-opt-2 @@ -17,7 +17,7 @@ SRC_URI="mirror://sourceforge/munin/${MY_P}.tar.gz LICENSE="GPL-2" SLOT="0" -KEYWORDS="~amd64 ~mips ~ppc ~x86" +KEYWORDS="~amd64 ~mips ~x86" IUSE="asterisk irc java memcached minimal mysql postgres ssl test +cgi" REQUIRED_USE="cgi? ( !minimal )" @@ -35,16 +35,16 @@ DEPEND_COM="dev-lang/perl postgres? ( dev-perl/DBD-Pg dev-db/postgresql-base ) memcached? ( dev-perl/Cache-Memcached ) cgi? ( dev-perl/FCGI ) + dev-perl/DBI dev-perl/DateManip dev-perl/File-Copy-Recursive dev-perl/IO-Socket-INET6 + dev-perl/Log-Log4perl dev-perl/Net-CIDR dev-perl/Net-Netmask dev-perl/Net-SNMP dev-perl/libwww-perl dev-perl/net-server - dev-perl/DBI - dev-perl/Log-Log4perl virtual/perl-Digest-MD5 virtual/perl-Getopt-Long virtual/perl-MIME-Base64 @@ -103,6 +103,13 @@ PERLSITELIB=$(perl -V:vendorlib | cut -d"'" -f2) JCVALID=$(usex java yes no) EOF } + +# parallel make and install need to be fixed before, and I haven't +# gotten around to do so yet. +src_compile() { + emake -j1 +} + src_install() { local dirs dirs="/var/log/munin/ /var/lib/munin/" @@ -125,8 +132,6 @@ src_install() { newins "${FILESDIR}"/${PN}-1.3.2-plugins.conf munin-node # make sure we've got everything in the correct directory - insinto /var/lib/munin - newins "${FILESDIR}"/${PN}-1.3.3-crontab crontab newinitd "${FILESDIR}"/munin-node_init.d_2.0.2 munin-node newconfd "${FILESDIR}"/munin-node_conf.d_1.4.6-r2 munin-node dodoc README ChangeLog INSTALL build/resources/apache* @@ -141,17 +146,66 @@ src_install() { # remove font files so that we don't have to keep them around rm "${D}"/usr/libexec/${PN}/*.ttf || die + + dodir /usr/share/${PN} + cat - >> "${D}"/usr/share/${PN}/crontab <<EOF +# Force the shell to bash +SHELL=/bin/bash +# Mail reports to root@, not munin@ +MAILTO=root + +# This runs the munin task every 5 minutes. +*/5 * * * * [ -x /usr/bin/munin-cron ] && /usr/bin/munin-cron + +# Alternatively, this route works differently +# Update once a minute (for busy sites) +#*/1 * * * * [ -x /usr/libexec/munin/munin-update ] && /usr/libexec/munin/munin-update +## Check for limit excess every 2 minutes +#*/2 * * * * [ -x /usr/libexec/munin/munin-limits ] && /usr/libexec/munin/munin-limits +## Update graphs every 5 minutes +#*/5 * * * * [ -x /usr/libexec/munin/munin-graph ] && nice /usr/libexec/munin/munin-graph --cron +## Update HTML pages every 15 minutes +#*/15 * * * * [ -x /usr/libexec/munin/munin-html ] && nice /usr/libexec/munin/munin-html +EOF + + cat - >> "${D}"/usr/share/${PN}/fcrontab <<EOF +# Mail reports to root@, not munin@, only execute one at a time +!mailto(root),serial(true) + +# This runs the munin task every 5 minutes. +@ 5 [ -x /usr/bin/munin-cron ] && /usr/bin/munin-cron + +# Alternatively, this route works differently +# Update once a minute (for busy sites) +#@ 1 [ -x /usr/libexec/munin/munin-update ] && /usr/libexec/munin/munin-update +## Check for limit excess every 2 minutes +#@ 2 [ -x /usr/libexec/munin/munin-limits ] && /usr/libexec/munin/munin-limits +## Update graphs every 5 minutes +#@ 5 [ -x /usr/libexec/munin/munin-graph ] && nice /usr/libexec/munin/munin-graph --cron +## Update HTML pages every 15 minutes +#@ 15 [ -x /usr/libexec/munin/munin-html ] && nice /usr/libexec/munin/munin-html +EOF fi } pkg_config() { + if use minimal; then + einfo "Nothing to do." + return 0 + fi + einfo "Press enter to install the default crontab for the munin master" einfo "installation from /var/lib/munin/crontab" einfo "If you have a large site, you may wish to customize it." read - # dcron is very fussy about syntax - # the following is the only form that works in BOTH dcron and vixie-cron - crontab - -u munin </var/lib/munin/crontab + + if has_version sys-process/fcron; then + fcrontab - -u munin < /usr/share/${PN}/fcrontab + else + # dcron is very fussy about syntax + # the following is the only form that works in BOTH dcron and vixie-cron + crontab - -u munin < /usr/share/${PN}/crontab + fi } pkg_postinst() { |