diff options
author | Karl Berry <karl@freefriends.org> | 2013-08-15 22:33:59 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2013-08-15 22:33:59 +0000 |
commit | 816a0af11a279e2c61f6a49a700cf0f3762945d0 (patch) | |
tree | d825fd432cf189e75ee7978fdf883b17bb84312a /Build/source/texk/tests | |
parent | b334c30fe0a0faa600731910cc98905b9f0b4955 (diff) |
sync, doc tweaks
git-svn-id: svn://tug.org/texlive/trunk@31439 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/tests')
-rw-r--r-- | Build/source/texk/tests/TeXLive/TLUtils.pm | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/Build/source/texk/tests/TeXLive/TLUtils.pm b/Build/source/texk/tests/TeXLive/TLUtils.pm index 8710c7b0e2a..3e87f9d56d4 100644 --- a/Build/source/texk/tests/TeXLive/TLUtils.pm +++ b/Build/source/texk/tests/TeXLive/TLUtils.pm @@ -5,7 +5,7 @@ package TeXLive::TLUtils; -my $svnrev = '$Revision: 30935 $'; +my $svnrev = '$Revision: 31259 $'; my $_modulerevision; if ($svnrev =~ m/: ([0-9]+) /) { $_modulerevision = $1; @@ -2892,18 +2892,28 @@ sub create_language_lua { } sub _create_config_files { - my ($tlpdb, $headfile, $dest,$localconf, $keepfirstline, $cc, $tlpdblinesref, @postlines) = @_; + my ($tlpdb, $headfile, $dest,$localconf, $keepfirstline, $cc, + $tlpdblinesref, @postlines) = @_; my $root = $tlpdb->root; - open(INFILE,"<$root/$headfile") or die("Cannot open $root/$headfile"); - my @lines = <INFILE>; + my @lines = (); + if (-r "$root/$headfile") { + # we might be in user mode and do *not* want that the generation + # of the configuration file just boils out. + open (INFILE, "<$root/$headfile") + || die "open($root/$headfile) failed, but -r ok: $!"; + @lines = <INFILE>; + close (INFILE); + } else { + tlwarn("TLUtils::_create_config_files: $root/$headfile: " + . " head file not found, ok in user mode"); + } push @lines, @$tlpdblinesref; - close (INFILE); if (defined($localconf) && -r $localconf) { # # this should be done more intelligently, but for now only add those # lines without any duplication check ... - open FOO, "<$localconf" - or die "strange, -r ok but cannot open $localconf: $!"; + open (FOO, "<$localconf") + || die "strange, -r ok but cannot open $localconf: $!"; my @tmp = <FOO>; close (FOO); push @lines, @tmp; |