[tex-live] Comment on Re: TeXLive-CD/DVD (Installation)
Nelson H. F. Beebe
beebe at math.utah.edu
Wed May 23 03:14:54 CEST 2007
List traffic today comments on the Unix shells, but there seems
to be confusion with comments like this;
>> shell commands are a bad way to go in my opinion, as they differ
>> between platfroms,
>> Isn't bash installed on most systems?
There are several widely-used shells on Unix systems in two major
families: C-shell and Bourne shell.
The C-shell is not universally available, and for many reasons, is
unsuitable for serious shell scripting (even though I have used it and
its descendant, tcsh, daily for 25+ years as my interactive shell).
Members of the Bourne shell family include the original /bin/sh, plus
bash, ksh (1988, 1993), pdksh, and zsh. On GNU/Linux systems, /bin/sh
IS bash, and that fact trips up many a shell programmer.
POSIX standardizes the original Bourne shell, with common extensions
such as shell functions. In our book, Classic Shell Scripting (ISBNs
0-596-00595-4 and 2-84177-375-2), we concentrate on **PORTABLE** shell
scripting based on the POSIX specification.
POSIX is not just for Unix: pretty much every shipping operating
system claims POSIX conformance, though sadly, Microsoft does this in
a way that makes POSIX a separate world that cannot easily communicate
with Windows, and also includes POSIX support only in add-on packages
that most systems have never had installed.
While we describe in our book some of the extensions present in ksh,
bash, and zsh, none of them can be used in portable shell scripting,
and the practice throughout the book is to use only what works
everywhere.
The GNU autoconf system is a triumph of portable shell scripting, and
demonstrates that complex shell scripts can be made to run correctly
on virtually every common Unix platform, and even lots of older
(e.g. BSD VAXes) or hosted ones (Cygwin on Microsoft Windows). In one
of my own packages, the generated configure script is over 71,000
lines long, and works for everything from VAXes to Don Knuth's MMIX
machine.
The proposals to write installers in other scripting languages, such
as lua, perl, python, ruby, ... have even more portability problems.
If you want portable installers that work on a wide variety of Unix
and POSIX systems, use carefully-written shell scripts.
If you do use other scripting languages, then your installer must
include WORKING binary distributions of those languages for every
platform, and that brings us back to the horrid mess of dependencies
of binary libraries on each other, and on O/S kernel versions.
If a simple, freely-distributable, standalone POSIX shell for Windows
(NT, ME, 2000, XP, VISTA, ...) could be found, along with the set of
several dozen command-line utilities required by POSIX, then an
installer written as a POSIX shell script could easily handle all
current platforms on which TeX Live is likely to be installed.
-------------------------------------------------------------------------------
- Nelson H. F. Beebe Tel: +1 801 581 5254 -
- University of Utah FAX: +1 801 581 4148 -
- Department of Mathematics, 110 LCB Internet e-mail: beebe at math.utah.edu -
- 155 S 1400 E RM 233 beebe at acm.org beebe at computer.org -
- Salt Lake City, UT 84112-0090, USA URL: http://www.math.utah.edu/~beebe/ -
-------------------------------------------------------------------------------
More information about the tex-live
mailing list