LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File grep.spec of Package grep (Project home:mbrugger:branches:openSUSE:Factory:RISCV)

# spec file for package grep
# Copyright (c) 2018 SUSE LINUX 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:           grep
Version:        3.1
Release:        0
Summary:        Print lines matching a pattern
License:        GPL-3.0+
Group:          Productivity/Text/Utilities
Url:            https://www.gnu.org/software/grep/
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
BuildRequires:  fdupes
BuildRequires:  makeinfo
BuildRequires:  pcre-devel
Requires(pre):  %{install_info_prereq}
Requires(preun): %{install_info_prereq}
Recommends:     %{name}-lang
Provides:       base:%{_bindir}/grep

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.


%setup -q

%configure \
  --disable-silent-rules \
%if %{do_profiling}
  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}"
  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_generate}" check
  make clean
  make %{?_smp_mflags} CFLAGS="%{optflags} %{cflags_profile_feedback}"
  make %{?_smp_mflags} CFLAGS="%{optflags}"

make %{?_smp_mflags} check

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
%fdupes -s %{buildroot}
%find_lang %{name}

%install_info --info-dir=%{_infodir} %{_infodir}/grep.info%{ext_info}

%install_info_delete --info-dir=%{_infodir} %{_infodir}/grep.info%{ext_info}

%license COPYING

%files lang -f %{name}.lang