[tex-live] Bug#530199: texlive-formats-extra: bashism in /bin/sh script

Frank Küster frank at debian.org
Sat May 23 19:30:06 CEST 2009


Dear TeX Live team,

Debian has the goal of being able to use smaller, but still
POSIX-compliant shells than bash as standard shell.  This is in
particular interesting for embedded systems, which might not be the main
target of TeXLive, but it turns out that it also speeds up many tasks a
lot, and is therefore useful for anyone.  Moreover and from an upstream
point of view, it (hopefully) increases portability to POSIX systems
where bash isn't installed by default.

Now, our checkbashisms script has identified a couple of uses of
bash-specific, non-POSIX syntax in #!/bin/sh-scripts in TeX Live. I
fear, however, that it may be hard to contact the maintainers.  

Would you be willing to help in that, or else to apply the patches to
the CTAN version in case there's no identifyable maintainer?

Here's one:

Raphael Geissert <atomo64 at gmail.com> wrote:

>> possible bashism in
>> ./usr/share/doc/texlive-formats-extra/eplain/util/trimsee line 28 
>> ('((' should be '$(('):
>>     if (( $1 < 2 )); then

There's no copyright information in the script, only the line

# (This file is public domain.)

(Raphael, is it acceptable for Debian to not have a copyright statement
for PD files? I guess so).

Unless someone from the people involved in eplain remember the author,
it seems someone else needs to take responsibility.

Here's one more:

> possible bashism in ./usr/share/texmf-texlive/tex/generic/hyphen/bahyph.sh
> line 155 (unsafe echo with backslash):
>	  echo "\catcode\`'=12 \lccode\`'=\`'"
> possible bashism in ./usr/share/texmf-texlive/tex/generic/hyphen/bahyph.sh
> line 159 (unsafe echo with backslash):
>	  echo "\catcode\`~=12 \lccode\`~=\`~"

Here we do have (old, very old) contact addresses, but there are some
additional concerns:

- Shouldn't this file be moved from TEXMFDIST/tex to doc? It can be used
  to recreate the basque hyphenation patterns.

- Is this file regarded as free by TeX Live? I fear Debian legal people
  will have concerns:

% You can use this software for any purpose. You cannot delete this
% copyright notice. If you change this software, you must include 
% comments explaining who, when and why. You are kindly requested to 
% send any changes to tex at gmv.es. If you change the generating 
% script, you must include code in it such that any output is clearly
% labeled as generated by a modified script.

The issues are:

a) it doesn't mention redistribution, so it's unclear whether anyone
   else but the original place (CTAN) is allowed to
   redistribute. However, the wording seems to implicitly assume
   redistribution - otherwise the requirement to identify changed
   versions doesn't make much sense

b) We don't like the requirement to reveal your identity if you make
   changes ("dissident test").

There are more scripts with bashisms, but I think those shouldn't be
installed by TeX Live and Debian at all, since they are only useful to
install a downloaded tarball in your local TEXMF tree:

/usr/share/doc/texlive-lang-french/latex/tabvar/install-tabvar.sh
/usr/share/doc/texlive-latex-extra-doc/latex/isodate/install.sh

Regards, Frank
-- 
Dr. Frank Küster
Debian Developer (TeXLive)
VCD Aschaffenburg-Miltenberg, ADFC Miltenberg
B90/Grüne KV Miltenberg


More information about the tex-live mailing list