Search
j0ke.net Open Build Service
>
Projects
>
server:database
:
percona
>
nagios-plugins
> Changes
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
Difference Between Revision 7 and
home:netmax
/
nagios-plugins
[-]
[+]
Changed
nagios-plugins.spec
@@ -1,51 +1,18 @@ #!BuildIgnore: post-build-checks - -%global commit 1b8ad572ea5480f9f611cf7321feb10f176fdb84 -%global shortcommit %(c=%{commit}; echo ${c:0:7}) -%global commdate 20190926 - -%global gitbuild 0 - -%define pkgname nagios-plugins Name: nagios-plugins -Version: 2.4.9 -%if 0%{?gitbuild:1} -Release: 35.%{?commdate}git%{?shortcommit}%{?dist} -%else +Version: 1.4.16 Release: 35 -%endif Summary: Host/service/network monitoring program plugins for Nagios Group: Applications/System License: GPL -URL: https://www.nagios-plugins.org/ -%if 0%{?gitbuild:1} -Source0: https://github.com/nagios-plugins/%{name}/archive/%{commit}/%{name}-%{shortcommit}.tar.gz -%else -Source0: %{pkgname}-%{version}.tar.bz2 -%endif - +URL: http://nagiosplug.sourceforge.net/ +Source0: http://dl.sf.net/sourceforge/nagiosplug/%{name}-%{version}.tar.bz2 Source1: %{name}-rpmlintrc -%if 0%{?gitbuild:1} -Patch1: nagios-plugins-0001-Fix-mysql-f27.patch -Patch2: nagios-plugins-0002-Remove-assignment-of-not-parsed-to-jitter.patch -Patch7: nagios-plugins-0007-Fix-the-use-lib-statement-and-the-external-ntp-comma.patch -Patch10: nagios-plugins-0010-include-mysql-version-header.patch -Patch11: nagios-plugins-0011-fix-perl-shebang.patch -Patch12: nagios-plugins-0012-fix-perl-ntp-ipv6.patch -%else -Patch200: revert-check_mailq-autodetect-2.4.0.diff -%endif - BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Prefix: %{_prefix}/lib/nagios/plugins PreReq: sed -Provides: monitoring-plugins-%{version}-%{release} -Provides: nagios-plugins-perl-%{version}-%{release} -Obsoletes: nagios-plugins-perl -Provides: monitoring-plugins-perl-%{version}-%{release} -Obsoletes: monitoring-plugins-perl %{!?custom:%global custom 0} Obsoletes: nagios-plugins-custom nagios-plugins-extras @@ -61,52 +28,21 @@ %endif %if 0%{?suse_version} -%if 0%{?suse_version} > 1310 -BuildRequires: libsmbclient0 -%else -BuildRequires: libsmbclient qstat -%endif -BuildRequires: tcpd-devel libsmbclient-devel openldap2-devel perl-Net-SNMP fping glibc bind-utils -%if 0%{?suse_version} > 1030 -BuildRequires: freeradius-client-devel freeradius-server-devel -%else -BuildRequires: freeradius-devel +BuildRequires: tcpd-devel libsmbclient libsmbclient-devel openldap2-devel perl-Net-SNMP fping glibc bind-utils %endif -%endif - - %if 0%{?fedora_version} || 0%{?centos_version} || 0%{?rhel_version} || 0%{?redhat_version} || 0%{?sl_version} -%if 0%{?rhel} == 8 -BuildRequires: openldap-devel freeradius samba-common openldap-devel glibc-common qstat which -%else -BuildRequires: tcp_wrappers openldap-devel freeradius samba-common openldap-devel net-snmp-perl glibc-common qstat which -%endif -%endif - - -# fping is in EPEL for EL -BuildRequires: openssl-devel postgresql-devel mysql-devel zlib-devel glibc-devel gcc gcc-c++ net-snmp net-snmp-devel openssh iputils samba-client procps fping - -%if 0%{?suse_version} <= 1310 -Requires: iputils qstat -%else -Requires: iputils +BuildRequires: tcp_wrappers openldap-devel freeradius samba-common openldap-devel net-snmp-perl glibc-common %endif +BuildRequires: openssl-devel postgresql-devel Percona-Server-devel-51 Percona-Server-shared-51 zlib-devel glibc-devel libgcc gcc gcc-c++ net-snmp net-snmp-devel openssh qstat iputils samba-client procps +Requires: qstat iputils %if 0%{?fedora_version} || 0%{?centos_version} || 0%{?rhel_version} || 0%{?redhat_version} || 0%{?sl_version} Requires: /usr/bin/smbclient %else Requires: samba-client %endif -# this is disabled in our build to have other packages require the utils.pm from nagios-plugins -# Do not provide private Perl modules -# global __provides_exclude %{?__provides_exclude:%{__provides_exclude}|}^perl\\(utils\\) -# global reqfilt sh -c "%{__perl_requires} | sed -e 's!perl(utils)!nagios-plugins-perl!'" -# global __perl_requires %{reqfilt} - - %description Nagios is a program that will monitor hosts and services on your network, and to email or page you when a problem arises or is @@ -118,40 +54,16 @@ %prep -%if 0%{?gitbuild:1} -%setup -q -n %{name}-%{commit} -%if 0%{?fedora} >26 -%patch1 -p1 -b .fix_mysql -%endif -%patch2 -p1 -b .remove_ntp_jitter -%patch7 -p1 -b .fix_ntpcommands -%if 0%{?rhel} > 7 -%patch10 -p1 -b .mysqlversionh -%endif -%patch11 -p1 -b .fix_perl_shebang -%patch12 -p1 -b .fix_perl_ntp -%else -%setup -q -n %{pkgname}-%{version} -%patch200 -p1 -%endif +%setup -q %build -%if 0%{?gitbuild:1} -./tools/setup -%endif ./configure \ --prefix=%{_prefix} \ --exec-prefix=%{_prefix} \ --libexecdir=%{_prefix}/lib/nagios/plugins \ --sysconfdir=%{_sysconfdir}/nagios \ --datadir=%{_datadir} \ ---with-perl=/usr/bin/perl \ -%if 0%{?centos_version} >= 700 || 0%{?rhel_version} >= 700 || 0%{?rhel} >= 7 || 0%{?sl_version} >= 700 ---with-ping-command="/bin/ping -n -U -w %d -c %d %s" \ -%endif --with-ping6-command="/bin/ping6 -n -U -w %d -c %d %s" \ ---with-fping-command=%{_sbindir}/fping \ ---with-fping6-command=%{_sbindir}/fping6 \ --with-ipv6 \ --with-cgiurl=/nagios/cgi-bin \ --with-rpcinfo-command=%{_sbindir}/rpcinfo \ @@ -165,16 +77,14 @@ %__make AM_INSTALL_PROGRAM_FLAGS="" DESTDIR=${RPM_BUILD_ROOT} install-strip %__make AM_INSTALL_PROGRAM_FLAGS="" DESTDIR=${RPM_BUILD_ROOT} install-root %__install -d ${RPM_BUILD_ROOT}/etc/nagios -##__install -m 664 command.cfg ${RPM_BUILD_ROOT}/etc/nagios -##%find_lang %{name} +%__install -m 664 command.cfg ${RPM_BUILD_ROOT}/etc/nagios +%find_lang %{name} # fix lib path in perl plugins cd ${RPM_BUILD_ROOT}%{_prefix}/lib/nagios/plugins -# set qmail-qstat if not found -# fix lib path in perl plugins -cd ${RPM_BUILD_ROOT}%{_prefix}/lib/nagios/plugins -# set qmail-qstat if not found -sed -i s@'$PATH_TO_QMAIL_QSTAT = "";'@'$PATH_TO_QMAIL_QSTAT = "/var/qmail/bin/qmail-qstat";'@ %{buildroot}%{_prefix}/lib/nagios/plugins/utils.pm -sed -i s@"{'PATH'}='';"@"{'PATH'}='/usr/bin:/usr/sbin';"@ %{buildroot}%{_prefix}/lib/nagios/plugins/check_mailq +# not needed since 1.4.14 +#for PLUGIN in check_breeze check_disk_smb check_file_age check_flexlm check_ifoperstatus check_ifstatus check_ircd check_mailq check_rpc check_wave ; do +# sed -i s@"nagios/plugins"@"%{_prefix}/lib/nagios/plugins"@g ${PLUGIN} +#done %clean rm -rf $RPM_BUILD_ROOT @@ -183,18 +93,15 @@ chmod 4711 %{_exec_prefix}/lib/nagios/plugins/check_icmp || : chmod 4711 %{_exec_prefix}/lib/nagios/plugins/check_dhcp || : -##%files -f %{name}.lang -%files +%files -f %{name}.lang %defattr(-,root,root) -##config(missingok,noreplace) /etc/nagios/command.cfg -%doc CODING COPYING FAQ README REQUIREMENTS SUPPORT -%if 0%{?gitbuild:0} -%doc ChangeLog -%endif +%config(missingok,noreplace) /etc/nagios/command.cfg +%doc CODING COPYING FAQ LEGAL README REQUIREMENTS SUPPORT THANKS +%doc ChangeLog command.cfg %defattr(775,root,root) %dir %{_exec_prefix}/lib/nagios/plugins -%{_datadir}/locale/de/LC_MESSAGES/%{pkgname}.mo -%{_datadir}/locale/fr/LC_MESSAGES/%{pkgname}.mo +%{_datadir}/locale/de/LC_MESSAGES/nagios-plugins.mo +%{_datadir}/locale/fr/LC_MESSAGES/nagios-plugins.mo %{_exec_prefix}/lib/nagios/plugins