From cdd5160fce1a61c8fb1d9dbee0831ddd75fca5b3e027e69204a89dd60871bb92 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Tue, 26 Mar 2013 14:44:17 +0000 Subject: [PATCH] Split util-linux for SRPM clarity (resend of sr#149338) OBS-URL: https://build.opensuse.org/package/show/Base:System/time?expand=0&rev=1 --- .gitattributes | 23 +++++++++++++++++ time-1.7.diff | 26 +++++++++++++++++++ time-1.7.tar.bz2 | 3 +++ time.changes | 4 +++ time.spec | 65 ++++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 121 insertions(+) create mode 100644 .gitattributes create mode 100644 time-1.7.diff create mode 100644 time-1.7.tar.bz2 create mode 100644 time.changes create mode 100644 time.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/time-1.7.diff b/time-1.7.diff new file mode 100644 index 0000000..43349d8 --- /dev/null +++ b/time-1.7.diff @@ -0,0 +1,26 @@ +--- + resuse.h | 4 ++++ + 1 file changed, 4 insertions(+) + +Index: time-1.7/resuse.h +=================================================================== +--- time-1.7.orig/resuse.h ++++ time-1.7/resuse.h +@@ -39,6 +39,9 @@ struct timeval + # if HAVE_WAIT3 + # include + # else ++# if defined(__linux__) && defined(__alpha__) ++# include ++# else + /* Process resource usage structure. */ + struct rusage + { +@@ -49,6 +52,7 @@ struct rusage + ru_oublock, ru_msgsnd, ru_msgrcv, ru_nsignals, + ru_nvcsw, ru_nivcsw; + }; ++# endif + # endif + #endif + diff --git a/time-1.7.tar.bz2 b/time-1.7.tar.bz2 new file mode 100644 index 0000000..b5ed718 --- /dev/null +++ b/time-1.7.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:83eeec8df47e4c939a09b0147c34a36462bb2762f879596e9089b2817dcff7e2 +size 92620 diff --git a/time.changes b/time.changes new file mode 100644 index 0000000..1983692 --- /dev/null +++ b/time.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Sun Jan 20 21:21:13 UTC 2013 - jengelh@inai.de + +- Split "time" off util-linux diff --git a/time.spec b/time.spec new file mode 100644 index 0000000..e1fa745 --- /dev/null +++ b/time.spec @@ -0,0 +1,65 @@ +# +# spec file for package time +# +# Copyright (c) 2013 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/ +# + + +Name: time +Version: 1.7 +Release: 0 +Summary: Time a simple command or give resource usage +License: GPL-2.0+ +Group: System/Base +Url: http://www.gnu.org/software/time/ + +Source: %name-%version.tar.bz2 +Patch1: time-1.7.diff +BuildRoot: %{_tmppath}/%{name}-%{version}-build +PreReq: %install_info_prereq +Provides: util-linux:/usr/bin/time + +%description +The "time" command runs another program, then displays information +about the resources used by that program, collected by the system +while the program was running. + +%prep +%setup -q +%patch -P 1 -p1 + +%build +export CFLAGS="%optflags -D_GNU_SOURCE " +export INSTALL_PROGRAM='$(INSTALL)' +%configure +make %{?_smp_mflags} + +%install +make install DESTDIR="%buildroot" prefix="%buildroot/%_prefix" \ + bindir="%buildroot/%_bindir" mandir="%buildroot/%_mandir" \ + infodir="%buildroot/%_infodir" + +%post +%install_info --entry="* time: (time). summarizing used system resources" --info-dir="%_infodir" "%_infodir/time.info.gz" + +%postun +%install_info_delete --info-dir="%_infodir" "%_infodir/time.info.gz" + +%files +%defattr(-,root,root) +%_bindir/time +%doc AUTHORS COPYING NEWS README +%_infodir/time.info*.gz + +%changelog