2006-12-19 00:16:42 +01:00
|
|
|
#
|
2011-08-11 10:08:30 +02:00
|
|
|
# spec file for package grep
|
2006-12-19 00:16:42 +01:00
|
|
|
#
|
2020-01-21 13:43:52 +01:00
|
|
|
# Copyright (c) 2020 SUSE LLC
|
2006-12-19 00:16:42 +01:00
|
|
|
#
|
2008-08-21 17:53:30 +02:00
|
|
|
# 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.
|
|
|
|
|
2019-01-07 16:05:24 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2006-12-19 00:16:42 +01:00
|
|
|
#
|
|
|
|
|
2012-03-14 11:21:46 +01:00
|
|
|
|
2006-12-19 00:16:42 +01:00
|
|
|
Name: grep
|
2020-11-23 11:53:34 +01:00
|
|
|
Version: 3.6
|
2011-12-01 16:53:45 +01:00
|
|
|
Release: 0
|
2006-12-19 00:16:42 +01:00
|
|
|
Summary: Print lines matching a pattern
|
2018-08-07 09:30:15 +02:00
|
|
|
License: GPL-3.0-or-later
|
2012-02-07 11:09:11 +01:00
|
|
|
Group: Productivity/Text/Utilities
|
2020-01-21 13:43:52 +01:00
|
|
|
URL: https://www.gnu.org/software/grep/
|
2017-06-05 20:55:41 +02:00
|
|
|
Source0: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz
|
|
|
|
Source2: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig
|
|
|
|
Source3: https://savannah.gnu.org/project/memberlist-gpgkeys.php?group=grep&download=1#/%{name}.keyring
|
2020-07-01 14:12:03 +02:00
|
|
|
Source4: profile.sh
|
2020-11-23 11:53:34 +01:00
|
|
|
Patch0: werror-return-type.patch
|
2017-02-13 13:43:49 +01:00
|
|
|
BuildRequires: fdupes
|
2014-02-19 13:44:11 +01:00
|
|
|
BuildRequires: makeinfo
|
|
|
|
BuildRequires: pcre-devel
|
2014-05-24 19:06:08 +02:00
|
|
|
Requires(pre): %{install_info_prereq}
|
2016-02-05 21:31:40 +01:00
|
|
|
Requires(preun): %{install_info_prereq}
|
2014-05-24 19:06:08 +02:00
|
|
|
Provides: base:%{_bindir}/grep
|
2014-02-19 13:44:11 +01:00
|
|
|
|
2006-12-19 00:16:42 +01:00
|
|
|
%description
|
2017-02-13 13:43:49 +01:00
|
|
|
The grep command searches one or more input files for lines containing a
|
|
|
|
match to a specified pattern. By default, grep prints the matching lines.
|
|
|
|
|
|
|
|
%lang_package
|
2006-12-19 00:16:42 +01:00
|
|
|
|
|
|
|
%prep
|
2007-10-03 00:55:33 +02:00
|
|
|
%setup -q
|
2020-11-23 11:53:34 +01:00
|
|
|
%patch0 -p1
|
2006-12-19 00:16:42 +01:00
|
|
|
|
2012-04-20 06:49:24 +02:00
|
|
|
%build
|
2017-06-05 20:55:41 +02:00
|
|
|
%configure \
|
|
|
|
--disable-silent-rules \
|
2020-01-21 13:43:52 +01:00
|
|
|
--without-included-regex \
|
2019-01-07 16:05:24 +01:00
|
|
|
%{nil}
|
2018-11-12 09:14:47 +01:00
|
|
|
%if 0%{?do_profiling}
|
2020-07-01 14:12:03 +02:00
|
|
|
make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}"
|
|
|
|
sh %{SOURCE4} # profiling run
|
2017-06-05 20:55:41 +02:00
|
|
|
make clean
|
|
|
|
make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_feedback}"
|
|
|
|
%else
|
|
|
|
make %{?_smp_mflags} CFLAGS="%{optflags}"
|
|
|
|
%endif
|
2009-06-05 22:56:59 +02:00
|
|
|
|
|
|
|
%check
|
2017-06-05 20:55:41 +02:00
|
|
|
make %{?_smp_mflags} check
|
2006-12-19 00:16:42 +01:00
|
|
|
|
|
|
|
%install
|
2017-02-13 13:43:49 +01:00
|
|
|
%make_install
|
2020-11-26 11:08:54 +01:00
|
|
|
%if !0%{?usrmerged}
|
2012-08-24 20:47:51 +02:00
|
|
|
install -d %{buildroot}/bin
|
|
|
|
ln -sf %{_bindir}/egrep %{buildroot}/bin/egrep
|
|
|
|
ln -sf %{_bindir}/fgrep %{buildroot}/bin/fgrep
|
|
|
|
ln -sf %{_bindir}/grep %{buildroot}/bin/grep
|
2020-11-26 11:08:54 +01:00
|
|
|
%endif
|
2017-02-13 13:43:49 +01:00
|
|
|
%fdupes -s %{buildroot}
|
2014-02-19 13:44:11 +01:00
|
|
|
%find_lang %{name}
|
2006-12-19 00:16:42 +01:00
|
|
|
|
|
|
|
%post
|
2017-02-13 13:43:49 +01:00
|
|
|
%install_info --info-dir=%{_infodir} %{_infodir}/grep.info%{ext_info}
|
2006-12-19 00:16:42 +01:00
|
|
|
|
2016-02-05 21:31:40 +01:00
|
|
|
%preun
|
2017-02-13 13:43:49 +01:00
|
|
|
%install_info_delete --info-dir=%{_infodir} %{_infodir}/grep.info%{ext_info}
|
2006-12-19 00:16:42 +01:00
|
|
|
|
2017-02-13 13:43:49 +01:00
|
|
|
%files
|
2006-12-19 00:16:42 +01:00
|
|
|
%defattr(-,root,root)
|
2018-02-26 10:37:58 +01:00
|
|
|
%license COPYING
|
|
|
|
%doc README AUTHORS NEWS THANKS TODO ChangeLog*
|
2020-11-26 11:08:54 +01:00
|
|
|
%if !0%{?usrmerged}
|
2012-02-07 11:09:11 +01:00
|
|
|
/bin/egrep
|
|
|
|
/bin/fgrep
|
|
|
|
/bin/grep
|
2020-11-26 11:08:54 +01:00
|
|
|
%endif
|
2017-02-13 13:43:49 +01:00
|
|
|
%{_bindir}/egrep
|
|
|
|
%{_bindir}/fgrep
|
|
|
|
%{_bindir}/grep
|
|
|
|
%{_mandir}/man1/egrep.1%{ext_man}
|
|
|
|
%{_mandir}/man1/fgrep.1%{ext_man}
|
|
|
|
%{_mandir}/man1/grep.1%{ext_man}
|
|
|
|
%{_infodir}/grep.info%{ext_info}
|
|
|
|
|
|
|
|
%files lang -f %{name}.lang
|
|
|
|
%defattr(-,root,root)
|
2007-11-28 23:12:05 +01:00
|
|
|
|
2007-03-22 20:43:58 +01:00
|
|
|
%changelog
|