From 6115117d6486cc4249133b5404bfcdeafb26df40 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 17 Mar 2008 12:23:47 +0000 Subject: uninstaller work git-svn-id: svn://tug.org/texlive/trunk@6982 c570f23f-e606-0410-a88d-b1316a301751 --- Master/install-tl.pl | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) (limited to 'Master/install-tl.pl') diff --git a/Master/install-tl.pl b/Master/install-tl.pl index 72d7fe42dcf..8197dce0237 100755 --- a/Master/install-tl.pl +++ b/Master/install-tl.pl @@ -362,6 +362,8 @@ sub do_installation { &$h(); } do_postinst_stuff(); + save_options_into_tlpdb(); + $localtlpdb->save; foreach my $h (@::end_install_hook) { &$h(); } @@ -707,6 +709,40 @@ sub do_install_packages { install_packages($tlpdb,$localtlpdb,\@what,\@netarchs,$vars{'option_src'},$vars{'option_doc'}); } +# for later complete removal we want to save some options and values +# into the local tlpdb: +# - should links be set, and if yes, the destination (bin,man,info) +sub save_options_into_tlpdb { + my $tlp = new TeXLive::TLPOBJ; + $tlp->name("00texlive-installation.config"); + $tlp->category("TLCore"); + my @deps; + if ($vars{'option_letter'}) { + push @deps, "option_letter"; + } + if ($vars{'option_fmt'}) { + push @deps, "option_fmt"; + } + if ($vars{'option_symlinks'}) { + push @deps, "option_symlinks"; + push @deps, "sys_bin/$vars{'sys_bin'}"; + push @deps, "sys_info/$vars{'sys_info'}"; + push @deps, "sys_man/$vars{'sys_man'}"; + } + if ($vars{'option_doc'}) { + push @deps, "option_doc"; + } + if ($vars{'option_src'}) { + push @deps, "option_src"; + } + push @deps, "TEXDIR/$vars{'TEXDIR'}"; + push @deps, "TEXMFSYSVAR/$vars{'TEXMFSYSVAR'}"; + push @deps, "TEXMFLOCAL/$vars{'TEXMFLOCAL'}"; + push @deps, "TEXMFHOME/$vars{'TEXMFHOME'}"; + $tlp->depends(@deps); + $localtlpdb->add_tlpobj($tlp); + $localtlpdb->save(); +} # do_postinst_stuff has to fix up the texmf tree and install some missing # files. The things to do are taken from the install-live.sh installer -- cgit v1.2.3