From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 7856) id CADE9383DBB7; Sat, 25 Jun 2022 04:48:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CADE9383DBB7 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Xi Ruoyao To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/xry111/heads/no-egrep-v2)] fortran: use grep instead of fgrep X-Act-Checkin: gcc X-Git-Author: Xi Ruoyao X-Git-Refname: refs/users/xry111/heads/no-egrep-v2 X-Git-Oldrev: 180f9add1ce36cbe9a47cf94e0f8c1936d60b903 X-Git-Newrev: a212eb6be3ef46fc591967f0d1bf2af73f349ebe Message-Id: <20220625044821.CADE9383DBB7@sourceware.org> Date: Sat, 25 Jun 2022 04:48:21 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Jun 2022 04:48:21 -0000 https://gcc.gnu.org/g:a212eb6be3ef46fc591967f0d1bf2af73f349ebe commit a212eb6be3ef46fc591967f0d1bf2af73f349ebe Author: Xi Ruoyao Date: Fri Jun 24 20:23:13 2022 +0800 fortran: use grep instead of fgrep fgrep has been deprecated in favor of grep -F for a long time, and the next grep release (3.8 or 4.0) will print a warning of fgrep is used. Stop using fgrep so we won't see the warning. We can't hard code grep -F here or it may break build on hosts w/o GNU grep. autoconf documentation contains a warning about this issue and suggest to use AC_PROG_FGREP and $FGREP, but these are too overkill in the specific case: there is no way "debian" could be interpreted as an non-trivial regex, so we can use a plain grep here. gcc/fortran/ChangeLog: * Make-lang.in: Use grep instead of fgrep. Diff: --- gcc/fortran/Make-lang.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/fortran/Make-lang.in b/gcc/fortran/Make-lang.in index 1cb47cb1a52..6eb597d0ca0 100644 --- a/gcc/fortran/Make-lang.in +++ b/gcc/fortran/Make-lang.in @@ -278,7 +278,7 @@ $(DESTDIR)$(man1dir)/$(GFORTRAN_INSTALL_NAME)$(man1ext): doc/gfortran.1 \ -chmod a-x $@ fortran.uninstall: - if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \ + if $(SHELL) -c 'install-info --version | sed 1q | grep -s -v -i debian' >/dev/null 2>&1; then \ echo " install-info --delete --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/gfortran.info"; \ install-info --delete --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/gfortran.info || : ; \ else : ; fi; \