From 590703932f4ec23e1f5246b95ff2ec3205133f6b Mon Sep 17 00:00:00 2001 From: jsbronder Date: Fri, 1 Aug 2008 03:48:54 +0000 Subject: Add ganglia-3.1.0. Python is not fully working yet, but everything else checks out. git-svn-id: http://overlays.gentoo.org/svn/proj/science/overlay@1228 32389bae-6d03-0410-99cf-db05cde120eb --- sys-cluster/ganglia/Manifest | 4 ++ sys-cluster/ganglia/files/gmetad.rc | 17 +++++ sys-cluster/ganglia/files/gmond.rc | 17 +++++ sys-cluster/ganglia/ganglia-3.1.0.ebuild | 120 +++++++++++++++++++++++++++++++ 4 files changed, 158 insertions(+) create mode 100644 sys-cluster/ganglia/Manifest create mode 100755 sys-cluster/ganglia/files/gmetad.rc create mode 100755 sys-cluster/ganglia/files/gmond.rc create mode 100644 sys-cluster/ganglia/ganglia-3.1.0.ebuild (limited to 'sys-cluster/ganglia') diff --git a/sys-cluster/ganglia/Manifest b/sys-cluster/ganglia/Manifest new file mode 100644 index 000000000..c3d80569c --- /dev/null +++ b/sys-cluster/ganglia/Manifest @@ -0,0 +1,4 @@ +AUX gmetad.rc 328 RMD160 bfe287d90db7f26cd13978c99eabc6f7783b7073 SHA1 73d49ca4f669d914c87e2cdd9a4ad74bf1a75eb5 SHA256 c25c3dac00012f83e45819d6d0fb79bcf4e1ec773ad705b38127aade7c2a08c7 +AUX gmond.rc 322 RMD160 98ac6011a603e3286ffe5c2368620ae0630a013f SHA1 d304b1849ea1abf14360915b3978e781b8e0cbed SHA256 ea3bd50fe4bfc18254fdfb69c81ec0bfad0c552a2f9a3d3aee4732f644695d7d +DIST ganglia-3.1.0.tar.gz 1175129 RMD160 92fee8fc2ffe6d058be2dc73bba6697dc2a226db SHA1 00b8901d2ff253564ef4a46918c1e28ea65e506a SHA256 87e367bd8de0d1ca87a7bc16477f99900b7e0dd87db7485aeb4f2e5766576b90 +EBUILD ganglia-3.1.0.ebuild 3167 RMD160 e07b1eb47890b475bb1074dadfd73d4d840592da SHA1 f561f0124f27bb2057ed12e918ac9dcc6e5f7310 SHA256 3cafba9a8da6135ac4835b04ffe3785940383c0d1c62b0773b68438a8a1e18e1 diff --git a/sys-cluster/ganglia/files/gmetad.rc b/sys-cluster/ganglia/files/gmetad.rc new file mode 100755 index 000000000..a9ae5c75a --- /dev/null +++ b/sys-cluster/ganglia/files/gmetad.rc @@ -0,0 +1,17 @@ +#!/sbin/runscript + +depend() { + need net +} + +start() { + ebegin "Starting GANGLIA gmetad: " + start-stop-daemon --start --quiet --exec /usr/sbin/gmetad + eend $? "Failed to start gmetad" +} + +stop() { + ebegin "Shutting down GANGLIA gmetad: " + start-stop-daemon --stop --quiet --exec /usr/sbin/gmetad + eend $? "Failed to stop gmetad" +} diff --git a/sys-cluster/ganglia/files/gmond.rc b/sys-cluster/ganglia/files/gmond.rc new file mode 100755 index 000000000..895420705 --- /dev/null +++ b/sys-cluster/ganglia/files/gmond.rc @@ -0,0 +1,17 @@ +#!/sbin/runscript + +depend() { + need net +} + +start() { + ebegin "Starting GANGLIA gmond: " + start-stop-daemon --start --quiet --exec /usr/sbin/gmond + eend $? "Failed to start gmond" +} + +stop() { + ebegin "Shutting down GANGLIA gmond: " + start-stop-daemon --stop --quiet --exec /usr/sbin/gmond + eend $? "Failed to stop gmond" +} diff --git a/sys-cluster/ganglia/ganglia-3.1.0.ebuild b/sys-cluster/ganglia/ganglia-3.1.0.ebuild new file mode 100644 index 000000000..eb0af3ea6 --- /dev/null +++ b/sys-cluster/ganglia/ganglia-3.1.0.ebuild @@ -0,0 +1,120 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-cluster/ganglia/ganglia-3.0.7.ebuild,v 1.4 2008/03/28 22:47:32 mr_bones_ Exp $ + +WEBAPP_OPTIONAL="yes" +inherit multilib webapp depend.php python + +DESCRIPTION="Ganglia is a scalable distributed monitoring system for high-performance computing systems such as clusters and grids" +HOMEPAGE="http://ganglia.sourceforge.net/" +SRC_URI="mirror://sourceforge/ganglia/${P}.tar.gz" +LICENSE="BSD" + +WEBAPP_MANUAL_SLOT="yes" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" +IUSE="test minimal vhosts python" + +DEPEND=" + dev-libs/confuse + dev-libs/expat + dev-libs/apr + test? ( >=dev-libs/check-0.8.2 ) + python? ( dev-lang/python )" + +RDEPEND=" + ${DEPEND} + !minimal? ( net-analyzer/rrdtool + ${WEBAPP_DEPEND} + =virtual/httpd-php-5* )" + +pkg_setup() { + if ! use minimal ; then + require_gd + require_php_with_use xml ctype + webapp_pkg_setup + fi +} + +src_compile() { + econf \ + --enable-gexec \ + $(use_enable python) \ + $(use_with !minimal gmetad) || die "econf failed" + + emake || die "emake failed" +} + +src_install() { + emake DESTDIR="${D}" install || die "emake install failed" + + newinitd "${FILESDIR}"/gmond.rc gmond + doman mans/{gmetric.1,gmond.1,gstat.1} + doman gmond/gmond.conf.5 + dodoc AUTHORS ChangeLog INSTALL NEWS README + dodir /etc/ganglia/conf.d + + if use python; then + # Sadly, there is no install target for any of this. + mv gmond/modules/python/README ${T}/README.python_modules + dodoc ${T}/README.python_modules + insinto /etc/ganglia/conf.d + # TODO: tcpconn cause a traceback, and diskusage import it? + doins gmond/python_modules/conf.d/example.pyconf + doins gmond/modules/conf.d/modpython.conf + dodir /usr/$(get_libdir)/ganglia/python_modules + insinto /usr/$(get_libdir)/ganglia/python_modules + doins $(find gmond/python_modules/ -name '*.py') + fi + + insinto /etc/ganglia + if ! use minimal; then + doins gmetad/gmetad.conf + doman mans/gmetad.1 + keepdir /var/lib/ganglia/rrds + fowners nobody:nobody /var/lib/ganglia/rrds + newinitd "${FILESDIR}"/gmetad.rc gmetad + + webapp_src_preinst + insinto "${MY_HTDOCSDIR}" + doins -r web/* + + webapp_configfile "${MY_HTDOCSDIR}"/conf.php + webapp_src_install + fi +} + +pkg_preinst() { + local f + if has_version ' /etc/ganglia/gmond.conf" + elog "and customize it from there or provide your own." + + use minimal || webapp_pkg_postinst + + use python && \ + python_mod_optimize /usr/$(get_libdir)/ganglia/python_modules/ +} + +pkg_prerm() { + use minimal || webapp_pkg_prerm +} + +pkg_postrm() { + use python && \ + python_mod_cleanup /usr/$(get_libdir)/ganglia/python_modules/ +} -- cgit v1.2.3-65-gdbad