- cleaned .spec file

This commit is contained in:
Peter Schiffer 2012-11-13 14:56:51 +01:00
parent 163f926520
commit 15be2fd9e8

View File

@ -1,43 +1,59 @@
Summary: Collection of performance monitoring tools for Linux
Name: sysstat
Version: 10.1.2
Release: 1%{?dist}
Summary: The sar and iostat system monitoring commands
License: GPLv2+
Group: Applications/System
URL: http://sebastien.godard.pagesperso-orange.fr/
Source0: http://pagesperso-orange.fr/sebastien.godard/%{name}-%{version}.tar.bz2
Patch12: sysstat-10.0.0-makefile.patch
Requires: sh-utils textutils grep fileutils /etc/cron.d
BuildRequires: lm_sensors-devel
BuildRequires: perl %{_includedir}/linux/if.h gettext
BuildRequires: autoconf automake
BuildRequires: systemd-units
Source: http://pagesperso-orange.fr/sebastien.godard/%{name}-%{version}.tar.bz2
Patch0: sysstat-10.0.0-makefile.patch
Requires: /etc/cron.d, fileutils, grep, sh-utils, textutils
Requires(post): systemd, systemd-sysv
Requires(preun): systemd
Requires(postun): systemd
BuildRequires: %{_includedir}/linux/if.h, gettext, lm_sensors-devel, perl
%description
This package provides the sar and iostat commands for Linux. Sar and
iostat enable system monitoring of disk, network, and other IO
activity.
The sysstat package contains sar, sadf, mpstat, iostat, pidstat, nfsiostat,
cifsiostat and sa tools for Linux.
The sar command collects and reports system activity information. This
information can be saved in a file in a binary format for future inspection. The
statistics reported by sar concern I/O transfer rates, paging activity,
process-related activities, interrupts, network activity, memory and swap space
utilization, CPU utilization, kernel activities and TTY statistics, among
others. Both UP and SMP machines are fully supported.
The sadf command may be used to display data collected by sar in various formats
(CSV, XML, etc.).
The iostat command reports CPU utilization and I/O statistics for disks.
The mpstat command reports global and per-processor statistics.
The pidstat command reports statistics for Linux tasks (processes).
The nfsiostat command reports I/O statistics for network file systems.
The cifsiostat command reports I/O statistics for CIFS file systems.
%prep
%setup -q
%patch12 -p1 -b .ls
%patch0 -p1 -b .ls
iconv -f windows-1252 -t utf8 CREDITS > CREDITS.aux
mv CREDITS.aux CREDITS
%build
history=28 compressafter=31 ./configure --prefix=%{_prefix} --disable-man-group sa_lib_dir=%{_libdir}/sa --libdir=%{_libdir} --enable-collect-all
%configure sa_lib_dir=%{_libdir}/sa history=28 compressafter=31 \
--disable-man-group \
--enable-collect-all
CFLAGS="$RPM_OPT_FLAGS -DSADC_PATH=\\\"%{_libdir}/sa/sadc\\\""
make CFLAGS="$CFLAGS" LFLAGS=""
make CFLAGS="$CFLAGS" LFLAGS="" %{?_smp_mflags}
%install
make install
make install DESTDIR=%{buildroot}
# Install cron file
mkdir -p %{buildroot}/%{_sysconfdir}/cron.d
install -m 0644 cron/sysstat.crond %{buildroot}/%{_sysconfdir}/cron.d/sysstat
# Install service file
mkdir -p %{buildroot}%{_unitdir}
install -m 0644 sysstat.service %{buildroot}%{_unitdir}/
@ -48,7 +64,7 @@ install -m 0644 sysstat.service %{buildroot}%{_unitdir}/
%preun
%systemd_preun sysstat.service
if [ $1 -eq 0 ]; then
if [[ $1 -eq 0 ]]; then
# Remove sa logs if removing sysstat completely
rm -f %{_localstatedir}/log/sa/*
fi
@ -66,7 +82,6 @@ fi
/sbin/chkconfig --del sysstat >/dev/null 2>&1 || :
/bin/systemctl try-restart sysstat.service >/dev/null 2>&1 || :
%files -f %{name}.lang
%doc CHANGES COPYING CREDITS README FAQ
%config(noreplace) %{_sysconfdir}/cron.d/sysstat
@ -86,6 +101,7 @@ fi
updated to 10.1.2
- resolves: #850333
migrated to the new systemd-rpm macros
- cleaned .spec file
* Wed Aug 01 2012 Peter Schiffer <pschiffe@redhat.com> - 10.1.1-1
- resolves: #844387