procps/procps.spec

197 lines
5.7 KiB
RPMSpec

#
# spec file for package procps (Version 3.2.8)
#
# Copyright (c) 2010 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: procps
BuildRequires: ncurses-devel
BuildRequires: libselinux-devel
Url: http://procps.sf.net
License: GPLv2+ ; LGPLv2.1+
Group: System/Monitoring
PreReq: %fillup_prereq %insserv_prereq
AutoReqProv: on
Version: 3.2.8
Release: 8
Summary: ps utilities for /proc
Provides: ps
Obsoletes: ps
Source: http://procps.sourceforge.net/procps-%version.tar.bz2
Source1: boot.sysctl
Source2: systat.xinetd
Source3: sysctl.conf
Patch: procps-3.2.3-make.diff
Patch1: procps-3.2.2-100cpus.diff
Patch2: procps-3.2.5-eof.diff
Patch3: procps-3.2.2-ia64.diff
Patch4: procps-3.2.7-stealtime.patch
Patch6: procps-3.2.8-manycpus.diff
Patch7: procps-3.2.2-w-notruncate.diff
Patch8: procps-3.2.2-w-simply-work.diff
Patch9: procps-3.2.7-top.1.diff
Patch10: procps-3.2.2-top-termsize.patch
Patch11: procps-3.2.8-buffersize.diff
Patch12: pwdx-bufferoverflow.diff
Patch13: procps-3.2.8-pmap-smaps-rml-2.patch
Patch15: procps-3.2.5-top-rc.patch
Patch16: procps-3.2.7-cpu_hotplug.patch
Patch17: procps-3.2.5-CPU-states.patch
Patch18: procps-3.2.7-readeof.patch
Patch19: procps-3.2.7-btime-from-proc-stat.patch
Patch20: procps-3.2.8-glibc-2.6.1.dif
Patch21: procps-3.2.8-slab.patch
Patch22: procps-3.2.7-selinux.patch
Patch23: procps-3.2.7-accuracy.dif
Patch24: procps-3.2.8-toosmall.dif
Patch25: procps-3.2.7-cgroups_flag.diff
Patch26: procps-3.2.8-pgrep_coption.dif
Patch27: procps-3.2.7-terabyte.dif
Patch28: procps-3.2.6-xen.dif
Patch29: procps-3.2.8-fdleak.dif
Patch30: procps-3.2.8-sysctlerr.dif
Patch31: procps-3.2.8-columns.dif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
The procps package contains a set of system utilities that provide
system information. Procps includes ps, free, skill, snice, tload, top,
uptime, vmstat, w, and watch. The ps command displays a snapshot of
running processes. The top command provides a repetitive update of the
statuses of running processes. The free command displays the amounts of
free and used memory on your system. The skill command sends a
terminate command (or another specified signal) to a specified set of
processes. The snice command is used to change the scheduling priority
of specified processes. The tload command prints a graph of the current
system load average to a specified tty. The uptime command displays the
current time, how long the system has been running, how many users are
logged on, and system load averages for the past one, five, and fifteen
minutes. The w command displays a list of the users who are currently
logged on and what they are running. The watch program watches a
running program. The vmstat command displays virtual memory statistics
about processes, memory, paging, block I/O, traps, and CPU activity.
Authors:
--------
Albert Cahalan <albert@users.sf.net>
(and many more)
%prep
%setup -q
%patch -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p0
%patch6 -p0
%patch7 -p1
%patch8 -p1
%patch9 -p1
%patch10 -p1
%patch11 -p0
%patch12 -p1
%patch13 -p0
%patch15 -p1
%patch16 -p1
%patch17
%patch18
%patch19 -p1
%patch20
%patch21 -p0
%patch22
%patch23
%patch24
%patch25 -p1
%patch26
%patch27
%patch28
%patch29
%patch30
%patch31
%build
make %{?jobs:-j%jobs} CFLAGS="-Wall -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 $RPM_OPT_FLAGS -pipe" \
CC="gcc"
%install
make DESTDIR=$RPM_BUILD_ROOT install
install -d $RPM_BUILD_ROOT/etc/init.d $RPM_BUILD_ROOT/etc/xinetd.d
install -m 755 %SOURCE1 $RPM_BUILD_ROOT/etc/init.d
install -m 644 %SOURCE2 $RPM_BUILD_ROOT/etc/xinetd.d/systat
install -m 644 %SOURCE3 $RPM_BUILD_ROOT/etc
# clean unwanted files (coreutils)
rm -f $RPM_BUILD_ROOT/bin/kill
rm -f $RPM_BUILD_ROOT/usr/bin/uptime
rm -f $RPM_BUILD_ROOT%_mandir/man1/kill.1
rm -f $RPM_BUILD_ROOT%_mandir/man1/uptime.1
mv $RPM_BUILD_ROOT/usr/bin/{pgrep,pkill} $RPM_BUILD_ROOT/bin/
ln -s /bin/pgrep $RPM_BUILD_ROOT/usr/bin/pgrep
ln -s /bin/pkill $RPM_BUILD_ROOT/usr/bin/pkill
%clean
rm -rf $RPM_BUILD_ROOT
%post
%{fillup_and_insserv -ny boot.sysctl boot.sysctl}
%postun
%insserv_cleanup
%files
%defattr (-,root,root,755)
%doc NEWS README COPYING
%config /etc/init.d/boot.sysctl
%config(noreplace) /etc/sysctl.conf
%config(noreplace) /etc/xinetd.d/systat
/bin/ps
/bin/pgrep
/bin/pkill
/sbin/sysctl
/usr/bin/free
/usr/bin/pgrep
/usr/bin/pkill
/usr/bin/pmap
/usr/bin/pwdx
/usr/bin/skill
/usr/bin/slabtop
/usr/bin/snice
/usr/bin/tload
/usr/bin/top
/usr/bin/vmstat
/usr/bin/w
/usr/bin/watch
%_mandir/man1/free.1.gz
%_mandir/man1/pgrep.1.gz
%_mandir/man1/pkill.1.gz
%_mandir/man1/pmap.1.gz
%_mandir/man1/ps.1.gz
%_mandir/man1/pwdx.1.gz
%_mandir/man1/skill.1.gz
%_mandir/man1/slabtop.1.gz
%_mandir/man1/snice.1.gz
%_mandir/man1/tload.1.gz
%_mandir/man1/top.1.gz
%_mandir/man1/w.1.gz
%_mandir/man1/watch.1.gz
%_mandir/man5/sysctl.conf.5.gz
%_mandir/man8/vmstat.8.gz
%_mandir/man8/sysctl.8.gz
%changelog