From faf44050886e84bd073dc020d9bee64f0134e11574b1580c61586ad54c8d245b Mon Sep 17 00:00:00 2001 From: Lars Vogdt Date: Wed, 30 Jul 2014 22:38:06 +0000 Subject: [PATCH] - rename subpackage to monitoring-plugins-postgres OBS-URL: https://build.opensuse.org/package/show/server:monitoring/check_postgres?expand=0&rev=8 --- check_postgres.changes | 5 +++++ check_postgres.spec | 30 +++++++++++++++++++----------- 2 files changed, 24 insertions(+), 11 deletions(-) diff --git a/check_postgres.changes b/check_postgres.changes index bcc6a39..7a4a17f 100644 --- a/check_postgres.changes +++ b/check_postgres.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Jul 30 22:37:22 UTC 2014 - lars@linux-schulserver.de + +- rename subpackage to monitoring-plugins-postgres + ------------------------------------------------------------------- Tue Oct 29 11:12:46 UTC 2013 - lars@linux-schulserver.de diff --git a/check_postgres.spec b/check_postgres.spec index d4734ce..e61c3c7 100644 --- a/check_postgres.spec +++ b/check_postgres.spec @@ -1,4 +1,8 @@ # +# spec file for package check_postgres +# +# Copyright (c) 2014 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 @@ -8,7 +12,9 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# needsrootforbuild +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + Name: check_postgres Summary: Postgres monitoring script @@ -21,6 +27,7 @@ Source0: %{name}-%{version}.tar.bz2 Source1: nagios-commands-postgres.cfg Source2: create_manpage.pl Requires: postgresql +BuildRequires: nagios-rpm-macros BuildRequires: perl(DBD::Pg) BuildRequires: perl(DBI) BuildRequires: perl(Data::Dumper) @@ -45,7 +52,6 @@ Recommends: coreutils Recommends: util-linux BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build -%define libexecdir %_prefix/lib/nagios/plugins %description check_postgres.pl is a Perl script that runs many different tests against one @@ -57,14 +63,16 @@ Author: Greg Sabino Mullane -%package -n nagios-plugins-postgres +%package -n monitoring-plugins-postgres Summary: Postgres monitoring script using check_postgres.pl Group: System/Monitoring PreReq: %{name} = %{version} +Provides: nagios-plugins-postgres = %{version}-%{release} +Obsoletes: nagios-plugins-postgres < %{version}-%{release} -%description -n nagios-plugins-postgres +%description -n monitoring-plugins-postgres This package contains the symlinks to execute special checks via the standard -Nagios plugins way. +monitoring plugins way. %prep %setup -q @@ -84,8 +92,8 @@ make %{?jobs:-j%jobs} %{__rm} -rf $RPM_BUILD_ROOT%perl_archlib %perl_gen_filelist # create symlinks for nagios-plugins-postgres package -mkdir -p %{buildroot}%{libexecdir} -pushd %{buildroot}%{libexecdir} +mkdir -p %{buildroot}%{nagios_plugindir} +pushd %{buildroot}%{nagios_plugindir} %{buildroot}%{_bindir}/check_postgres.pl --symlinks # fix symlinks, as they point to the buildroot for link in *; do @@ -105,11 +113,11 @@ rm -rf %buildroot %doc MANIFEST README TODO nagios-commands-postgres.cfg check_postgres.pl.html %{_mandir}/man1/check_postgres.pl.1* -%files -n nagios-plugins-postgres +%files -n monitoring-plugins-postgres %defattr(-,root,root) # avoid build dependecy of nagios - own the dirs -%dir %_prefix/lib/nagios -%dir %libexecdir -%libexecdir/* +%dir %{nagios_libdir} +%dir %{nagios_plugindir} +%{nagios_plugindir}/* %changelog