commit:     4499057035307d4fc366c5cfeab7aaf57ad9dbc4
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Apr 10 07:00:58 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Apr 10 07:11:36 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=44990570

sys-apps/grep: add 3.10_p20230410 (unkeyworded)

Signed-off-by: Sam James <sam <AT> gentoo.org>

 sys-apps/grep/Manifest                   |   2 +
 sys-apps/grep/grep-3.10_p20230410.ebuild | 115 +++++++++++++++++++++++++++++++
 2 files changed, 117 insertions(+)

diff --git a/sys-apps/grep/Manifest b/sys-apps/grep/Manifest
index fe709b81efa0..74afa8e6a07a 100644
--- a/sys-apps/grep/Manifest
+++ b/sys-apps/grep/Manifest
@@ -1,3 +1,5 @@
+DIST grep-3.10.7-e498.tar.xz 1700076 BLAKE2B 
e50b2799ad43461441e82eb88e050e1aa1ac223e02b1c77f52657195ebbaf336795156cd26d4fb11734b1f3c6616ea60ac432f71faf263d32d3e9e196a9587b5
 SHA512 
671e06c3189cfa52614fddf42b85b907b0be5325e0ece418db39c3bfb5ae9998f171f225bb3fddc36f0669bcd32f0cffe6a7bca63920b400e7fcafefe72550de
+DIST grep-3.10.7-e498.tar.xz.sig 833 BLAKE2B 
82b914943cf6c79f343321adde11ad1c0751819aed61f713e12be4a300879aee8dc35da08c8bad2ca5b9bbf50d9f495ef44dd98677a47574dc71918733a3b23d
 SHA512 
5d11c04f42730852063211904cd95b83555f1b1aed985ce8ef0f17e0c4755d799cd60eb7986c002b54c56b1083538ae6b51c25ebd55db07273a6819b80512c6b
 DIST grep-3.10.tar.xz 1687464 BLAKE2B 
5ff169a4ed39e8af1e6729fd2e1bafd39036a4f56cf831f990d58bf9e76bc7d8b055254ae7f60509be4e8bf2f3737edb15431a8ecfc7fc058578d2abea3d73b9
 SHA512 
865e8f3fd7afc68f1a52f5e1e1ee05fb9c6d6182201efb0dbdf6075347b0b1d2bf0784537a8f8dd4fb050d523f7a1d2fb5b9c3e3245087d0e6cc12d6e9d3961b
 DIST grep-3.10.tar.xz.sig 833 BLAKE2B 
0b13c8c8955b4e38889cf79b426618e006b05bc3b224e0705b2cb592b1520a7fc751d5cc386371707a53c8b6888c4e1f9dd31c3ea2ef5cbf4c97ddef3ba7d037
 SHA512 
02224ff2d6b3a9a50d0e15f7a9b3c264aa717602d133ac32b36a7315bf29ec3b94ef7ec31ee979b199264d10003dc502e20f9bf932bb32b4abe4426ea564d4be
 DIST grep-3.7.tar.xz 1641196 BLAKE2B 
acf03b1fe8065dac48d686de070bab9ecddae65c97f3b0e2be484e8abdd06d1fbdbb396f3d73dadadf9618aad2f02cf6416094bad64d5f2f15eab6b6b3adfeda
 SHA512 
e9e45dcd40af8367f819f2b93c5e1b4e98a251a9aa251841fa67a875380fae52cfa27c68c6dbdd6a4dde1b1017ee0f6b9833ef6dd6e419d32d71b6df5e972b82

diff --git a/sys-apps/grep/grep-3.10_p20230410.ebuild 
b/sys-apps/grep/grep-3.10_p20230410.ebuild
new file mode 100644
index 000000000000..1dbbfb2df67f
--- /dev/null
+++ b/sys-apps/grep/grep-3.10_p20230410.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/grep.asc
+inherit flag-o-matic verify-sig
+
+DESCRIPTION="GNU regular expression matcher"
+HOMEPAGE="https://www.gnu.org/software/grep/";
+
+if [[ ${PV} == *_p* ]] ; then
+       # Subscribe to the 'platform-testers' ML to find these.
+       # Useful to test on our especially more niche arches and report issues 
upstream.
+       MY_COMMIT="7-e498"
+       MY_P=${PN}-$(ver_cut 1-2).${MY_COMMIT}
+       SRC_URI="https://meyering.net/${PN}/${MY_P}.tar.xz";
+       SRC_URI+=" verify-sig? ( https://meyering.net/${PN}/${MY_P}.tar.xz.sig 
)"
+       S="${WORKDIR}"/${MY_P}
+else
+       SRC_URI="mirror://gnu/${PN}/${P}.tar.xz"
+       SRC_URI+=" verify-sig? ( mirror://gnu/${PN}/${P}.tar.xz.sig )"
+       KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc 
~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux 
~arm64-macos ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris 
~x86-solaris"
+fi
+
+LICENSE="GPL-3+"
+SLOT="0"
+IUSE="+egrep-fgrep nls pcre static"
+
+# We lack dev-libs/libsigsegv[static-libs] for now
+REQUIRED_USE="static? ( !sparc )"
+
+LIB_DEPEND="
+       pcre? ( >=dev-libs/libpcre2-7.8-r1[static-libs(+)] )
+       sparc? ( dev-libs/libsigsegv )
+"
+RDEPEND="
+       !static? ( ${LIB_DEPEND//\[static-libs(+)]} )
+       nls? ( virtual/libintl )
+       virtual/libiconv
+"
+DEPEND="
+       ${RDEPEND}
+       static? ( ${LIB_DEPEND} )
+"
+BDEPEND="
+       virtual/pkgconfig
+       nls? ( sys-devel/gettext )
+       verify-sig? ( sec-keys/openpgp-keys-grep )
+"
+
+DOCS=( AUTHORS ChangeLog NEWS README THANKS TODO )
+
+QA_CONFIG_IMPL_DECL_SKIP=(
+       # Either gnulib FPs or fixed in newer autoconf, not worth autoreconf 
here for now?
+       MIN
+       alignof
+       static_assert
+)
+
+src_prepare() {
+       default
+
+       # bug #523898
+       sed -i \
+               -e "s:@SHELL@:${EPREFIX}/bin/sh:g" \
+               -e "s:@grep@:${EPREFIX}/bin/grep:" \
+               src/egrep.sh || die
+}
+
+src_configure() {
+       use static && append-ldflags -static
+
+       # We used to turn this off unconditionally (bug #673524) but we now
+       # allow it for cases where libsigsegv is better for userspace handling
+       # of stack overflows.
+       # In particular, it's necessary for sparc: bug #768135
+       export ac_cv_libsigsegv=$(usex sparc)
+
+       local myeconfargs=(
+               --bindir="${EPREFIX}"/bin
+               $(use_enable nls)
+               $(use_enable pcre perl-regexp)
+       )
+
+       econf "${myeconfargs[@]}"
+}
+
+src_install() {
+       default
+
+       if use egrep-fgrep ; then
+               # Delete the upstream wrapper variants which warn on 
egrep+fgrep use
+               rm "${ED}"/bin/{egrep,fgrep} || die
+
+               into /
+               # Install egrep, fgrep which don't warn.
+               #
+               # We do this by default to avoid breakage in old scripts
+               # and such which don't expect unexpected output on stderr,
+               # we've had examples of builds failing because foo-config
+               # starts returning a warning.
+               #
+               # 
https://lists.gnu.org/archive/html/bug-grep/2022-10/msg00000.html
+               newbin - egrep <<-EOF
+               #!/usr/bin/env sh
+               exec "${EPREFIX}/bin/grep" -E "\$@"
+               EOF
+
+               newbin - fgrep <<-EOF
+               #!/usr/bin/env sh
+               exec "${EPREFIX}/bin/grep" -F "\$@"
+               EOF
+       fi
+}

Reply via email to