From 80071d5e4dddda14b0a3228d9b39f4315737945f Mon Sep 17 00:00:00 2001 From: Vladimir Volovich Date: Sat, 5 Sep 2009 12:37:28 +0000 Subject: adapt xindy front-end scripts to TL2009 on woe32: SELFAUTOLOC was set in TL2008 by the wrapper commands (xindy.bat and texindy.bat) but SELFAUTOLOC is no longer set in TL2009 by the new wrapper commands (xindy.exe and texindy.exe), and instead there's a TL_ROOT env. var. This appears to work when TL is being run from a letter-mapped "drive" but doesn't work when run directly from a network share w/o a letter mapping. git-svn-id: svn://tug.org/texlive/trunk@15129 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/utils/xindy/user-commands/texindy | 7 +++++-- Build/source/utils/xindy/user-commands/xindy.in | 5 ++++- 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'Build') diff --git a/Build/source/utils/xindy/user-commands/texindy b/Build/source/utils/xindy/user-commands/texindy index 64dfbd71d46..72e86e7939c 100755 --- a/Build/source/utils/xindy/user-commands/texindy +++ b/Build/source/utils/xindy/user-commands/texindy @@ -367,6 +367,9 @@ if ( -f "$cmd_dir/xindy" && -x _ ) { $xindy = "$cmd_dir/xindy"; } elsif ( -f "$cmd_dir/xindy.pl" && -x _ ) { $xindy = "$cmd_dir/xindy.pl"; +} elsif ( exists $ENV{"TL_ROOT"} && -f "$ENV{TL_ROOT}\\bin\\win32\\xindy.exe") { + $xindy = "$ENV{TL_ROOT}\\bin\\win32\\xindy.exe"; + $cmd_dir = "$ENV{TL_ROOT}\\bin\\win32"; } elsif ( -f "$ENV{SELFAUTOLOC}/xindy.bat" ) { # woe32 $xindy = "$ENV{SELFAUTOLOC}/xindy.bat"; $cmd_dir = $ENV{"SELFAUTOLOC"}; @@ -394,9 +397,9 @@ push (@opt, map { ('-M', $_) } ($ENV{TEXINDY_AUTO_MODULE} || 'texindy', @modules)); push (@opt, '-I', $input_markup); -print "Calling xindy as: $cmd_dir/xindy @opt @ARGV\n" if (grep /^script$/, @debug); +print "Calling xindy as: $xindy @opt @ARGV\n" if (grep /^script$/, @debug); -if ($xindy =~ m,\.bat$,) { +if ($xindy =~ m,\.(bat|exe)$,) { system($xindy, @opt, @ARGV); exit $? if $? != -1; } else { diff --git a/Build/source/utils/xindy/user-commands/xindy.in b/Build/source/utils/xindy/user-commands/xindy.in index 34f1714d392..3d3814f2377 100644 --- a/Build/source/utils/xindy/user-commands/xindy.in +++ b/Build/source/utils/xindy/user-commands/xindy.in @@ -306,7 +306,10 @@ BEGIN { die "$cmd: Invalid XINDY_LIBDIR setting: cannot find $lib_dir/$xindy_run" if ! -f "$lib_dir/$xindy_run"; } elsif ( -f "$cmd_dir/$xindy_run" ) { # texlive unix $lib_dir = $cmd_dir; - } elsif ( exists $ENV{"SELFAUTOLOC"} && -f "$ENV{SELFAUTOLOC}/$xindy_run" ) { # texlive woe32 + } elsif ( exists $ENV{"TL_ROOT"} && -f "$ENV{TL_ROOT}\\bin\\win32\\$xindy_run") { # TL2009 woe32 + $lib_dir = "$ENV{TL_ROOT}\\bin\\win32"; + $cmd_dir = "$ENV{TL_ROOT}\\bin\\win32"; + } elsif ( exists $ENV{"SELFAUTOLOC"} && -f "$ENV{SELFAUTOLOC}/$xindy_run" ) { # TL2008 woe32 $lib_dir = $ENV{"SELFAUTOLOC"}; $cmd_dir = $ENV{"SELFAUTOLOC"}; } elsif ( '@libdir@' ne '@libdir' . '@' ) { # GNU configure at work? -- cgit v1.2.3