summaryrefslogtreecommitdiff
path: root/Master/tlpkg/doc
diff options
context:
space:
mode:
authorSiep Kroonenberg <siepo@cybercomm.nl>2008-03-28 22:53:32 +0000
committerSiep Kroonenberg <siepo@cybercomm.nl>2008-03-28 22:53:32 +0000
commit75d6ef94ce62506d8e90017e564b87bf631eab3f (patch)
treeb5f2c0c40ca85e7087600e091109737fb0b64f13 /Master/tlpkg/doc
parente5e997d04fad4016c49b495c2c29a203230e0538 (diff)
Edits in BachoTeX paper
git-svn-id: svn://tug.org/texlive/trunk@7206 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/doc')
-rw-r--r--Master/tlpkg/doc/tlinst-BT08.tex131
-rw-r--r--Master/tlpkg/doc/wingoo-demo.pl56
2 files changed, 107 insertions, 80 deletions
diff --git a/Master/tlpkg/doc/tlinst-BT08.tex b/Master/tlpkg/doc/tlinst-BT08.tex
index dbfc433cd09..4789924a1c2 100644
--- a/Master/tlpkg/doc/tlinst-BT08.tex
+++ b/Master/tlpkg/doc/tlinst-BT08.tex
@@ -4,8 +4,8 @@
% Article presented on the 16th BachoTeX meeting, Bachotek ?? May 2008
%
% Copyright 2007 Norbert Preining at al.
-% You can redistribute and/or modify this document under the terms of the
-% GNU General Public License as published by the Free Software Foundation;
+% You can redistribute and/or modify this document under the terms of the
+% GNU General Public License as published by the Free Software Foundation;
% either version 2 of the License, or (at your option) any later version.
%
%\documentclass{arstexnica}
@@ -100,50 +100,41 @@
\section{Introduction}
\label{sec:intro}
+In this paper we introduce the new \tl\ installer. Its creation was
+necessitated by the brand-new package infrastructure -- described
+elsewhere in these proceedings.
+However, there is more news, also from a user's point of view. In
+particular:
+\begin{itemize}
+\item It will be possible to install \tl\ from the internet.
+\item The Windows version is much more in line with Unix versions.
+\item There is just one installer, which can run either in text mode
+ or in GUI mode.
+\end{itemize}
+\section{\tlu}
-\section{What's new?}
-
-\subsection{Multiplatform Installations}
-It had always been possible to install \tl\ on a UNIX server and mount
-the \tl\ directory on many platforms. On Windows there had been some
-restrictions. Since \tl\ for Windows had been regarded as a
-single-user system in the past, *|-sys|-Programs like |fmtutil-sys| or
-|updmap-sys| had not been provided. Thus, it was necessary to provide
-a separate |texmf.cnf| file for Windows.
-
-The *|-sys| programs could be implemented easily in |texlua|. There
-are several reasons to use |texlua| for this purpose:
+Nowadays \TeX{} contains a customized copy of Lua as embedded
+scripting language. When called as \tlu, it acts as a standalone Lua
+interpreter, customized for a \TeX{} environment. This is a very
+attractive scripting solution:
\begin{itemize}
-\item |texlua| is a scripting language and therefore the programs are
- platform independent and much easier to maintain than C programs.
-\item |texlua| has \kpse\ compiled in. In a |texlua| script the
+\item no discrepancies between versions: \tlu{} scripts should
+ simply match the \TeX{} version they are part of.
+\item \tlu{} has \kpse\ compiled in. In a \tlu{} script the
location of a particular file can be determined very fast.
-\item |texlua| is a small, simple but very powerful programming
- language. Its simplicity makes the code easy to maintain.
+\item An embedded scripting language is immune from the kind of
+ bloat suffered by popular scripting languages such as \pl{} and
+ Ruby.
\end{itemize}
+Under Windows, |.texlua| files are made executable by the installer.
-In order to allow to use the same |texmf.cnf| for all platforms, Karl
-Berry implemented tilde expansion to \kpse. That means that the entry
-\begin{verbatim}
- ~/texmf
-\end{verbatim}
-in |texmf.cnf| expands to
-\begin{verbatim}
- $HOME/texmf
-\end{verbatim}
-on UNIX, but to
-\begin{verbatim}
- %USERPROFILE%\texmf
-\end{verbatim}
-on Windows.
-
-\subsection{Install \tl\ from the Internet}
+\section{Install \tl\ from the Internet}\label{texlua}
It is now possible to install \tl\ from a remote server. Thanks to
the new infrastructure, the package database which is needed by the
installer in order to determine which packages have to be downloaded
-and how to install them is a single file.
+and how to install them is a single file.
Two installers for network downloads are provided.
|install-tl.tar.gz.| supports UNIX only. |install-tl.zip|
@@ -153,33 +144,61 @@ supported by \tl. The sole reason for providing a separate package
for UNIX is its significantly smaller size.
-\subsection{A new compression Algorithm}
+\section{A new compression Algorithm}
Using |.tar.lzma| compression instead of |.zip| reduces the size of the
compressed packages by 20\%. It cannot be assumed that |lzma|
decompressors are available on any platform, hence they have to be
-provided for all platforms supported by \tl\. Fortunately there is a
+provided for all platforms supported by \tl. Fortunately there is a
program `|lzmadec|' available for all platforms. The size of the
-executable file is only 12\,kB.
-
-\subsection{Perl and Ghostscript}
-Though it can be assumed that \pl\ and \gs\ are installed on every
-UNIX system, this is quite uncommon on Windows. Former versions of
-\tl\ installed these programs on demand but it is quite difficult to
-avoid conflicts with instances of these programs already installed.
-
-A better solution is to hide these programs and make them visible only
-to the scripts which need them. This is done by wrapper scripts
-written in \tlu The purpose of these scripts is to start another
-program in a changed environment, and \tlu\ turned out to be the
-ultimate programming language for such wrappers because it has \kpse\
-built in.
-
-The most important batch files provided by \gs\ had been ported to
-\tlu\ too.
+executable file is only 12\,kB.
+
+\section{Bringing Windows in line with Unix}
+
+\tl\ 2008 supports Windows 2000 and later. By dropping older Windows
+versions, there is much less need to treat Windows specially.
+
+\subsection{\texttt{\$HOME} and multi-user support}
+Under Windows 2000 and later, users have a real home directory,
+viz. \verb+%USERPROFILE%+, usually
+\verb+C:\Documents and Settings\+\textit{username}.
+
+This is now reflected in tilde expansion by \kpse, thanks to Karl
+Berry: \verb+~/texmf+ is expanded to \verb+%USERPROFILE%\texmf+
+under Windows and to \verb+$HOME+ under Unix.
+
+It is also possible to differentiate between system settings and
+user settings. Now there is no reason any more to have a different
+set of \texttt{texmf} trees or to leave out scripts such as
+\texttt{fmtutil-sys} and \texttt{updmap-sys}. It also shares the
+Unix \texttt{texmf.cnf}.
+
+\subsection{Scripting}
+We cannot count on the presence of the usual Unix scripting
+languages. We deal with this by including a limited subset of \pl{}
+for Windows, which contains just enough modules to run the installer
+and the \pl{} scripts which are part of \tl.
+
+To prevent interference with any pre-existing \pl, we make it
+invisible to the system by not placing it on the searchpath and by
+not creating or changing any \pl-related settings. Instead, the
+\tl\ \pl\ scripts are called via wrapper scripts that know how to
+find Perl and that create the necessary environment variables for
+the hidden \pl{} for the duration of the job. In the case of the
+installer itself, the wrapper is a simple batchfile (but not so
+simple that it would have worked under earlier Windows
+versions). But in most cases, the wrapper is written in \tlu; see
+section \ref{texlua}.
+
+\subsection{\gs}
+
+\tl{} for Windows also includes a hidden copy of \gs, another
+fixture of Unix systems that is usually absent under Windows. The
+most important batch files provided by \gs\ have been ported to
+\tlu{}, see \ref{texlua}.
%\bibliographystyle{arstexnica}
%\bibliography{atsample}
-
+
%\end{article}
\end{document}
diff --git a/Master/tlpkg/doc/wingoo-demo.pl b/Master/tlpkg/doc/wingoo-demo.pl
index 1b2944e9385..84c0a455a77 100644
--- a/Master/tlpkg/doc/wingoo-demo.pl
+++ b/Master/tlpkg/doc/wingoo-demo.pl
@@ -26,7 +26,9 @@ BEGIN {
}
use TeXLive::TLUtils qw( get_system_tmpdir );
-use TeXLive::TLWinGoo qw(
+use TeXLive::TLWinGooTry qw(
+ &win_version
+ &is_vista
&admin
&non_admin
&admin_again
@@ -65,13 +67,12 @@ sub maybenot {
sub create_file {
my $name = shift;
- return if -e $name;
- eval {
- open DUMMY, ">".$name;
- print DUMMY 's = tostring(0.0000001)'; # lua: 1e-7; texlua: 0
- print DUMMY ('print("0.0000001 becomes " .. s)');
- close DUMMY;
- } ;
+ return 1 if -e $name;
+ return 0 unless open DUMMY, ">".$name;
+ print DUMMY 's = tostring(0.0000001)'; # lua: 1e-7; texlua: 0
+ print DUMMY ('print("0.0000001 becomes " .. s)');
+ close DUMMY;
+ return 1;
}
sub print_search_paths {
@@ -130,6 +131,11 @@ if (admin()) {
print "\nGlobal tempdir: " . global_tmpdir()."\n";
+# Windows version
+
+print "Windows version: ".win_version()."\n";
+print maybenot(is_vista()). " Vista\n";
+
if ($^O !~ /^MSWin(32|64)$/i) {
print "Not Windows; bailing out...\n";
exit;
@@ -137,8 +143,8 @@ if ($^O !~ /^MSWin(32|64)$/i) {
### end of non-windows
-my @winversion = Win32::GetOSVersion();
-print "Windows version: " . $winversion[1] . "\n";
+#my @winversion = Win32::GetOSVersion();
+#print "Windows version: " . $winversion[1] . "\n";
# country
@@ -222,30 +228,32 @@ while (1) { # running this first as admin (if possible) and then as non-admin
if (admin()) {
non_admin();
next;
- } elsif ($winversion[1]>=6) { last; }
- #vista: don't try this
+ }
# the problem case: no admin, but TeX on system path
print( "\nNon-admin path problem\n" );
my $fn = expand_string("%windir%")."/TEX.EXE";
$fn =~ s/\\/\//g;
- create_file($fn); # a tex.exe on the system path!
- add_texbindir_to_path(expand_string($wr_dir2));
- my @wge = wg_error();
- if (@wge) {
- print $wge[1]."\n";
+ if (create_file($fn)) { # a tex.exe on the system path!
+ add_texbindir_to_path(expand_string($wr_dir2));
+ my @wge = wg_error();
+ if (@wge) {
+ print $wge[1]."\n";
+ }
+ print( "Cannot remove tex from system searchpath\n" );
+ print_search_paths();
+ print "Wrong tex.exe found in " . win_which_dir("tex.exe") . "\n";
+ unlink $fn;
+ remove_texbindirs_from_path();
+ broadcast_env();
+ pause( "Non-admin: check environment in new dosbox" );
+ } else {
+ print "Cannot test; cannot create $fn\n";
}
- print( "Cannot remove tex from system searchpath\n" );
- print_search_paths();
- print "Wrong tex.exe found in " . win_which_dir("tex.exe") . "\n";
- unlink $fn;
- remove_texbindirs_from_path();
# broadcast environment changes
- broadcast_env();
- pause( "Non-admin: check environment in new dosbox" );
if (!admin()) { last; }
}