| 1 |
#! /bin/sh -vx |
| 2 |
# $Id: makeindex.test 73835 2025-02-09 23:41:59Z takuji $ |
| 3 |
# Copyright 2024-2025 TANAKA Takuji <[email protected]> |
| 4 |
# Copyright 2017 Karl Berry <[email protected]> |
| 5 |
# Copyright 2012 Peter Breitenlohner <[email protected]> |
| 6 |
# You may freely use, modify and/or distribute this file. |
| 7 |
|
| 8 |
BinDir=${BinDir:-.} |
| 9 |
ExeExt=${ExeExt:-} |
| 10 |
_makeindex=$BinDir/makeindex$ExeExt |
| 11 |
|
| 12 |
TEXMFCNF=$srcdir/../kpathsea |
| 13 |
export TEXMFCNF |
| 14 |
|
| 15 |
rm -f sample.* tort*.* |
| 16 |
rc=0 |
| 17 |
|
| 18 |
$_makeindex $srcdir/tests/sample.idx -o sample.ind1 -t sample.ilg1 \ |
| 19 |
&& diff $srcdir/tests/sample.ind sample.ind1 || rc=1 |
| 20 |
|
| 21 |
cat $srcdir/tests/sample.idx | $_makeindex >sample.ind2 2>sample.ilg2 \ |
| 22 |
&& diff $srcdir/tests/sample.ind sample.ind2 || rc=2 |
| 23 |
|
| 24 |
$_makeindex $srcdir/tests/tort.idx -o tort.ind1 -t tort.ilg1 \ |
| 25 |
&& diff $srcdir/tests/ok-tort.ind tort.ind1 || rc=20 |
| 26 |
|
| 27 |
$_makeindex $srcdir/tests/tortW.idx -o tortW.ind1 -t tortW.ilg1 \ |
| 28 |
&& diff $srcdir/tests/ok-tort.ind tortW.ind1 || rc=21 |
| 29 |
|
| 30 |
$_makeindex $srcdir/tests/tort.idx -s $srcdir/tests/head1.ist -o tort2.ind1 -t tort2.ilg1 \ |
| 31 |
&& diff $srcdir/tests/ok-tort2.ind tort2.ind1 || rc=22 |
| 32 |
|
| 33 |
$_makeindex $srcdir/tests/tortW.idx -s $srcdir/tests/head1.ist -o tortW2.ind1 -t tortW2.ilg1 \ |
| 34 |
&& diff $srcdir/tests/ok-tort2.ind tortW2.ind1 || rc=23 |
| 35 |
|
| 36 |
|
| 37 |
exit $rc |