Bug#292973: postinst and prerm are #!/bin/sh scripts but use command -v
Package: dpkg-doc
Version: 1.10.26
Severity: minor
"command -v" is not POSIX. However, the postinst and prerm scripts use
it and have #!/bin/sh at the top, so they violate policy 10.4.
Possible solutions:
* Using #!/bin/bash eliminates the 10.4 violation. However, there
remains the additional problem that "command -v" doesn't really work
as a check whether or not a command is runnable. The string that it
outputs is not necessarily the pathname of an executable file.
(See #291197.)
* Use the which program from debianutils.
* Use the trydo() function I posted to #291026.
* Use the findcommand() function posted by Tollef Fog Heen in #218530.
* Assume that install-docs is at /usr/sbin/install-docs and just use
test -x /usr/sbin/install-docs
-- System Information:
Debian Release: 3.1
APT prefers testing
APT policy: (500, 'testing'), (50, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.6.9
Locale: LANG=en_IE@euro, LC_CTYPE=en_IE@euro (charmap=ISO-8859-15)
-- no debconf information
Reply to: