clone 373242 -1 Retitle -1 dash: Breaks documented "test" functionality Severity -1 important reassign -1 dash Retitle 373242 nslint: FTBFS when dash is used as /bin/sh because dash "test" builtin doesn't support documented syntax Thanks
Gerrit: Please see below for a summary of why I think this is a "dash" bug. I clone the bug instead of just reassigning it because I will implement a workaround in my package and will close the bug in the changelog accordingly. I'm sorry, but the test syntax is absolutely OK for a Debian system (see "man test") and it certainly is no "bashism". The problem is that dash wants to override the normal "test" binary but doesn't allow it's full syntax. Dash is the only shell I know of that doesn't allow use of the "-nt" (newer than) test. In other words: I believe that this needs to be fixed in dash, not in my build script. I use documented syntax of the "test" binary. If dash insists on overriding that binary with its own builtin implementation, it should provide the full functionality of the test binary shipped with Debian. This has been discussed before IIRC, but I can't find the discussion anymore.... However, I will (for now) call /usr/bin/test explicitly, which _should_ avoid the test builtin, but this is a stupid workaround to a (IMHO) stupid behaviour of a so-called standard-adherent shell. To summarize: Debian includes a "test" binary which documents support of the "-nt" comparator (see "man dash",[1]). "dash" overrides that with a builtin which doesn't support "-nt". Posix doesn't mandate a "test" built-in (see [2] and [3]), so the implementation of such a built-in is in excession of POSIX requirements. dash implements a posix-minimal version of "test", which is less than one can rightfully expect from a Debian system (-nt is documented in the manpage of "test). Regards, Sven [1]http://www.debian.org/doc/manuals/reference/ch-program.en.html#s-shell-cond [2]http://www.opengroup.org/onlinepubs/009695399/idx/sbi.html [3]http://www.opengroup.org/onlinepubs/009695399/utilities/sh.html Julien Danjou wrote on 13/06/2006 22:46: > Package: nslint > Version: 2.1a6-1 > Severity: important > > Hello, > > There was a problem while autobuilding your package: > > >>Automatic build of nslint_2.1a6-1 on avidan by sbuild/i386 0.46 >>Build started at 20060613-1529 >>****************************************************************************** >>Checking available source versions... >>Fetching source files... >>Reading package lists... >>Building dependency tree... >>Need to get 98.2kB of source archives. >>Get:1 http://ftp.fr.debian.org sid/main nslint 2.1a6-1 (dsc) [544B] >>Get:2 http://ftp.fr.debian.org sid/main nslint 2.1a6-1 (tar) [87.9kB] >>Get:3 http://ftp.fr.debian.org sid/main nslint 2.1a6-1 (diff) [9727B] >>Fetched 98.2kB in 0s (163kB/s) >>Download complete and in download only mode >>** Using build dependencies supplied by package: >>Build-Depends: dpatch >>Checking for already installed source dependencies... >>dpatch: missing >>Checking for source dependency conflicts... >>Reading package lists... >>Building dependency tree... >>Suggested packages: >> curl >>Recommended packages: >> patchutils >>The following NEW packages will be installed: >> dpatch >>0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. >>Need to get 0B/84.1kB of archives. >>After unpacking 319kB of additional disk space will be used. >>Selecting previously deselected package dpatch. >>(Reading database ... 10593 files and directories currently installed.) >>Unpacking dpatch (from .../archives/dpatch_2.0.20_all.deb) ... >>Setting up dpatch (2.0.20) ... >>Checking correctness of source dependencies... >>Kernel: Linux 2.6.16-xen i386 (i686) >>Toolchain package versions: libc6-dev_2.3.6-15 >>linux-kernel-headers_2.6.16.20-5 gcc-4.1_4.1.1-3 g++-4.1_4.1.1-3 >>binutils_2.16.1cvs20060413-1 libstdc++6-4.1-dev_4.1.1-3 libstdc++6_4.1.1-3 >>------------------------------------------------------------------------------ >>gpg: Signature made Tue Apr 25 16:01:23 2006 CEST using DSA key ID 14D4060B >>gpg: Can't check signature: public key not found >>dpkg-source: extracting nslint in nslint-2.1a6 >>dpkg-source: unpacking nslint_2.1a6.orig.tar.gz >>dpkg-source: applying /home/buildd/build/nslint_2.1a6-1.diff.gz >>dpkg-buildpackage: source package is nslint >>dpkg-buildpackage: source version is 2.1a6-1 >>dpkg-buildpackage: host architecture i386 >>dpkg-buildpackage: source version without epoch 2.1a6-1 >> /usr/bin/fakeroot debian/rules clean >>test -e debian/control >>test root = "`whoami`" >>rm -f configure-stamp build-stamp >>make distclean >>make[1]: Entering directory `/build/buildd/nslint-2.1a6' >>make[1]: *** No rule to make target `distclean'. Stop. >>make[1]: Leaving directory `/build/buildd/nslint-2.1a6' >>make: [clean] Error 2 (ignored) >>rm -rf debian/files debian/substvars "debian/tmp.nslint" >>rm -f config.cache gnuc.h >> debian/rules build >>test -e debian/control >>test config.guess -nt /usr/share/misc/config.guess || cp >>/usr/share/misc/config.guess . >>cp: cannot stat `/usr/share/misc/config.guess': No such file or directory >>make: *** [configure-stamp] Error 1 >>****************************************************************************** >>Build finished at 20060613-1530 >>FAILED [dpkg-buildpackage died] >>------------------------------------------------------------------------------ >>(Reading database ... 10637 files and directories currently installed.) >>Removing dpatch ... >>Purging configuration files for dpatch ... >>****************************************************************************** >>Finished at 20060613-1530 >>Build needed 00:00:03, 476k disk space > > > I guess the test syntax you use is not POSIX compliant and fails with a > posix compliant shell like dash. >
signature.asc
Description: OpenPGP digital signature

