[tlbuild] Broken shebangs in TeX Live scripts

Ken Moffat zarniwhoop at ntlworld.com
Sat Apr 9 17:50:58 CEST 2022


On Sat, Apr 09, 2022 at 03:56:16PM +0200, Henri Menke wrote:
> Dear builders,
> 
> I've checked the shebangs in the scripts shipped with TeX Live for
> x86_64-linux and discovered some problems. There are some shebangs that
> are outright broken like "#!perl -w" and others that hardcode the path
> to the executable like /bin/bash or /usr/bin/python. This won't work on
> systems which have /bin merged into /usr/bin where no /bin/bash exists
> or for people who use Python or Perl installations in non-standard
> paths, e.g. /usr/local/bin.
> 

For /bin/bash : any sane merged-usr system symlinks /usr/bin to
/bin. I have read of an alternative where everything in /bin is a
symlink, e.g. /bin/bash -> /usr/bin/bash, but I cannot conceive of a
linux system where some form of /bin/bash does not exist.

ĸen
> 
> Below you can find a probably non-exhaustive list of problematic
> scripts in TeX Live 2022.
> 
> Kind regards,
> Henri
> 
> 
> 
> $ 2>/dev/null grep '^#!' /opt/texlive/2022/bin/x86_64-linux/* | grep -v -e '/usr/bin/env' -e '/bin/sh'
> /opt/texlive/2022/bin/x86_64-linux/a2ping:#!perl -w
> /opt/texlive/2022/bin/x86_64-linux/bibexport:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/ctan-o-mat:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/ctanupload:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/de-macro:#!/usr/bin/python -O
> /opt/texlive/2022/bin/x86_64-linux/dtxgen:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/exceltex:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/findhyph:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/fragmaster:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/git-latexdiff:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/installfont-tl:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/latex2man:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/latexpand:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/listbib:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/ltxfileinfo:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/makedtx:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/mathspic:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/mkt1font:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/multibibliography:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/pamphletangler:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/pdflatexpicscale:#!/usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/pdftex-quiet:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/pdfxup:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/pn2pdf:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/splitindex:#! /usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/svn-multi:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/tlcockpit:#!/bin/bash
> /opt/texlive/2022/bin/x86_64-linux/ulqda:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/urlbst:#! /usr/bin/perl -w
> /opt/texlive/2022/bin/x86_64-linux/vpl2ovp:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/vpl2vpl:#!/usr/bin/perl
> /opt/texlive/2022/bin/x86_64-linux/yplan:#!/usr/bin/perl

-- 
    "Well, when Nobby asked him if he wanted his figgin toasted,
     he just give a scream and ran off."
                                     -- (Guards! Guards!)


More information about the tlbuild mailing list.