Skip to content

checkbashisms.pl in make check + fixed docs

Petr Vorel ltp 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4doc: Mention make checkdoc/c-test-tutorial-simple.txt doc/test-writing-guidelines.txt+15 -161 reply
1/4doc: Mention make check+0 -00 replies
2/4Vendor checkbashisms.pl version 2.20.5scripts/checkbashisms.pl+816 -01 reply
3/4rules.mk: Add checkbashisms to 'make check' for *.shinclude/mk/env_post.mk include/mk/generic_leaf_target.inc include/mk/generic_trunk_target.inc +1 more+13 -21 reply
3/4rules.mk: Add checkbashisms to 'make check' for *.sh+0 -00 replies
4/4doc: Update for vendored checkbashisms.pldoc/maintainer-patch-review-checklist.txt doc/test-writing-guidelines.txt+7 -41 reply
4/4doc: Update for vendored checkbashisms.pl+0 -00 replies

Reviews trailers per patch

All 7 patches have a Reviewed-by or Acked-by.

PatchCyril Hrubis
1/4R-b
1/4R-b
2/4R-b
3/4R-b
3/4R-b
4/4R-b
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [LTP] [PATCH 0/4] checkbashisms.pl in make check + fixed docs

Hi,

checkbashisms.pl has problem with type. Although it's in POSIX [1] even in old one from 2004 [2] and it's supported by all common shells (i.e. bash, zsh, dash, busybox sh, mksh; even in ksh; maybe just csh does not support it) checkbashisms.pl complains about it:

$ make check-tst_test.sh
CHECK testcases/lib/tst_test.sh
possible bashism in tst_test.sh line 33 (type):
		if type $TST_CLEANUP >/dev/null 2>/dev/null; then
possible bashism in tst_test.sh line 694 (type):
		if type $TST_SETUP >/dev/null 2>/dev/null; then
possible bashism in tst_test.sh line 726 (type):
		if type ${TST_TESTFUNC}1 > /dev/null 2>&1; then
make: [../../include/mk/rules.mk:58: check-tst_test.sh] Error 1 (ignored)

Should I report it to Debian (the upstream)? Or at least ask for way to suppress the warning?

Kind regards,
Petr

[1] https://pubs.opengroup.org/onlinepubs/9699919799/utilities/type.html#tag_20_136
[2] https://pubs.opengroup.org/onlinepubs/000095399/utilities/type.html

Petr Vorel (4):
doc: Mention make check
Vendor checkbashisms.pl version 2.20.5 rules.mk: Add checkbashisms to 'make check' for *.sh
doc: Update for vendored checkbashisms.pl

 doc/c-test-tutorial-simple.txt            |  21 +-
 doc/maintainer-patch-review-checklist.txt |   3 +-
 doc/test-writing-guidelines.txt           |  18 +-
 include/mk/env_post.mk                    |   2 +
 include/mk/generic_leaf_target.inc        |   2 +-
 include/mk/generic_trunk_target.inc       |   2 +-
 include/mk/rules.mk                       |   9 +
 scripts/checkbashisms.pl                  | 816 ++++++++++++++++++++++
 8 files changed, 851 insertions(+), 22 deletions(-)
 create mode 100755 scripts/checkbashisms.pl
Signature · 1 line
2.33.0