diff options
author | Vladimir Volovich <vvv@vsu.ru> | 2008-07-29 12:55:01 +0000 |
---|---|---|
committer | Vladimir Volovich <vvv@vsu.ru> | 2008-07-29 12:55:01 +0000 |
commit | a68489f9f86349004a9bfda8b3482705a678c00f (patch) | |
tree | 1607184b0aca90a6c767b099f646f89fdb432fb8 /Master/texmf/scripts/xindy/xindy.pl | |
parent | ef285e6a49a93af098150d0b3125a34d3477ba55 (diff) |
add support for Mac universal binary: xindy.run is one binary for intel and powerpc Mac,
but the mem file depends on machine type: xindy-powerpc.mem or xindy-i386.mem
git-svn-id: svn://tug.org/texlive/trunk@9870 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf/scripts/xindy/xindy.pl')
-rwxr-xr-x | Master/texmf/scripts/xindy/xindy.pl | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/Master/texmf/scripts/xindy/xindy.pl b/Master/texmf/scripts/xindy/xindy.pl index 72407935c54..4dc4465b8ab 100755 --- a/Master/texmf/scripts/xindy/xindy.pl +++ b/Master/texmf/scripts/xindy/xindy.pl @@ -345,7 +345,7 @@ BEGIN { use Getopt::Long qw(:config bundling); use File::Temp qw(tempfile tmpnam); use File::Spec; - +use POSIX qw(uname); # Check arguments, store them in proper variables. # @@ -396,7 +396,18 @@ our ($quiet, $verbose, %debug, $outfile, $logfile, $language, @codepages, @modules, $input_markup, $interactive, $mem_file); $input_markup = 'latex'; + $mem_file = "$lib_dir/xindy.mem"; +if ($^O eq 'darwin' && ! -e $mem_file) { + # support universal binary on mac + my @uname = POSIX::uname(); + if ($uname[4] eq 'Power Macintosh') { + $mem_file = "$lib_dir/xindy-powerpc.mem"; + } else { + $mem_file = "$lib_dir/xindy-i386.mem"; + } +} +die "$cmd: Cannot locate $mem_file" if ! -e $mem_file; parse_options(); |