Gentoo Archives: gentoo-commits

From: "Tobias Scherbaum (dertobi123)" <dertobi123@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-analyzer/nagios-plugins: ChangeLog nagios-plugins-1.4.15.ebuild nagios-plugins-1.4.13-r1.ebuild
Date: Fri, 30 Jul 2010 15:02:13
Message-Id: 20100730143442.83DE12CE15@corvid.gentoo.org
1 dertobi123 10/07/30 14:34:42
2
3 Modified: ChangeLog
4 Added: nagios-plugins-1.4.15.ebuild
5 Removed: nagios-plugins-1.4.13-r1.ebuild
6 Log:
7 Version bump
8 (Portage version: 2.2_rc67/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.131 net-analyzer/nagios-plugins/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog?rev=1.131&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog?rev=1.131&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog?r1=1.130&r2=1.131
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog,v
20 retrieving revision 1.130
21 retrieving revision 1.131
22 diff -u -r1.130 -r1.131
23 --- ChangeLog 25 Jun 2010 10:34:19 -0000 1.130
24 +++ ChangeLog 30 Jul 2010 14:34:41 -0000 1.131
25 @@ -1,6 +1,13 @@
26 # ChangeLog for net-analyzer/nagios-plugins
27 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog,v 1.130 2010/06/25 10:34:19 hwoarang Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-plugins/ChangeLog,v 1.131 2010/07/30 14:34:41 dertobi123 Exp $
30 +
31 +*nagios-plugins-1.4.15 (30 Jul 2010)
32 +
33 + 30 Jul 2010; Tobias Scherbaum <dertobi123@g.o>
34 + -nagios-plugins-1.4.13-r1.ebuild, +nagios-plugins-1.4.15.ebuild,
35 + +files/nagios-plugins-1.4.15-vserver.patch:
36 + Version bump
37
38 25 Jun 2010; Markos Chandras <hwoarang@g.o>
39 nagios-plugins-1.4.14.ebuild,
40
41
42
43 1.1 net-analyzer/nagios-plugins/nagios-plugins-1.4.15.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/nagios-plugins/nagios-plugins-1.4.15.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/nagios-plugins/nagios-plugins-1.4.15.ebuild?rev=1.1&content-type=text/plain
47
48 Index: nagios-plugins-1.4.15.ebuild
49 ===================================================================
50 # Copyright 1999-2010 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/net-analyzer/nagios-plugins/nagios-plugins-1.4.15.ebuild,v 1.1 2010/07/30 14:34:41 dertobi123 Exp $
53
54 EAPI=1
55
56 inherit eutils autotools
57
58 DESCRIPTION="Nagios $PV plugins - Pack of plugins to make Nagios work properly"
59 HOMEPAGE="http://www.nagios.org/"
60 SRC_URI="mirror://sourceforge/nagiosplug/${P}.tar.gz"
61
62 LICENSE="GPL-2"
63 SLOT="0"
64 KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
65 IUSE="+ssl samba mysql postgres ldap snmp nagios-dns nagios-ntp nagios-ping nagios-ssh nagios-game ups ipv6 radius +suid jabber"
66
67 DEPEND="ldap? ( >=net-nds/openldap-2.0.25 )
68 mysql? ( virtual/mysql )
69 postgres? ( dev-db/postgresql-base )
70 ssl? ( >=dev-libs/openssl-0.9.6g )
71 radius? ( >=net-dialup/radiusclient-0.3.2 )"
72
73 RESTRICT="test"
74
75 RDEPEND="${DEPEND}
76 >=dev-lang/perl-5.6.1-r7
77 samba? ( >=net-fs/samba-2.2.5-r1 )
78 snmp? ( >=dev-perl/Net-SNMP-4.0.1-r1
79 >=net-analyzer/net-snmp-5.0.6
80 )
81 mysql? ( dev-perl/DBI
82 dev-perl/DBD-mysql )
83 nagios-dns? ( >=net-dns/bind-tools-9.2.2_rc1 )
84 nagios-ntp? ( >=net-misc/ntp-4.1.1a )
85 nagios-ping? ( >=net-analyzer/fping-2.4_beta2-r1 )
86 nagios-ssh? ( >=net-misc/openssh-3.5_p1 )
87 ups? ( >=sys-power/nut-1.4 )
88 !sparc? ( nagios-game? ( >=games-util/qstat-2.6 ) )
89 jabber? ( >=dev-perl/Net-Jabber-2.0 )"
90
91 pkg_setup() {
92 enewgroup nagios
93 enewuser nagios -1 /bin/bash /var/nagios/home nagios
94 }
95
96 src_unpack() {
97 unpack ${A}
98 cd "${S}"
99
100 if ! use radius; then
101 EPATCH_OPTS="-p1 -d ${S}" epatch \
102 "${FILESDIR}"/nagios-plugins-1.4.10-noradius.patch
103 fi
104
105 epatch "${FILESDIR}"/${PN}-1.4.10-contrib.patch
106 epatch "${FILESDIR}"/${PN}-1.4.12-pgsqlconfigure.patch
107 epatch "${FILESDIR}"/${P}-vserver.patch
108
109 eautoreconf
110 }
111
112 src_compile() {
113
114 local conf
115 if use ssl; then
116 conf="${conf} --with-openssl=/usr"
117 else
118 conf="${conf} --without-openssl"
119 fi
120
121 if use postgres; then
122 conf="${conf} --with-pgsql=/usr"
123 fi
124
125 econf \
126 $(use_with mysql) \
127 $(use_with ipv6) \
128 ${conf} \
129 --host=${CHOST} \
130 --prefix=/usr \
131 --libexecdir=/usr/$(get_libdir)/nagios/plugins \
132 --sysconfdir=/etc/nagios || die "econf failed"
133
134 # fix problem with additional -
135 sed -i -e 's:/bin/ps -axwo:/bin/ps axwo:g' config.h || die "sed failed"
136
137 emake || die "emake failed"
138 }
139
140 src_install() {
141 mv "${S}"/contrib/check_compaq_insight.pl "${S}"/contrib/check_compaq_insight.pl.msg
142 chmod +x "${S}"/contrib/*.pl
143
144 sed -i -e '1s;#!.*;#!/usr/bin/perl -w;' "${S}"/contrib/*.pl || die "sed failed"
145 sed -i -e s#/usr/nagios/libexec#/usr/$(get_libdir)/nagios/plugins#g "${S}"/contrib/*.pl || die "sed failed"
146 sed -i -e '30s/use lib utils.pm;/use utils;/' \
147 "${S}"/plugins-scripts/check_file_age.pl || die "sed failed"
148
149 dodoc ACKNOWLEDGEMENTS AUTHORS BUGS CODING \
150 ChangeLog FAQ NEWS README REQUIREMENTS SUPPORT THANKS
151
152 emake DESTDIR="${D}" install || die "make install failed"
153
154 if use mysql || use postgres; then
155 dodir /usr/$(get_libdir)/nagios/plugins
156 exeinto /usr/$(get_libdir)/nagios/plugins
157 doexe "${S}"/contrib/check_nagios_db.pl
158 fi
159
160 if ! use snmp; then
161 rm "${D}"/usr/$(get_libdir)/nagios/plugins/check_if{operstatus,status} \
162 || die "Failed to remove SNMP check plugins"
163 fi
164
165 mv "${S}"/contrib "${D}"/usr/$(get_libdir)/nagios/plugins/contrib
166
167 if ! use jabber; then
168 rm "${D}"usr/$(get_libdir)/nagios/plugins/contrib/nagios_sendim.pl \
169 || die "Failed to remove XMPP notification addon"
170 fi
171
172 chown -R root:nagios "${D}"/usr/$(get_libdir)/nagios/plugins \
173 || die "Failed chown of ${D}usr/$(get_libdir)/nagios/plugins"
174
175 chmod -R o-rwx "${D}"/usr/$(get_libdir)/nagios/plugins \
176 || die "Failed chmod of ${D}usr/$(get_libdir)/nagios/plugins"
177
178 if use suid ; then
179
180 chmod 04710 "${D}"/usr/$(get_libdir)/nagios/plugins/{check_icmp,check_ide_smart,check_dhcp} \
181 || die "Failed setting the suid bit for various plugins"
182 fi
183
184 dosym /usr/$(get_libdir)/nagios/plugins/utils.sh /usr/$(get_libdir)/nagios/plugins/contrib/utils.sh
185 dosym /usr/$(get_libdir)/nagios/plugins/utils.pm /usr/$(get_libdir)/nagios/plugins/contrib/utils.pm
186 }
187
188 pkg_postinst() {
189 einfo "This ebuild has a number of USE flags which determines what nagios is able to monitor."
190 einfo "Depending on what you want to monitor with nagios, some or all of these USE"
191 einfo "flags need to be set for nagios to function correctly."
192 echo
193 einfo "contrib plugins are installed into /usr/$(get_libdir)/nagios/plugins/contrib"
194 }