diff options
author | rillig <rillig@pkgsrc.org> | 2020-03-12 08:44:15 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2020-03-12 08:44:15 +0000 |
commit | 0ad39added933a32b48c95677cfbbe37c61de80e (patch) | |
tree | 441cdb9283e5472fea0b961640a60c5c6a64677c /mk/check | |
parent | 5531ecd5fba2bba6f4e3dcc5127cacec977307a6 (diff) | |
download | pkgsrc-0ad39added933a32b48c95677cfbbe37c61de80e.tar.gz |
mk/check/check-portability: check Makefile.am and Makefile.in as well
Up to now, these files had been skipped because they didn't start with a
#! line. Still, they contain shell programs, therefore it makes sense to
check them.
Diffstat (limited to 'mk/check')
-rw-r--r-- | mk/check/check-portability.sh | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/mk/check/check-portability.sh b/mk/check/check-portability.sh index 134def2b241..3ec709c7e9c 100644 --- a/mk/check/check-portability.sh +++ b/mk/check/check-portability.sh @@ -1,4 +1,4 @@ -# $NetBSD: check-portability.sh,v 1.13 2020/03/11 23:59:27 rillig Exp $ +# $NetBSD: check-portability.sh,v 1.14 2020/03/12 08:44:15 rillig Exp $ # # This program checks all files in the current directory and any # subdirectories for portability issues that are likely to result in @@ -43,12 +43,13 @@ find * -type f -print 2>/dev/null \ eval "case \"\$fname\" in $SKIP_FILTER *.orig) skip=yes;; esac" [ $skip = no ] || continue + skip_shebang_test=no ext="${fname##*.}" case "$ext" in # A few file extensions cannot be skipped since the Makefiles # will be generated from these, in the configure stage, which # is run later. - (am|in) ;; + (am|in) skip_shebang_test=yes;; # echo */*/PLIST | xargs cat | sed s,'.*\.',, | sort | uniq -c | sort -nr | sed 40q (png|html|svg|py|h|mo|php|js|xml|rb|go|txt|3|hpp) continue ;; (tfm|gif|dtd|properties|json|ogg|gz|test|result|xpm|po) continue ;; @@ -57,6 +58,11 @@ find * -type f -print 2>/dev/null \ (c|C|cc|cxx|f|go|pl|py|in|ac|m4) continue ;; esac + if [ $skip_shebang_test = yes ]; then + check_shell "$fname" + continue + fi + case "$opsys" in SunOS-5.9) # See also (if you can): |