diff options
Diffstat (limited to 'Master/bin/win32/getnonfreefonts.bat')
-rw-r--r-- | Master/bin/win32/getnonfreefonts.bat | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/Master/bin/win32/getnonfreefonts.bat b/Master/bin/win32/getnonfreefonts.bat index 91551f38d28..1967ce698b2 100644 --- a/Master/bin/win32/getnonfreefonts.bat +++ b/Master/bin/win32/getnonfreefonts.bat @@ -114,7 +114,7 @@ sub expand_var { }
while (<KPSEWHICH>) {
chop;
- return $_;
+ return "$_";
}
close KPSEWHICH;
}
@@ -179,11 +179,9 @@ if ($opt_debug) { }
-if ($sys) {
- $INSTALLROOT=expand_var 'TEXMFLOCAL';
-} else {
- $INSTALLROOT=expand_var 'TEXMFHOME';
-}
+$INSTALLROOTNAME=($sys)? 'TEXMFLOCAL':'TEXMFHOME';
+
+$INSTALLROOT=expand_var "$INSTALLROOTNAME";
($sys)? debug_msg "sys=true":debug_msg "sys=false";
@@ -195,7 +193,13 @@ $INSTALLROOT=~s/\\/\//g if ($INSTALLROOT=~/^\\\\/); # \\abc\def debug_msg "Internal variable INSTALLROOT converted to '$INSTALLROOT'";
sub check_installroot {
- die "! ERROR: The install directory '$INSTALLROOT' doesn't exist.\n"
+ die "! ERROR: The variable $INSTALLROOTNAME is not set.\n"
+ unless length ("$INSTALLROOT") > 0;
+
+ die "! ERROR: The install directory '$INSTALLROOT' doesn't " .
+ "exist.\n" .
+ " If this is the correct path, please create " .
+ "this directory manually.\n"
unless (-d "$INSTALLROOT");
die "! ERROR: The install directory '$INSTALLROOT' is not writable.\n"
|