Search
j0ke.net Open Build Service
>
Projects
>
server:monitoring
>
nagios32
> Changes
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
Changes of Revision 7
[-]
[+]
Added
nagios.spec
@@ -0,0 +1,481 @@ +# +# spec file for package nagios (Version 3.2.0) +# +# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + +# norootforbuild + + +Name: nagios +%define realname nagios +%define nsusr nagios +%define nsgrp nagios +%define cmdusr wwwrun +%define cmdgrp nagcmd +%define nslockfile_dir /var/run/%{realname} +%define nslockfile %nslockfile_dir/%{realname}.pid +%define apache2_sysconfdir %(/usr/sbin/apxs2 -q SYSCONFDIR)/conf.d +# Macro that print mesages to syslog at package (un)install time +%define nnmmsg logger -t %{realname}/rpm +Summary: The Nagios Network Monitor +Version: 3.2.0 +Release: 1 +License: GPL v2 or later +Group: System/Monitoring +Url: http://www.nagios.org/ +Source0: %{realname}-%{version}.tar.bz2 +Source1: rc%{name} +Source2: %{name}-rpmlintrc +Source3: %{name}.sysconfig +Source4: suse.de-nagios +Source10: %{name}-README.SuSE +# +Patch1: nagios.run_async_service_check.return.patch +Patch10: nagios-p1.pl-location.patch +# +BuildRoot: %{_tmppath}/%{name}-%{version}-build +PreReq: %insserv_prereq +PreReq: %fillup_prereq +PreReq: /bin/logger +PreReq: coreutils +PreReq: grep +PreReq: pwdutils +PreReq: sed +BuildRequires: apache2-devel +BuildRequires: freetype2-devel +BuildRequires: gd-devel +BuildRequires: iputils +BuildRequires: libjpeg-devel +BuildRequires: libpng-devel +BuildRequires: mailx +BuildRequires: openssl-devel +BuildRequires: pcre-devel +BuildRequires: zlib-devel +%if 0%{?suse_version} < 1010 +BuildRequires: XFree86-devel +BuildRequires: XFree86-libs +BuildRequires: libapr0 +Requires: cron +%else +BuildRequires: libapr-util1-devel +BuildRequires: xorg-x11-devel +Recommends: cron +Recommends: %{name}-www +# we enable nagios embedded perl, but if people disable it... +Recommends: perl = %{perl_version} +%endif +%if 0%{?suse_version} > 1020 +BuildRequires: fdupes +%endif +Requires: mailx %{realname}-plugins + +%description +Nagios is a program that will monitor hosts and services on your +network. It has the ability to email or page you when a problem arises +and when a problem is resolved. Nagios is written in C and is designed +to run under Linux (and some other *NIX variants) as a background +process, intermittently running checks on various services that you +specify. + +The actual service checks are performed by separate "plugin" programs +which return the status of the checks to Nagios. The plugins are +available at http://sourceforge.net/projects/nagiosplug + +This package provide core programs for nagios. The web interface, +documentation, and development files are built as separate packages + + + +Authors: +-------- + Ethan Galstad <nagios@nagios.org> + +%package www +License: GPL v2 or later +Group: System/Monitoring +Summary: Provides the HTML and CGI files for the Nagios web interface +Requires: %{name} = %{version} +Requires: gd php5 mod_php_any +PreReq: apache2 +PreReq: coreutils +PreReq: pwdutils +PreReq: /bin/logger +PreReq: sed +PreReq: grep +PreReq: gawk + +%description www +Nagios is a program that will monitor hosts and services on your +network. It has the ability to email or page you when a problem arises +and when a problem is resolved. Nagios is written in C and is designed +to run under Linux (and some other *NIX variants) as a background +process, intermittently running checks on various services that you +specify. + +Several CGI programs are included with Nagios in order to allow you to +view the current service status, problem history, notification history, +and log file via the web. This package provides the HTML and CGI files +for the Nagios web interface. In addition, HTML documentation is +included in this package. + + + +Authors: +-------- + Ethan Galstad <nagios@nagios.org> + +%package devel +License: GPL v2 or later +Group: Development/Libraries/C and C++ +Summary: Development files for nagios +Requires: %{name} = %{version} +Requires: gcc + +%description devel +Nagios is a program that will monitor hosts and services on your +network. It has the ability to email or page you when a problem arises +and when a problem is resolved. Nagios is written in C and is designed +to run under Linux (and some other *NIX variants) as a background +process, intermittently running checks on various services that you +specify. + +This package provides include files that Nagios-related applications +may compile against. + + + +Authors: +-------- + Ethan Galstad <nagios@nagios.org> + +%prep +%setup -q -n %{realname}-%{version} +%patch1 -p1 +%patch10 +find -name ".cvsignore" | xargs rm +find -name ".gitignore" | xargs rm + +%build +# if the following command fails, then apache dependencies are not met +/usr/sbin/apxs2 -q DATADIR >/dev/null +%configure \ + --prefix=%{_prefix} \ + --exec-prefix=%{_sbindir} \ + --bindir=%{_sbindir} \ + --sbindir=%{_prefix}/lib/%{realname}/cgi \ + --libexecdir=%{_prefix}/lib/%{realname}/plugins \ + --datadir=%{_datadir}/%{realname} \ + --sysconfdir=%{_sysconfdir}/%{realname} \ + --with-init-dir=%{_sysconfdir}/init.d \ + --localstatedir=/var/lib/%{realname} \ + --with-cgiurl=/%{realname}/cgi-bin \ + --with-htmurl=/%{realname} \ + --with-httpd-conf=%{apache2_sysconfdir} \ + --with-checkresult-dir=/var/spool/%{realname} \ + --with-lockfile=%{nslockfile} \ + --with-nagios-user=%{nsusr} \ + --with-nagios-group=%{nsgrp} \ + --with-command-user=%{cmdusr} \ + --with-command-grp=%{cmdgrp} \ + --with-gd-lib=%{_libdir} \ + --with-gd-inc=%{_includedir} \ + --with-template-objects \ + --with-template-extinfo \ + --with-perlcache \ + --enable-event-broker \ + --enable-embedded-perl +#