summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xMaster/install-tl2
-rwxr-xr-xMaster/texmf/scripts/texlive/tlmgr.pl5
-rw-r--r--Master/tlpkg/TeXLive/TLMedia.pm2
-rw-r--r--Master/tlpkg/TeXLive/TLPostActions.pm (renamed from Master/tlpkg/TeXLive/TLPostInstall.pm)13
4 files changed, 14 insertions, 8 deletions
diff --git a/Master/install-tl b/Master/install-tl
index 1932e46baed..8659cd31d0c 100755
--- a/Master/install-tl
+++ b/Master/install-tl
@@ -49,7 +49,7 @@ use TeXLive::TLUtils qw(initialize_installer media platform platform_desc
use TeXLive::TLPOBJ;
use TeXLive::TLPDB;
use TeXLive::TLConfig;
-use TeXLive::TLPostInstall;
+use TeXLive::TLPostActions;
use Pod::Usage;
use Cwd 'abs_path';
diff --git a/Master/texmf/scripts/texlive/tlmgr.pl b/Master/texmf/scripts/texlive/tlmgr.pl
index cf3bacf9836..051148ba663 100755
--- a/Master/texmf/scripts/texlive/tlmgr.pl
+++ b/Master/texmf/scripts/texlive/tlmgr.pl
@@ -240,6 +240,11 @@ sub remove_package {
# disadvantage: removing a collection calls the save routine several times
# still I consider it better that the tlpdb is in a consistent state
$localtlpdb->save;
+ # do the post removal actions
+ if (defined($PostRemove{$pkg})) {
+ tllog($::LOG_NORMAL, "running post remove action for $pkg\n");
+ &{$PostRemove{$pkg}}($totlpdb->root);
+ }
}
return \%ret;
}
diff --git a/Master/tlpkg/TeXLive/TLMedia.pm b/Master/tlpkg/TeXLive/TLMedia.pm
index 67624c2ea39..bddbdd529fd 100644
--- a/Master/tlpkg/TeXLive/TLMedia.pm
+++ b/Master/tlpkg/TeXLive/TLMedia.pm
@@ -9,7 +9,7 @@
package TeXLive::TLMedia;
use TeXLive::TLConfig;
-use TeXLive::TLPostInstall;
+use TeXLive::TLPostActions;
use TeXLive::TLUtils qw(tllog copy win32 dirname mkdirhier conv_to_win_path basename download_file merge_into);
use TeXLive::TLPDB;
use Cwd qw/abs_path/;
diff --git a/Master/tlpkg/TeXLive/TLPostInstall.pm b/Master/tlpkg/TeXLive/TLPostActions.pm
index 07591f9a6a9..bc0c82509ca 100644
--- a/Master/tlpkg/TeXLive/TLPostInstall.pm
+++ b/Master/tlpkg/TeXLive/TLPostActions.pm
@@ -1,10 +1,10 @@
# $Id$
-# TeXLive::TLPostInstall.pm - collection post install stuff for installation
+# TeXLive::TLPostActions.pm - collection post install stuff for installation
# Copyright 2008 Norbert Preining
# This file is licensed under the GNU General Public License version 2
# or any later version.
-package TeXLive::TLPostInstall;
+package TeXLive::TLPostActions;
BEGIN {
use Exporter ();
@@ -19,6 +19,7 @@ BEGIN {
use TeXLive::TLUtils qw(win32 mkdirhier copy);
our %PostInstall;
+our %PostRemove;
sub do_bin_xetex {
@@ -187,16 +188,16 @@ sub do_context {
=head1 NAME
-C<TeXLive::TLPostInstall> -- TeX Live Post Installation Routines
+C<TeXLive::TLPostActions> -- TeX Live Post Installation and Removal Routines
=head1 SYNOPSIS
- use TeXLive::TLPostInstall;
+ use TeXLive::TLPostActions;
=head1 DESCRIPTION
-The L<TeXLive::TLPostInstall> module exports the C<%PostInstall> hash indexed
-by package names providing code references.
+The L<TeXLive::TLPostActions> module exports the C<%PostInstall> and
+the C<%PostRemove> hash indexed by package names providing code references.
These code references are called with the root of the installation as
argument (C<$SELFAUTOPARENT>). Additional arguments, but not necessarily