2006-12-19 00:17:47 +01:00
|
|
|
#
|
2011-11-30 15:27:48 +01:00
|
|
|
# spec file for package sed
|
2006-12-19 00:17:47 +01:00
|
|
|
#
|
2015-08-27 18:10:55 +02:00
|
|
|
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
2006-12-19 00:17:47 +01:00
|
|
|
#
|
2009-06-18 17:51:22 +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.
|
|
|
|
|
2006-12-19 00:17:47 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2012-02-07 13:58:46 +01:00
|
|
|
|
2006-12-19 00:17:47 +01:00
|
|
|
Name: sed
|
2013-01-22 18:57:26 +01:00
|
|
|
Version: 4.2.2
|
2011-11-30 15:27:48 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: A Stream-Oriented Non-Interactive Text Editor
|
2012-02-06 22:10:47 +01:00
|
|
|
License: GPL-3.0+
|
2006-12-19 00:17:47 +01:00
|
|
|
Group: System/Base
|
2013-01-22 18:57:26 +01:00
|
|
|
Url: http://www.gnu.org/software/sed/
|
2013-04-06 03:03:49 +02:00
|
|
|
Source: ftp://ftp.gnu.org/gnu/sed/%{name}-%{version}.tar.bz2
|
2013-01-22 18:57:26 +01:00
|
|
|
Source1: %{name}-%{version}.tar.bz2.sig
|
|
|
|
Source2: %{name}.keyring
|
2014-07-03 16:56:24 +02:00
|
|
|
# PATCH-FIX-SLE sed-dont_close_twice.patch bnc@880817 tcech@suse.cz -- Fix double close.
|
|
|
|
Patch: sed-dont_close_twice.patch
|
2015-08-27 18:10:55 +02:00
|
|
|
# PATCH-FIX-UPSTREAM sed-follow-symlinks-hyphen.patch bnc933029 gnu20796 sbrabec@suse.com -- Make behavior of "sed --follow-symlinks -" consistent again.
|
|
|
|
Patch1: sed-follow-symlinks-hyphen.patch
|
|
|
|
# PATCH-FIX-UPSTREAM sed-follow-symlinks-stdin.patch bnc933029 gnu20795 sbrabec@suse.com -- Fix --follow-symlinks on stdin.
|
|
|
|
Patch2: sed-follow-symlinks-stdin.patch
|
|
|
|
# PATCH-FIX-UPSTREAM sed-y-NUL-RHS.patch sbrabec@suse.com -- Fix y command in the RHS of a y/LHS/RHS/ transliteration.
|
|
|
|
Patch3: sed-y-NUL-RHS.patch
|
|
|
|
# PATCH-FIX-UPSTREAM sed-fix-overlapping-address-ranges.patch sbrabec@suse.com -- Fix mishandling of overlapping address ranges.
|
|
|
|
Patch4: sed-fix-overlapping-address-ranges.patch
|
|
|
|
# PATCH-FIX-UPSTREAM sed-temp-delete.patch sbrabec@suse.com -- Fix fail to remove a temporary file.
|
|
|
|
Patch5: sed-temp-delete.patch
|
2013-01-22 18:57:26 +01:00
|
|
|
# Use rpmbuild -D 'VERIFY_SIG 1' to verify signature during build or run one-shot check by "gpg-offline --verify --package=sed sed-*.sig".
|
|
|
|
%if 0%{?VERIFY_SIG}
|
|
|
|
BuildRequires: gpg-offline
|
|
|
|
%endif
|
2011-11-30 15:27:48 +01:00
|
|
|
PreReq: %install_info_prereq
|
|
|
|
Provides: base:/bin/sed
|
2013-01-22 18:57:26 +01:00
|
|
|
Recommends: %{name}-lang
|
2006-12-19 00:17:47 +01:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
2008-02-19 02:34:00 +01:00
|
|
|
Sed takes text input, performs one or more operations on it, and
|
|
|
|
outputs the modified text. Sed is typically used for extracting parts
|
|
|
|
of a file using pattern matching or for substituting multiple
|
2007-03-11 00:09:22 +01:00
|
|
|
occurrences of a string within a file.
|
2006-12-19 00:17:47 +01:00
|
|
|
|
2013-01-22 18:57:26 +01:00
|
|
|
%lang_package
|
2006-12-19 00:17:47 +01:00
|
|
|
%prep
|
2013-01-22 18:57:26 +01:00
|
|
|
%if 0%{?VERIFY_SIG}
|
|
|
|
%gpg_verify %{S:1}
|
|
|
|
%endif
|
2006-12-19 00:17:47 +01:00
|
|
|
%setup -q
|
2014-07-03 16:56:24 +02:00
|
|
|
%patch -p1
|
2015-08-27 18:10:55 +02:00
|
|
|
%patch1 -p1
|
|
|
|
%patch2 -p1
|
|
|
|
%patch3 -p1
|
|
|
|
%patch4 -p1
|
|
|
|
%patch5 -p1
|
2006-12-19 00:17:47 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
%define warn_flags -Wall -Wstrict-prototypes -Wpointer-arith -Wformat-security
|
2014-12-31 15:00:19 +01:00
|
|
|
export CFLAGS="%{optflags} %warn_flags -fPIE"
|
|
|
|
export LDFLAGS="-pie"
|
2006-12-19 00:17:47 +01:00
|
|
|
./configure --prefix=/usr \
|
2013-04-06 03:03:49 +02:00
|
|
|
--mandir=%{_mandir} \
|
|
|
|
--infodir=%{_infodir} \
|
|
|
|
--without-included-regex \
|
|
|
|
%{_target_cpu}-suse-linux
|
2006-12-19 00:17:47 +01:00
|
|
|
%if %do_profiling
|
2010-07-30 15:50:49 +02:00
|
|
|
make %{?_smp_mflags} CFLAGS="$CFLAGS "%cflags_profile_generate
|
|
|
|
make %{?_smp_mflags} check
|
2006-12-19 00:17:47 +01:00
|
|
|
make clean
|
2010-07-30 15:50:49 +02:00
|
|
|
make %{?_smp_mflags} CFLAGS="$CFLAGS "%cflags_profile_feedback
|
2006-12-19 00:17:47 +01:00
|
|
|
%else
|
2010-07-30 15:50:49 +02:00
|
|
|
make %{?_smp_mflags}
|
2006-12-19 00:17:47 +01:00
|
|
|
%endif
|
2010-07-30 15:50:49 +02:00
|
|
|
make %{?_smp_mflags} check
|
2006-12-19 00:17:47 +01:00
|
|
|
|
|
|
|
%install
|
2008-02-19 02:34:00 +01:00
|
|
|
%makeinstall
|
2012-02-06 22:10:47 +01:00
|
|
|
#UsrMerge
|
2011-11-30 15:27:48 +01:00
|
|
|
mkdir -p %{buildroot}/bin
|
2012-02-06 22:10:47 +01:00
|
|
|
ln -s %{_bindir}/sed %{buildroot}/bin/sed
|
|
|
|
#EndUserMerge
|
2013-01-22 18:57:26 +01:00
|
|
|
%find_lang %{name}
|
2006-12-19 00:17:47 +01:00
|
|
|
|
2013-01-22 18:57:26 +01:00
|
|
|
%files
|
2006-12-19 00:17:47 +01:00
|
|
|
%defattr(-, root, root)
|
|
|
|
/bin/sed
|
2011-11-30 15:27:48 +01:00
|
|
|
%{_bindir}/sed
|
2012-02-06 22:10:47 +01:00
|
|
|
%doc AUTHORS BUGS COPYING* NEWS README* THANKS
|
2013-01-22 18:57:26 +01:00
|
|
|
%doc %{_infodir}/sed.info*.gz
|
|
|
|
%doc %{_mandir}/man*/*.gz
|
|
|
|
|
|
|
|
%files lang -f %{name}.lang
|
2006-12-19 00:17:47 +01:00
|
|
|
|
|
|
|
%post
|
2011-11-30 15:27:48 +01:00
|
|
|
%install_info --info-dir=%{_infodir} %{_infodir}/%name.info.gz
|
2006-12-19 00:17:47 +01:00
|
|
|
|
|
|
|
%postun
|
2011-11-30 15:27:48 +01:00
|
|
|
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%name.info.gz
|
2006-12-19 00:17:47 +01:00
|
|
|
|
2007-03-11 00:09:22 +01:00
|
|
|
%changelog
|