Compare commits

..

No commits in common. "rawhide" and "f38" have entirely different histories.

8 changed files with 70 additions and 3754 deletions

1
.gitignore vendored
View file

@ -1,2 +1 @@
/grep-*.tar.xz
/grep-*.tar.xz.sig

View file

@ -7,5 +7,5 @@ if ( $status == 1 ) then
endif
alias grep 'grep --color=auto'
alias egrep 'grep -E --color=auto'
alias fgrep 'grep -F --color=auto'
alias egrep 'egrep --color=auto'
alias fgrep 'fgrep --color=auto'

View file

@ -3,5 +3,5 @@
/usr/libexec/grepconf.sh -c || return
alias grep='grep --color=auto' 2>/dev/null
alias egrep='grep -E --color=auto' 2>/dev/null
alias fgrep='grep -F --color=auto' 2>/dev/null
alias egrep='egrep --color=auto' 2>/dev/null
alias fgrep='fgrep --color=auto' 2>/dev/null

View file

@ -1,38 +0,0 @@
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 223088f..315ced7 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -195,7 +195,6 @@ TESTS = \
word-delim-multibyte \
word-multi-file \
word-multibyte \
- write-error-msg \
y2038-vs-32-bit \
yesno \
z-anchor-newline
diff --git a/tests/Makefile.in b/tests/Makefile.in
index 3270d30..33dcd8a 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -2729,7 +2729,6 @@ TESTS = \
word-delim-multibyte \
word-multi-file \
word-multibyte \
- write-error-msg \
y2038-vs-32-bit \
yesno \
z-anchor-newline
@@ -3970,13 +3969,6 @@ word-multibyte.log: word-multibyte
--log-file $$b.log --trs-file $$b.trs \
$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
"$$tst" $(AM_TESTS_FD_REDIRECT)
-write-error-msg.log: write-error-msg
- @p='write-error-msg'; \
- b='write-error-msg'; \
- $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
- --log-file $$b.log --trs-file $$b.trs \
- $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
- "$$tst" $(AM_TESTS_FD_REDIRECT)
y2038-vs-32-bit.log: y2038-vs-32-bit
@p='y2038-vs-32-bit'; \
b='y2038-vs-32-bit'; \

46
grep-configure-c99.patch Normal file
View file

@ -0,0 +1,46 @@
Work around a recent regression in C99 compatibility in autoconf.
The configure script was generated with an autoconf prerelease,
and the issue has been fixed upstream with this commit:
commit bf5a75953b6d504f0405b1ca33b039b8dd39eef4
Author: Zack Weinberg <zackw@panix.com>
Date: Thu Nov 10 12:05:30 2022 -0500
More fixes for compilers that reject K&R function definitions.
This fixes all of the remaining failures exposed by running the
testsuite with GCC 12 and
CC='cc -Wimplicit-function-declaration -Wold-style-definition
-Wimplicit-int -Werror'
.
* lib/autoconf/c.m4 (_AC_C_C89_TEST_GLOBALS): Dont use K&R function
definitions.
* lib/autoconf/specific.m4 (AC_SYS_RESTARTABLE_SYSCALLS): Likewise.
(AC_FUNC_MKTIME): Declare functions taking no arguments as fn (void)
not fn ().
* lib/autoconf/c.m4 (_AC_C_C99_TEST_GLOBALS): Declare free().
diff --git a/configure b/configure
index 51bd10995a6f57e8..4bdd3ecca7d2c793 100755
--- a/configure
+++ b/configure
@@ -3954,9 +3954,7 @@ struct stat;
/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
struct buf { int x; };
struct buf * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
+static char *e (char **p, int i)
{
return p[i];
}
@@ -4007,6 +4005,7 @@ extern int puts (const char *);
extern int printf (const char *, ...);
extern int dprintf (int, const char *, ...);
extern void *malloc (size_t);
+extern void free (void *);
// Check varargs macros. These examples are taken from C99 6.10.3.5.
// dprintf is used instead of fprintf to avoid needing to declare

File diff suppressed because it is too large Load diff

View file

@ -1,22 +1,18 @@
Summary: Pattern matching utilities
Name: grep
Version: 3.12
Release: 2%{?dist}
License: GPL-3.0-or-later AND LGPL-3.0-or-later AND LGPL-2.1-or-later AND GPL-2.0-or-later AND LGPL-2.0-or-later AND GFDL-1.3-no-invariants-or-later
Version: 3.8
Release: 3%{?dist}
License: GPLv3+
URL: https://www.gnu.org/software/grep/
Source0: https://ftp.gnu.org/pub/gnu/%{name}/%{name}-%{version}.tar.xz
Source1: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig
Source2: https://savannah.gnu.org/project/release-gpgkeys.php?group=grep&download=1'#/grep-keyring.gpg
Source3: colorgrep.sh
Source4: colorgrep.csh
Source5: GREP_COLORS
Source6: grepconf.sh
Source: https://ftp.gnu.org/pub/gnu/grep/grep-%{version}.tar.xz
Source1: colorgrep.sh
Source2: colorgrep.csh
Source3: GREP_COLORS
Source4: grepconf.sh
# upstream ticket 39445
Patch: grep-3.5-help-align.patch
# upstream ticket 77800
Patch: grep-3.12-test-write-error-msg-drop.patch
Patch0: grep-3.5-help-align.patch
Patch1: grep-configure-c99.patch
BuildRequires: gcc
BuildRequires: pcre2-devel
@ -24,14 +20,10 @@ BuildRequires: texinfo
BuildRequires: gettext
BuildRequires: autoconf
BuildRequires: automake
# temporal for the gnulib patch
BuildRequires: gettext-devel
Buildrequires: glibc-all-langpacks
BuildRequires: perl(FileHandle)
BuildRequires: make
BuildRequires: gnupg2
BuildRequires: libsigsegv-devel
# https://fedorahosted.org/fpc/ticket/174
Provides: bundled(gnulib)
# for backward compatibility (rhbz#1540485)
@ -47,7 +39,6 @@ prints the matching lines. GNU's grep utilities include grep, egrep and fgrep.
GNU grep is needed by many scripts, so it shall be installed on every system.
%prep
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
%autosetup -p1
%build
@ -60,7 +51,11 @@ GNU grep is needed by many scripts, so it shall be installed on every system.
%global BUILD_FLAGS %{BUILD_FLAGS} -mlong-double-64
%endif
%configure --without-included-regex --disable-silent-rules CFLAGS="%{BUILD_FLAGS}"
# Temporarily switch to the included regex until glibc bug is fixed:
# https://sourceware.org/bugzilla/show_bug.cgi?id=11053
#%%configure --without-included-regex --disable-silent-rules \
%configure --disable-silent-rules \
CPPFLAGS="-I%{_includedir}/pcre" CFLAGS="%{BUILD_FLAGS}"
%make_build
%install
@ -68,9 +63,9 @@ GNU grep is needed by many scripts, so it shall be installed on every system.
gzip $RPM_BUILD_ROOT%{_infodir}/grep*
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
install -pm 644 %{SOURCE3} %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
install -pm 644 %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}
install -Dpm 755 %{SOURCE6} $RPM_BUILD_ROOT%{_libexecdir}/grepconf.sh
install -pm 644 %{SOURCE1} %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
install -pm 644 %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}
install -Dpm 755 %{SOURCE4} $RPM_BUILD_ROOT%{_libexecdir}/grepconf.sh
%find_lang %name
@ -89,54 +84,6 @@ make check
%{_libexecdir}/grepconf.sh
%changelog
* Thu Jul 24 2025 Fedora Release Engineering <releng@fedoraproject.org> - 3.12-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
* Mon Apr 14 2025 Jaroslav Škarvada <jskarvad@redhat.com> - 3.12-1
- New version
Resolves: rhbz#2358901
* Fri Jan 17 2025 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
* Thu Jul 18 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Mon Apr 29 2024 Lukáš Zaoral <lzaoral@redhat.com> - 3.11-8
- remove redundant dependency on libsigsegv (RHEL-34664)
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sat Jan 20 2024 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Thu Aug 10 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.11-5
- Updated SPDX license expression
* Wed Aug 9 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.11-4
- Converted license to SPDX
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.11-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu Jul 13 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.11-2
- Fixed egrep/fgrep aliases
Resolves: rhbz#2215713
* Tue Jun 6 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.11-1
- New version
Resolves: rhbz#2181063
* Thu Mar 23 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.10-1
- New version
Resolves: rhbz#2181063
* Tue Mar 7 2023 Jaroslav Škarvada <jskarvad@redhat.com> - 3.9-1
- New version
Resolves: rhbz#2175526
- Added sources verification
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.8-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild

View file

@ -1,2 +1 @@
SHA512 (grep-3.12.tar.xz) = c54b4db5a8b9afe098c088decd94977746305284d716666a60bac82b4edc0fae4acf828970b5b6fc7d58ecd549f638e17e6958f33a71fedcc7d7415b9228b161
SHA512 (grep-3.12.tar.xz.sig) = 333755fd9e5879436789a19e9593667d6fb96c2d1b876a1c391eb9cd75d10bb7fbc10215db9838280e6006790c818ef4583b1ae22318a833a5b69264ca15dbf1
SHA512 (grep-3.8.tar.xz) = 2014519a80c6dcd799837e1bd7d9d5ebe8729ec54b0dc76981dac4755a9a8a9f200470cdcc911e2825bed8162e61da39e3dd60289f7393b48bf67314077d0c79