From c9a39f716f1e5ec820ed3aab2c9aef25c5a9d730 Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 14 May 2012 15:04:35 +0000 Subject: update updmap.pl from source: - fix disableMap undefined - fix missing lsR after creating a new config file git-svn-id: svn://tug.org/texlive/trunk@26370 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf/scripts/texlive/updmap.pl | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'Master/texmf') diff --git a/Master/texmf/scripts/texlive/updmap.pl b/Master/texmf/scripts/texlive/updmap.pl index dbf83a2aad5..5f81184dd85 100755 --- a/Master/texmf/scripts/texlive/updmap.pl +++ b/Master/texmf/scripts/texlive/updmap.pl @@ -1,6 +1,6 @@ #!/usr/bin/env perl # mupdmap: utility to maintain map files for outline fonts. -# $Id: updmap.pl 26362 2012-05-14 09:46:53Z preining $ +# $Id: updmap.pl 26369 2012-05-14 15:00:53Z preining $ # # Copyright 2011, 2012 Norbert Preining # This file is licensed under the GNU General Public License version 2 @@ -34,7 +34,7 @@ BEGIN { } -my $version = '$Id: updmap.pl 26362 2012-05-14 09:46:53Z preining $'; +my $version = '$Id: updmap.pl 26369 2012-05-14 15:00:53Z preining $'; use Getopt::Long qw(:config no_autoabbrev ignore_case_always); use strict; @@ -340,16 +340,18 @@ sub main { if ($opts{'syncwithtrees'}) { my @missing = read_map_files(); if (@missing) { - print "Missing map files found, disabling them in $changes_config_file\n"; - for my $m (@missing) { - $changed ||= disableMap($m); - } + print "Missing map files found, disabling\n @missing\nin $changes_config_file\n"; + $changed ||= enable_disable_maps(@missing); # the original script did not run any update of the map files here, # should we do that? } exit 0; } + # what does this? + $updLSR = &mktexupd(); + $updLSR->{mustexist}(0); + my $cmd; if ($opts{'edit'}) { if ($opts{"dry-run"}) { @@ -378,9 +380,6 @@ sub main { $changed ||= enable_disable_maps(@{$opts{'enable'}}, @{$opts{'disable'}}); } - # what does this? - $updLSR = &mktexupd(); - $updLSR->{mustexist}(0); if ($cmd && !$opts{'force'} && !$changed) { print "$changes_config_file unchanged. Map files not recreated.\n" @@ -1334,6 +1333,10 @@ sub save_updmap { } close(FN) || warn("Cannot close file handle for $fn: $!"); delete $alldata->{'updmap'}{$fn}{'changed'}; + # + # update lsR database + $updLSR->{add}($fn); + # return 1; } return 0; -- cgit v1.2.3