git: ea62bacb8ac8 - main - sysutils/debootstrap: use gnugrep

Edward Tomasz Napierala trasz at FreeBSD.org
Tue May 4 12:48:10 UTC 2021


The branch main has been updated by trasz:

URL: https://cgit.FreeBSD.org/ports/commit/?id=ea62bacb8ac8978cd8f265cc385fd55cec051d1a

commit ea62bacb8ac8978cd8f265cc385fd55cec051d1a
Author:     Edward Tomasz Napierala <trasz at FreeBSD.org>
AuthorDate: 2021-05-04 12:42:35 +0000
Commit:     Edward Tomasz Napierala <trasz at FreeBSD.org>
CommitDate: 2021-05-04 12:47:58 +0000

    sysutils/debootstrap: use gnugrep
    
    Debootstrap triggers some weird corner case in our base grep(1),
    where it's two orders of magnitude slower than it should be.
    Fix it by providing it with GNU grep.  This reduces the time
    to complete 'debootstrap bionic' from ~4m30s to ~1m30s.
    
    Reviewed By:    emaste (earlier version)
    Sponsored By:   EPSRC
    Differential Revision:  https://reviews.freebsd.org/D30023
---
 sysutils/debootstrap/Makefile | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/sysutils/debootstrap/Makefile b/sysutils/debootstrap/Makefile
index 09cfc7e65b1c..d8934457e10e 100644
--- a/sysutils/debootstrap/Makefile
+++ b/sysutils/debootstrap/Makefile
@@ -2,7 +2,7 @@
 
 PORTNAME=	debootstrap
 PORTVERSION=	1.0.123
-PORTREVISION=	4
+PORTREVISION=	5
 CATEGORIES=	sysutils
 MASTER_SITES=	DEBIAN
 DISTNAME=	${PORTNAME}_${PORTVERSION}
@@ -15,6 +15,7 @@ LICENSE_FILE=	${WRKSRC}/debian/copyright
 
 RUN_DEPENDS=	wget:ftp/wget \
 		bash:shells/bash \
+		${LOCALBASE}/bin/grep:textproc/gnugrep \
 		gpgv2:security/gnupg \
 		${LOCALBASE}/share/keyrings/ubuntu-archive-keyring.gpg:security/ubuntu-keyring
 
@@ -41,6 +42,10 @@ post-patch:
 	@${FIND} ${WRKSRC}/scripts -type f | \
 		${XARGS} ${REINPLACE_CMD} -e 's,/usr/share/keyrings,${LOCALBASE}/share/keyrings,g'
 
+	# Workaround for bin/255525
+	@${REINPLACE_CMD} -e 's,grep,${LOCALBASE}/bin/grep,g' \
+		${WRKSRC}/functions
+
 post-install:
 	${INSTALL_MAN} ${WRKSRC}/debootstrap.8 \
 		${STAGEDIR}${MAN8PREFIX}/man/man8/debootstrap.8


More information about the dev-commits-ports-all mailing list