summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Black <dragonheart@gentoo.org>2005-01-28 04:52:09 +0000
committerDaniel Black <dragonheart@gentoo.org>2005-01-28 04:52:09 +0000
commitdbc346ac2a32451ca959a6b5025d164cccb0ce4f (patch)
tree7a2a217b6b7938611ae4ceb6a198de34c98fd453 /net-analyzer
parent=net-analyzer/nagios-core-2.0b_p1 Apache herd package refresh Meta-bug #76457 (diff)
downloadgentoo-2-dbc346ac2a32451ca959a6b5025d164cccb0ce4f.tar.gz
gentoo-2-dbc346ac2a32451ca959a6b5025d164cccb0ce4f.tar.bz2
gentoo-2-dbc346ac2a32451ca959a6b5025d164cccb0ce4f.zip
Version bump as per bug #74481. Still masked due to apache bug #76457
(Portage version: 2.0.51-r15)
Diffstat (limited to 'net-analyzer')
-rw-r--r--net-analyzer/nagios-core/ChangeLog9
-rw-r--r--net-analyzer/nagios-core/Manifest13
-rw-r--r--net-analyzer/nagios-core/files/2.0b_p1-submit_check_result_via_nsca.patch18
-rw-r--r--net-analyzer/nagios-core/files/digest-nagios-core-2.0b_p11
-rw-r--r--net-analyzer/nagios-core/nagios-core-2.0b_p1.ebuild220
5 files changed, 250 insertions, 11 deletions
diff --git a/net-analyzer/nagios-core/ChangeLog b/net-analyzer/nagios-core/ChangeLog
index 1366b55b2ee4..4b90fc50a162 100644
--- a/net-analyzer/nagios-core/ChangeLog
+++ b/net-analyzer/nagios-core/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-analyzer/nagios-core
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-core/ChangeLog,v 1.47 2005/01/25 10:04:18 dragonheart Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-core/ChangeLog,v 1.48 2005/01/28 04:52:09 dragonheart Exp $
+
+*nagios-core-2.0b_p1 (28 Jan 2005)
+
+ 28 Jan 2005; Daniel Black <dragonheart@gentoo.org>
+ +files/2.0b_p1-submit_check_result_via_nsca.patch,
+ +nagios-core-2.0b_p1.ebuild:
+ Version bump as per bug #74481. Still masked due to apache bug #76457
*nagios-core-1.2-r4 (25 Jan 2005)
diff --git a/net-analyzer/nagios-core/Manifest b/net-analyzer/nagios-core/Manifest
index 9e73cfcf9f25..4f3f97b1eabc 100644
--- a/net-analyzer/nagios-core/Manifest
+++ b/net-analyzer/nagios-core/Manifest
@@ -1,12 +1,10 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
MD5 2b01bf3690a35ffdce51bc4ecee618cd ChangeLog 8249
MD5 a1ece421fae3536d1e5dd9b5ecb0215d metadata.xml 928
MD5 e4ffec908f9991ffd916e63a4bb2c002 nagios-core-1.2-r3.ebuild 7167
MD5 b2b5a4982c7a888addfc7c5bb2ec173e nagios-core-1.2-r2.ebuild 6619
MD5 cf93d67ac95ed4f86c4d40a4e6d50ed4 nagios-core-1.2-r4.ebuild 7095
MD5 8e2eaa206717b94fb41508c7ab17a135 nagios-core-1.2-r1.ebuild 6669
+MD5 3ecffdd830768bbec413ad01a00fa072 nagios-core-2.0b_p1.ebuild 5772
MD5 673bda0ac6ab9230d23331e7f3846b7b files/99_nagios.conf 350
MD5 565ce2a690d50aeb542e7afe44b8c733 files/Makefile-distclean.diff.bz2 1133
MD5 f2947dec6b9a839da79606bcc394036b files/conf.d 409
@@ -18,10 +16,5 @@ MD5 cd183719838dc2a8b9cafa8a639f4ad2 files/digest-nagios-core-1.2-r3 63
MD5 cd183719838dc2a8b9cafa8a639f4ad2 files/digest-nagios-core-1.2-r1 63
MD5 cee7d66cc61be3558af44ab177d99e1f files/submit_check_result_via_nsca.patch 585
MD5 cd183719838dc2a8b9cafa8a639f4ad2 files/digest-nagios-core-1.2-r4 63
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.0 (GNU/Linux)
-
-iD8DBQFB9iH9mdTrptrqvGERAok0AJ46FlKWbUl6qWEyGZNdYR9fAo984QCgmgEv
-0aGof74vvPkfmMN+T4+Fmvo=
-=jR67
------END PGP SIGNATURE-----
+MD5 aa5bb53aee1f5609395e8184f2eff4a6 files/digest-nagios-core-2.0b_p1 65
+MD5 446906907cccdbf195442373c6f17f77 files/2.0b_p1-submit_check_result_via_nsca.patch 767
diff --git a/net-analyzer/nagios-core/files/2.0b_p1-submit_check_result_via_nsca.patch b/net-analyzer/nagios-core/files/2.0b_p1-submit_check_result_via_nsca.patch
new file mode 100644
index 000000000000..faae90c48597
--- /dev/null
+++ b/net-analyzer/nagios-core/files/2.0b_p1-submit_check_result_via_nsca.patch
@@ -0,0 +1,18 @@
+--- contrib/eventhandlers/distributed-monitoring/submit_check_result_via_nsca.orig 2005-01-28 12:57:11.537852344 +0930
++++ contrib/eventhandlers/distributed-monitoring/submit_check_result_via_nsca 2005-01-28 12:57:45.877631904 +0930
+@@ -28,9 +28,12 @@
+
+ printfcmd="/bin/printf"
+
+-NscaBin="/usr/local/nagios/libexec/send_nsca"
+-NscaCfg="/usr/local/nagios/etc/send_nsca.cfg"
+-NagiosHost="nagioshost"
++NscaBin="/usr/nagios/libexec/send_nsca"
++NscaCfg="/etc/nagios/send_nsca.cfg"
++
++# Gentoo Linux Users: configure the hostname in /etc/conf.d/nagios
++source /etc/conf.d/nagios
++NagiosHost="${NAGIOS_NSCA_HOST}"
+
+ # Fire the data off to the NSCA daemon using the send_nsca script
+ $printfcmd "%s\t%s\t%s\t%s\n" "$1" "$2" "$3" "$4" | $NscaBin $NagiosHost -c $NscaCfg
diff --git a/net-analyzer/nagios-core/files/digest-nagios-core-2.0b_p1 b/net-analyzer/nagios-core/files/digest-nagios-core-2.0b_p1
new file mode 100644
index 000000000000..df8b7caf32c4
--- /dev/null
+++ b/net-analyzer/nagios-core/files/digest-nagios-core-2.0b_p1
@@ -0,0 +1 @@
+MD5 994a89bd6d344f72a0520b72fb615857 nagios-2.0b1.tar.gz 1694022
diff --git a/net-analyzer/nagios-core/nagios-core-2.0b_p1.ebuild b/net-analyzer/nagios-core/nagios-core-2.0b_p1.ebuild
new file mode 100644
index 000000000000..b20a86b48c5a
--- /dev/null
+++ b/net-analyzer/nagios-core/nagios-core-2.0b_p1.ebuild
@@ -0,0 +1,220 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-core/nagios-core-2.0b_p1.ebuild,v 1.1 2005/01/28 04:52:09 dragonheart Exp $
+
+inherit eutils depend.apache toolchain-funcs
+
+MY_P=${PN/-core}-${PV/_p}
+DESCRIPTION="Nagios Core - Check daemon, CGIs, docs"
+HOMEPAGE="http://www.nagios.org/"
+SRC_URI="mirror://sourceforge/nagios/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86 ~sparc ~ppc ~amd64"
+IUSE="noweb perl debug apache2"
+# mysql postgres
+DEPEND="virtual/mailx
+ !noweb? (
+ >=media-libs/jpeg-6b-r3
+ >=media-libs/libpng-1.2.5-r4
+ >=media-libs/gd-1.8.3-r5
+ ${APACHE_DEPEND}
+ perl? ( net-analyzer/traceroute )
+ )
+ perl? ( >=dev-lang/perl-5.6.1-r7 )"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ # If there's a gd lib on the system, it will try to build with it.
+ # check if gdlib-config is on, and then check its output.
+ if [[ -x ${ROOT}usr/bin/gdlib-config ]]; then
+ if [[ ! $(${ROOT}usr/bin/gdlib-config --libs | grep -- -ljpeg) ]]; then
+ eerror "Your gd has been compiled without jpeg support."
+ eerror "Please re-emerge gd:"
+ eerror "# USE="jpeg" emerge gd"
+ die "pkg_setup failed"
+ fi
+ fi
+}
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ epatch ${FILESDIR}/${PV}-submit_check_result_via_nsca.patch || die "patch failed"
+
+ gunzip -c ${FILESDIR}/nagios.cfg-sample.gz > ./nagios.cfg-sample
+}
+
+src_compile() {
+ local myconf
+
+ if use perl
+ then
+ myconf="${myconf} --enable-embedded-perl --with-perlcache"
+ fi
+
+ if use debug; then
+ myconf="${myconf} --enable-DEBUG0"
+ myconf="${myconf} --enable-DEBUG1"
+ myconf="${myconf} --enable-DEBUG2"
+ myconf="${myconf} --enable-DEBUG3"
+ myconf="${myconf} --enable-DEBUG4"
+ myconf="${myconf} --enable-DEBUG5"
+ fi
+
+ if use noweb; then
+ myconf="${myconf} --with-command-grp=nagios"
+ else
+ myconf="${myconf} --with-command-grp=apache"
+ fi
+
+ ./configure ${myconf} \
+ --host=${CHOST} \
+ --prefix=/usr/nagios \
+ --localstatedir=/var/nagios \
+ --sysconfdir=/etc/nagios \
+ --infodir=/usr/share/info \
+ --mandir=/usr/share/man \
+ ${myconf} || die "./configure failed"
+
+ emake CC=$(tc-getCC) nagios contrib || die "make failed"
+
+ if use !noweb ; then
+ # Only compile the CGI's if "noweb" useflag is not set.
+ make CC=$(tc-getCC) DESTDIR=${D} cgis || die
+ fi
+
+ # convert config files
+ emake -C contrib convertcfg || "config convert died"
+
+}
+
+src_install() {
+ dodoc Changelog INSTALLING LEGAL LICENSE README UPGRADING
+
+ if use noweb; then
+ sed -i -e 's/cd $(SRC_CGI) && $(MAKE) $@/# line removed due to noweb use flag/' \
+ -e 's/cd $(SRC_HTM) && $(MAKE) $@/# line removed due to noweb use flag/' \
+ Makefile
+ fi
+
+ sed -i -e 's/^contactgroups$//g' Makefile
+
+ make DESTDIR=${D} install
+ make DESTDIR=${D} install-config
+ make DESTDIR=${D} install-commandmode
+
+ docinto sample-configs
+ dodoc ${D}/etc/nagios/*
+ rm ${D}/etc/nagios/*
+
+ dodoc ${S}/nagios.cfg-sample
+
+ exeinto /etc/init.d
+ doexe ${FILESDIR}/nagios
+
+ insinto /etc/conf.d
+ newins ${FILESDIR}/conf.d nagios
+
+
+ rm ${S}/contrib/Makefile* ${S}/contrib/*.c ${S}/contrib/*.h
+
+ #contribs are not configured by the configure script, we'll configure them overselves...
+ find ${S}/contrib/ -type f | xargs sed -e 's:/usr/local/nagios/var/rw:/var/nagios/rw:;
+ s:/usr/local/nagios/libexec:/usr/nagios/libexec:;
+ s:/usr/local/nagios/etc:/etc/nagios:;
+ s:/usr/local/nagios/sbin:/usr/nagios/sbin:;' -i
+
+ mv contrib/ ${D}usr/nagios
+
+ for dir in etc/nagios usr/nagios var/nagios usr/nagios/contrib
+ do
+ chown -R nagios:nagios ${D}/${dir} || die "Failed chown of ${D}/${dir}"
+ done
+
+ #Apache Module
+ if use !noweb; then
+ if use apache2; then
+ insinto ${APACHE2_MODULES_CONFDIR}
+ doins ${FILESDIR}/99_nagios.conf
+ else
+ insinto ${APACHE1_MODULES_CONFDIR}
+ doins ${FILESDIR}/nagios.conf
+ fi
+ if use perl; then
+ mv ${D}usr/nagios/contrib/traceroute.cgi ${D}usr/nagios/sbin
+ fperms a+x /usr/nagios/sbin/traceroute.cgi
+ fi
+ fi
+}
+
+pkg_preinst() {
+ keepdir /etc/nagios
+ keepdir /var/nagios
+ keepdir /var/nagios/archives
+ keepdir /usr/nagios/share/ssi
+ keepdir /var/nagios/rw
+
+ enewgroup nagios
+
+ if use noweb; then
+ enewuser nagios -1 /bin/bash /dev/null nagios
+ chown nagios:nagios ${D}/var/nagios/rw || die "Failed Chown of ${D}/var/nagios/rw"
+ else
+ enewuser nagios -1 /bin/bash /dev/null apache
+ usermod -G apache nagios
+ chown nagios:apache ${D}/var/nagios/rw || die "Failed Chown of ${D}/var/nagios/rw"
+ fi
+
+ chmod ug+s ${D}/var/nagios/rw || die "Failed Chmod of ${D}/var/nagios/rw"
+}
+
+pkg_postinst() {
+ einfo
+ einfo "The example config files are located at /usr/share/doc/${PF}/sample-configs/."
+ einfo
+ einfo "Also, if you want nagios to start at boot time"
+ einfo "remember to execute:"
+ einfo " rc-update add nagios default"
+ einfo
+
+ if use !noweb; then
+ einfo "This does not include cgis that are perl-dependent"
+ einfo "Currently traceroute.cgi is perl-dependent"
+ einfo "To have ministatus.cgi requires copying of ministatus.c"
+ einfo "to cgi directory for compiling."
+
+ if use apache2; then
+ einfo " Edit /etc/conf.d/apache2 and add \"-D NAGIOS\""
+ else
+ einfo " Edit /etc/conf.d/apache and add \"-D NAGIOS\""
+ fi
+
+ einfo
+ einfo "That will make nagios's web front end visable via"
+ einfo "http://localhost/nagios/"
+ einfo
+
+ else
+ einfo "Please note that you have installed Nagios without web interface."
+ einfo "Please don't file any bugs about having no web interface when you do this."
+ einfo "Thank you!"
+ fi
+
+ einfo
+ einfo "If your kernel has /proc protection, nagios"
+ einfo "will not be happy as it relies on accessing the proc"
+ einfo "filesystem. You can fix this by adding nagios into"
+ einfo "the group wheel, but this is not recomended."
+ einfo
+
+ einfo
+ ewarn "Use /usr/nagios/contrib/convertcfg for configuration file conversion"
+ einfo
+}
+
+pkg_prerm() {
+ /etc/init.d/nagios stop
+}