textproc/gnugrep (dependencies): do not rely on compatibility symlink

Historically we had built and installed GNU grep programs as `grep' +
[ef]grep, but started to configure the port with `--program-prefix=g'
in 2022, as we and several other non-GNU/Linux systems, e.g. NetBSD,
OpenBSD, Solaris, macOS do for miscellaneous GNU utilities.  To avoid
breaking POLA, g-prefixless compatibility symlinks were being created,
subject to the COMPAT option (on by default).

Recently GNU grep developers decided to deprecate {e,f}grep variants,
with the clear intention to consolidate all three greps into a single
command.  This had significantly annoyed users who could not update
their scripts to `grep -[EF]', usually for portability reasons, e.g.
SunOS 4.11 grep which does not support those switches, but does have
egrep and fgrep, or when scripts are written by others and they don't
have permissions to modify them, etc.  Perhaps it is time to turn the
COMPAT option off by default, this commit concludes the preparation.

PR:		277784
Requested by:	fuz, obrien
This commit is contained in:
Alexey Dokuchaev
2025-05-11 06:58:54 +00:00
parent 0705239f6a
commit 18bf1a7d6b
3 changed files with 7 additions and 7 deletions
+2 -2
View File
@@ -15,7 +15,7 @@ BUILD_DEPENDS= aclocal:devel/automake \
autoreconf:devel/autoconf \
bash:shells/bash \
cmake:devel/cmake-core \
${LOCALBASE}/bin/grep:textproc/gnugrep \
ggrep:textproc/gnugrep \
libgcrypt>0:security/libgcrypt \
libtoolize:devel/libtool \
e2fsprogs-libuuid>0:misc/e2fsprogs-libuuid \
@@ -48,7 +48,7 @@ post-patch:
-e '7s/^/pidfile="\/var\/run\/${PORTNAME}\/${PORTNAME}.pid"\n/g' \
${WRKSRC}/src/proxysql.cfg
@${REINPLACE_CMD} \
-e 's,grep -P,${LOCALBASE}/bin/grep -P,g' \
-e 's,grep -P,g&,' \
-e '/ export C/d' \
-e 's,PROXYSQLCLICKHOUSE=1 ,,g' \
-e 's,--enable-fastopen=false ,--enable-fastopen=false --enable-shared=no ,g' \
+2 -2
View File
@@ -10,7 +10,7 @@ WWW= https://www.argobots.org/
LICENSE= BSD4CLAUSE
LICENSE_FILE= ${WRKSRC}/COPYRIGHT
BUILD_DEPENDS= ${LOCALBASE}/bin/grep:textproc/gnugrep # workaround for https://github.com/pmodels/argobots/issues/375
BUILD_DEPENDS= ggrep:textproc/gnugrep # workaround for https://github.com/pmodels/argobots/issues/375
USES= autoreconf gmake libtool
USE_LDCONFIG= yes
@@ -22,7 +22,7 @@ GH_ACCOUNT= pmodels
INSTALL_TARGET= install-strip
BINARY_ALIAS= grep=${LOCALBASE}/bin/grep # for https://github.com/pmodels/argobots/issues/375
BINARY_ALIAS= grep=ggrep # for https://github.com/pmodels/argobots/issues/375
PLIST_FILES= include/abt.h \
lib/libabt.a \
+3 -3
View File
@@ -30,10 +30,10 @@ WWW= https://docs.espressif.com/projects/esp-idf/en/v5.3.1/esp32/get-started/
LICENSE= GPLv2 LGPL21
LICENSE_COMB= multi
BUILD_DEPENDS= ${LOCALBASE}/bin/grep:textproc/gnugrep \
${LOCALBASE}/include/libintl.h:devel/gettext-runtime \
BUILD_DEPENDS= ${LOCALBASE}/include/libintl.h:devel/gettext-runtime \
bash:shells/bash \
gawk:lang/gawk \
ggrep:textproc/gnugrep \
gpatch:devel/patch \
gsed:textproc/gsed \
help2man:misc/help2man \
@@ -58,7 +58,7 @@ BINARY_ALIAS= g++=${CXX} gcc=${CC} python=${PYTHON_VERSION}
BUILD_ENV= ${WRK_ENV} \
CT_ALLOW_BUILD_AS_ROOT_SURE=1 \
CT_FORBID_DOWNLOAD=y \
GREP=${LOCALBASE}/bin/grep \
GREP=ggrep \
LD_RUN_PATH=${PREFIX}/lib/${CC} \
LDFLAGS=-I${PREFIX}/lib \
${MAKE_ENV:MPATH=*}