3
0
forked from pool/findutils
findutils/findutils.spec

153 lines
4.3 KiB
RPMSpec
Raw Normal View History

#
# spec file for package findutils (Version 4.4.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/
#
Name: findutils
%if %suse_version > 1100
BuildRequires: libselinux-devel
%endif
Url: http://www.gnu.org/software/findutils/
License: GFDL v1.2 ; GPL v3 or later
Group: Productivity/File utilities
Provides: find
Obsoletes: find
AutoReqProv: on
PreReq: %{install_info_prereq}
Version: 4.4.0
Release: 45
Summary: GNU find--Finding Files
Source: findutils-%{version}.tar.bz2
Source1: sysconfig.locate
Source2: cron.daily.updatedb
Patch: findutils-%{version}.diff
Patch1: findutils-selinux.diff
Patch2: findutils-null.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
This package contains GNU find and xargs. The programs comply with
POSIX 1003.2. They also support additional options, some borrowed from
Unix and some unique to GNU.
Authors:
--------
David J. MacKenzie <djm@gnu.org>
Jan Brittenson <bson@gnu.org>
Brian L. Matthews <blm@6sceng.UUCP>
Mike Rendell <michael@cs.mun.ca>
James A. Woods <jwoods@adobe.com>
Jay Plett <jay@silence.princeton.nj.us>
Tim Wood <tim@toad.com>
%package locate
License: GPL v3 or later
Summary: Tool for Locating Files (GNU Findutils Subpackage)
Group: Productivity/File utilities
Provides: findutils:/usr/bin/locate
AutoReqProv: on
PreReq: %fillup_prereq
Requires: cron
%description locate
This package contains the locate program which is part of the GNU
findutils software suite.
You can find files fast using locate. On installing findutils-locate
an additional daily cron job will be added to the cron system. This
job will update the files database every night or shortly after
switching on the computer.
Authors:
--------
David J. MacKenzie <djm@gnu.org>
Jan Brittenson <bson@gnu.org>
Brian L. Matthews <blm@6sceng.UUCP>
Mike Rendell <michael@cs.mun.ca>
James A. Woods <jwoods@adobe.com>
Jay Plett <jay@silence.princeton.nj.us>
Tim Wood <tim@toad.com>
%prep
%setup -q
%patch
%patch1 -p1
%patch2 -p0
%build
%ifarch %arm armv5tel armv7l armv7el armv5el
# this is a workaround for a qemu-user bug, we hit. A qemu patch is being discussed, but for now ...
DEFAULT_ARG_SIZE="(31u * 1024u)" \
%endif
./configure CFLAGS="$RPM_OPT_FLAGS" \
--prefix=%{_prefix} --libexecdir=%{_libdir}/find \
--localstatedir=/var/lib \
--infodir=%{_infodir} --mandir=%{_mandir} \
--without-included-regex \
--without-fts \
--enable-d_type-optimisation
make
%install
make install DESTDIR=$RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/var/adm/fillup-templates
mkdir -p $RPM_BUILD_ROOT/etc/cron.daily
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT/var/adm/fillup-templates
install -m 755 %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.daily/suse.de-updatedb
%find_lang %name
rm -f $RPM_BUILD_ROOT%{_bindir}/oldfind
rm -f $RPM_BUILD_ROOT%{_bindir}/ftsfind
rm -f $RPM_BUILD_ROOT%{_infodir}/find-maint*
%clean
rm -rf $RPM_BUILD_ROOT
%post locate
%{fillup_only -n locate}
%post
%install_info --info-dir=%{_infodir} %{_infodir}/find.info.gz
%postun
%install_info_delete --info-dir=%{_infodir} %{_infodir}/find.info.gz
%files -f %name.lang
%defattr(-,root,root,755)
%doc README NEWS AUTHORS TODO
%{_bindir}/find
%{_bindir}/xargs
%doc %{_infodir}/find.info*.gz
%doc %{_mandir}/man1/find.1.gz
%doc %{_mandir}/man1/xargs.1.gz
%files locate
%defattr(-,root,root,755)
/etc/cron.daily/*
%{_bindir}/locate
%{_bindir}/updatedb
%{_libdir}/find
%doc %{_mandir}/man1/locate.1.gz
%doc %{_mandir}/man1/updatedb.1.gz
%doc %{_mandir}/man5/locatedb.5.gz
/var/adm/fillup-templates/*
%changelog