]> Savannah Git Hosting - gnulib.git/commitdiff
maintainer-makefile: Add syntax-check rule for unportable 'grep -q'.
authorSimon Josefsson <simon@josefsson.org>
Tue, 1 Nov 2022 08:06:56 +0000 (09:06 +0100)
committerSimon Josefsson <simon@josefsson.org>
Tue, 1 Nov 2022 08:06:56 +0000 (09:06 +0100)
* top/maint.mk (sc_unportable_grep_q): Add.

top/maint.mk

index 045609c285d0f9077fae2185bc7da46a1b4cb812..85b15fb2d2b4d5845b7b8200fa29f7990ecd5140 100644 (file)
@@ -1373,6 +1373,10 @@ sc_vulnerable_makefile_CVE-2012-3386:
          '  see https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2012-3386 for details') \
          $(_sc_search_regexp)
 
+sc_unportable_grep_q:
+       @prohibit='grep -q' halt="unportable 'grep -q', use >/dev/null instead" \
+         $(_sc_search_regexp)
+
 vc-diff-check:
        $(AM_V_GEN)(unset CDPATH; cd $(srcdir) && $(VC) diff) > vc-diffs || :
        $(AM_V_at)if test -s vc-diffs; then                     \