summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/kpathsea/kpathsea.html
blob: 883cc129293c0602747a7eb005c70dc4ef737ed1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- This file documents the Kpathsea library for path searching.

Copyright (C) 1996-2021 Karl Berry & Olaf Weber.

Permission is granted to make and distribute verbatim copies of this
manual provided the copyright notice and this permission notice are
preserved on all copies.


Permission is granted to copy and distribute modified versions of this
manual under the conditions for verbatim copying, provided that the
entire resulting derived work is distributed under the terms of a
permission notice identical to this one.

Permission is granted to copy and distribute translations of this manual
into another language, under the above conditions for modified versions,
except that this permission notice may be stated in a translation
approved by the TeX Users Group. -->
<!-- Created by GNU Texinfo 6.7, http://www.gnu.org/software/texinfo/ -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Kpathsea: A library for path searching</title>

<meta name="description" content="Kpathsea: A library for path searching">
<meta name="keywords" content="Kpathsea: A library for path searching">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<link href="#Top" rel="start" title="Top">
<link href="#Index" rel="index" title="Index">
<link href="#SEC_Contents" rel="contents" title="Table of Contents">
<link href="http://tug.org/texinfohtml" rel="up" title="(dir)">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: initial; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>


</head>

<body lang="en">
<h1 class="settitle" align="center">Kpathsea: A library for path searching</h1>









<span id="SEC_Contents"></span>
<h2 class="contents-heading">Table of Contents</h2>

<div class="contents">

<ul class="no-bullet">
  <li><a id="toc-Introduction-1" href="#Introduction">1 Introduction</a>
  <ul class="no-bullet">
    <li><a id="toc-History-1" href="#History">1.1 History</a></li>
  </ul></li>
  <li><a id="toc-unixtex_002eftp_003a-Obtaining-TeX" href="#unixtex_002eftp">2 <samp>unixtex.ftp</samp>: Obtaining TeX</a></li>
  <li><a id="toc-Security-1" href="#Security">3 Security</a></li>
  <li><a id="toc-TeX-directory-structure-1" href="#TeX-directory-structure">4 TeX directory structure</a></li>
  <li><a id="toc-Path-searching-1" href="#Path-searching">5 Path searching</a>
  <ul class="no-bullet">
    <li><a id="toc-Searching-overview-1" href="#Searching-overview">5.1 Searching overview</a></li>
    <li><a id="toc-Path-sources-1" href="#Path-sources">5.2 Path sources</a>
    <ul class="no-bullet">
      <li><a id="toc-Config-files-1" href="#Config-files">5.2.1 Config files</a></li>
    </ul></li>
    <li><a id="toc-Path-expansion-1" href="#Path-expansion">5.3 Path expansion</a>
    <ul class="no-bullet">
      <li><a id="toc-Default-expansion-1" href="#Default-expansion">5.3.1 Default expansion</a></li>
      <li><a id="toc-Variable-expansion-1" href="#Variable-expansion">5.3.2 Variable expansion</a></li>
      <li><a id="toc-Tilde-expansion-1" href="#Tilde-expansion">5.3.3 Tilde expansion</a></li>
      <li><a id="toc-Brace-expansion-1" href="#Brace-expansion">5.3.4 Brace expansion</a></li>
      <li><a id="toc-KPSE_005fDOT-expansion-1" href="#KPSE_005fDOT-expansion">5.3.5 <code>KPSE_DOT</code> expansion</a></li>
      <li><a id="toc-Subdirectory-expansion-1" href="#Subdirectory-expansion">5.3.6 Subdirectory expansion</a></li>
    </ul></li>
    <li><a id="toc-Casefolding-search-1" href="#Casefolding-search">5.4 Casefolding search</a>
    <ul class="no-bullet">
      <li><a id="toc-Casefolding-rationale-1" href="#Casefolding-rationale">5.4.1 Casefolding rationale</a></li>
      <li><a id="toc-Casefolding-examples-1" href="#Casefolding-examples">5.4.2 Casefolding examples</a></li>
    </ul></li>
    <li><a id="toc-Filename-database-_0028ls_002dR_0029" href="#Filename-database">5.5 Filename database (<code>ls-R</code>)</a>
    <ul class="no-bullet">
      <li><a id="toc-ls_002dR-1" href="#ls_002dR">5.5.1 <samp>ls-R</samp></a></li>
      <li><a id="toc-Filename-aliases-1" href="#Filename-aliases">5.5.2 Filename aliases</a></li>
      <li><a id="toc-Database-format-1" href="#Database-format">5.5.3 Database format</a></li>
    </ul></li>
    <li><a id="toc-kpsewhich_003a-Standalone-path-searching" href="#Invoking-kpsewhich">5.6 <code>kpsewhich</code>: Standalone path searching</a>
    <ul class="no-bullet">
      <li><a id="toc-Path-searching-options-1" href="#Path-searching-options">5.6.1 Path searching options</a></li>
      <li><a id="toc-Specially_002drecognized-files-for-kpsewhich" href="#Specially_002drecognized-files">5.6.2 Specially-recognized files for <code>kpsewhich</code></a></li>
      <li><a id="toc-Auxiliary-tasks-1" href="#Auxiliary-tasks">5.6.3 Auxiliary tasks</a></li>
      <li><a id="toc-Standard-options-1" href="#Standard-options">5.6.4 Standard options</a></li>
    </ul></li>
  </ul></li>
  <li><a id="toc-TeX-support-1" href="#TeX-support">6 TeX support</a>
  <ul class="no-bullet">
    <li><a id="toc-Supported-file-formats-1" href="#Supported-file-formats">6.1 Supported file formats</a></li>
    <li><a id="toc-File-lookup-1" href="#File-lookup">6.2 File lookup</a></li>
    <li><a id="toc-Glyph-lookup-1" href="#Glyph-lookup">6.3 Glyph lookup</a>
    <ul class="no-bullet">
      <li><a id="toc-Basic-glyph-lookup-1" href="#Basic-glyph-lookup">6.3.1 Basic glyph lookup</a></li>
      <li><a id="toc-Fontmap-1" href="#Fontmap">6.3.2 Fontmap</a></li>
      <li><a id="toc-Fallback-font-1" href="#Fallback-font">6.3.3 Fallback font</a></li>
    </ul></li>
    <li><a id="toc-Suppressing-warnings-1" href="#Suppressing-warnings">6.4 Suppressing warnings</a></li>
    <li><a id="toc-mktex-scripts-1" href="#mktex-scripts">6.5 <samp>mktex</samp> scripts</a>
    <ul class="no-bullet">
      <li><a id="toc-mktex-configuration-1" href="#mktex-configuration">6.5.1 <samp>mktex</samp> configuration</a></li>
      <li><a id="toc-mktex-script-names-1" href="#mktex-script-names">6.5.2 <samp>mktex</samp> script names</a></li>
      <li><a id="toc-mktex-script-arguments-1" href="#mktex-script-arguments">6.5.3 <samp>mktex</samp> script arguments</a></li>
    </ul></li>
  </ul></li>
  <li><a id="toc-Programming-1" href="#Programming">7 Programming</a>
  <ul class="no-bullet">
    <li><a id="toc-Programming-overview-1" href="#Programming-overview">7.1 Programming overview</a></li>
    <li><a id="toc-Calling-sequence-1" href="#Calling-sequence">7.2 Calling sequence</a></li>
    <li><a id="toc-Program_002dspecific-files-1" href="#Program_002dspecific-files">7.3 Program-specific files</a></li>
    <li><a id="toc-Programming-with-config-files-1" href="#Programming-with-config-files">7.4 Programming with config files</a></li>
  </ul></li>
  <li><a id="toc-Reporting-bugs-1" href="#Reporting-bugs">8 Reporting bugs</a>
  <ul class="no-bullet">
    <li><a id="toc-Bug-checklist-1" href="#Bug-checklist">8.1 Bug checklist</a></li>
    <li><a id="toc-Mailing-lists-1" href="#Mailing-lists">8.2 Mailing lists</a></li>
    <li><a id="toc-Debugging-1" href="#Debugging">8.3 Debugging</a></li>
    <li><a id="toc-Logging-1" href="#Logging">8.4 Logging</a></li>
    <li><a id="toc-Common-problems-1" href="#Common-problems">8.5 Common problems</a>
    <ul class="no-bullet">
      <li><a id="toc-Unable-to-find-files-1" href="#Unable-to-find-files">8.5.1 Unable to find files</a></li>
      <li><a id="toc-Slow-path-searching-1" href="#Slow-path-searching">8.5.2 Slow path searching</a></li>
      <li><a id="toc-Unable-to-generate-fonts-1" href="#Unable-to-generate-fonts">8.5.3 Unable to generate fonts</a></li>
      <li><a id="toc-TeX-or-Metafont-failing-1" href="#TeX-or-Metafont-failing">8.5.4 TeX or Metafont failing</a></li>
    </ul></li>
  </ul></li>
  <li><a id="toc-Index-1" href="#Index" rel="index">Index</a></li>
</ul>
</div>



<span id="Top"></span><div class="header">
<p>
Next: <a href="#Introduction" accesskey="n" rel="next">Introduction</a>, Up: <a href="http://tug.org/texinfohtml" accesskey="u" rel="up">(dir)</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Kpathsea-library"></span><h1 class="top">Kpathsea library</h1>

<p>This manual documents the Kpathsea library for path searching.  It
corresponds to version 6.3.3, released in
February 2021.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Introduction" accesskey="1">Introduction</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Overview and history.
</td></tr>
<tr><th colspan="3" align="left" valign="top"><pre class="menu-comment">

</pre></th></tr><tr><td align="left" valign="top">&bull; <a href="#unixtex_002eftp" accesskey="2">unixtex.ftp</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Obtaining TeX software.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Security" accesskey="3">Security</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Who can write what files, etc.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#TeX-directory-structure" accesskey="4">TeX directory structure</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Managing the horde of TeX input files.
</td></tr>
<tr><th colspan="3" align="left" valign="top"><pre class="menu-comment">

</pre></th></tr><tr><td align="left" valign="top">&bull; <a href="#Path-searching" accesskey="5">Path searching</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">How filename lookups work.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#TeX-support" accesskey="6">TeX support</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Special support for TeX-related file lookups.
</td></tr>
<tr><th colspan="3" align="left" valign="top"><pre class="menu-comment">

</pre></th></tr><tr><td align="left" valign="top">&bull; <a href="#Programming" accesskey="7">Programming</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">How to use Kpathsea features in your program.
</td></tr>
<tr><th colspan="3" align="left" valign="top"><pre class="menu-comment">

</pre></th></tr><tr><td align="left" valign="top">&bull; <a href="#Reporting-bugs" accesskey="8">Reporting bugs</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Where and how to report bugs.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Index" rel="index" accesskey="9">Index</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">General index.
</td></tr>
</table>


<hr>
<span id="Introduction"></span><div class="header">
<p>
Next: <a href="#unixtex_002eftp" accesskey="n" rel="next">unixtex.ftp</a>, Previous: <a href="#Top" accesskey="p" rel="prev">Top</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Introduction-1"></span><h2 class="chapter">1 Introduction</h2>

<span id="index-introduction"></span>
<span id="index-fundamental-purpose-of-Kpathsea"></span>

<p>This manual corresponds to version 6.3.3 of the Kpathsea
library, released in February 2021.
</p>
<p>The library&rsquo;s fundamental purpose is to return a filename from a list of
directories specified by the user, similar to what shells do when
looking up program names to execute.
</p>
<span id="index-programs-using-the-library"></span>
<p>The following software, all of which is maintained in parallel, uses
this library:
</p>
<ul>
<li> Dviljk (see the &lsquo;<samp>dvilj</samp>&rsquo; man page)
</li><li> Dvipsk (see <cite><a href="https://tug.org/texinfohtml/dvips.html#Top">Dvips: A DVI driver</a></cite>)
</li><li> GNU font utilities (see <cite><a href="fontu.html#Top">GNU font utilities</a></cite>)
</li><li> Web2c (see <cite><a href="https://tug.org/texinfohtml/web2c.html#Top">Web2c: A TeX implementation</a></cite>)
</li><li> Xdvik (see the &lsquo;<samp>xdvi</samp>&rsquo; man page)
</li></ul>

<p>Other software that we do not maintain also uses it.
</p>
<p>Kpathsea is now maintained as part of the TeX Live distribution
(<a href="https://tug.org/texlive">https://tug.org/texlive</a>), which includes several more
Kpathsea-using programs.  For information on configuration, building,
installing, and more, see <cite><a href="https://tug.org/texinfohtml/tlbuild.html#Top">Building TeX Live</a></cite>.
</p>
<span id="index-interface_002c-not-frozen"></span>
<span id="index-comments_002c-making"></span>
<span id="index-suggestions_002c-making"></span>
<p>The library is still actively maintained.  If you have comments or
suggestions, please send along (see <a href="#Reporting-bugs">Reporting bugs</a>).
</p>
<span id="index-conditions-for-use"></span>
<span id="index-license-for-using-the-library"></span>
<span id="index-GNU-General-Public-License"></span>
<p>The Kpathsea library is distributed under the GNU Library General
Public License (LGPL), version&nbsp;2.1 or (at your option) any later
version.  In short, this means if you write a program using the
library, you must (offer to) distribute the source to the library,
along with any changes you have made, and allow anyone to modify the
library source and distribute their modifications.  It does not mean
you have to distribute the source to your program using the library,
although we hope you will.  See accompanying files for the text of the
GNU licenses, or <a href="https://gnu.org/licenses">https://gnu.org/licenses</a>.
</p>
<span id="index-TeX-Users-Group"></span>
<p>If you know enough about TeX to be reading this manual, then you (or
your institution) should consider joining the TeX Users Group (if
you&rsquo;re already a member, thanks!).  TUG produces the periodical
<cite>TUGboat</cite>, sponsors an annual meeting and publishes the
proceedings, and arranges courses on TeX for all levels of users
throughout the world.  See <a href="https://tug.org">https://tug.org</a> for information.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#History" accesskey="1">History</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
</table>


<hr>
<span id="History"></span><div class="header">
<p>
Up: <a href="#Introduction" accesskey="u" rel="up">Introduction</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="History-1"></span><h3 class="section">1.1 History</h3>

<span id="index-history-of-Kpathsea"></span>

<span id="index-Knuth_002c-Donald-E_002e"></span>
<p>This section is for those people who are curious about how the library
came about.  If you like to read historical accounts of software, we
urge you to seek out the GNU Autoconf manual and the &ldquo;Errors of
TeX&rdquo; paper by Don Knuth, published in his book <cite>Digital
Typography</cite>, among other places.
</p>
<span id="index-Morgan_002c-Tim"></span>
<span id="index-Rokicki_002c-Tom"></span>
<span id="index-Berry_002c-Karl"></span>
<span id="index-VAX-11_002f750"></span>
<span id="index-Sun-2"></span>
<span id="index-pxp-Pascal-preprocessor"></span>
<span id="index-pc-Pascal-compiler"></span>
<p>[Karl writes.]  My first ChangeLog entry for Web2c seems to be
February 1990, but I may have done some work before then.  In any
case, Tim Morgan and I were jointly maintaining it for a time.  (I
should mention here that Tim had made Web2c into a real distribution
long before I had ever used it or even heard of it, and Tom Rokicki
did the original implementation.  When I started, I was using
<code>pxp</code> and <code>pc</code> on VAX 11/750&rsquo;s and the hot new Sun 2
machines.)
</p>
<p>It must have been later in 1990 and 1991 that I started working on
<cite>TeX for the Impatient</cite>. Dvips, Xdvi, Web2c, and the GNU
fontutils (which I was also writing at the time) all used different
environment variables, and, more importantly, had different bugs in
their path searching. This became extremely painful, as I was stressing
everything to the limit working on the book.  I also desperately wanted
to implement subdirectory searching, since I couldn&rsquo;t stand putting
everything in one big directory, and also couldn&rsquo;t stand having to
explicitly specify <samp>cm</samp>, <samp>pandora</samp>, &hellip; in a path.
</p>
<span id="index-Vojta_002c-Paul"></span>
<p>In the first incarnation, I just hacked separately on each
program&mdash;that was the original subdirectory searching code in both
Xdvi and Dvips.  That is, I tried to go with the flow in each program,
rather than changing the program&rsquo;s calling sequences to conform to new
routines.
</p>
<p>Then, as bugs inevitably appeared, I found I was fixing the same thing
three times (Web2c and fontutils were already sharing code, since I
maintained both of those&mdash;there was no Dvipsk or Xdvik or Dviljk at
this point).  After a while, I finally started sharing source files.
They weren&rsquo;t yet a library, though.  I just kept things up to date
with shell scripts.  (I was developing on a 386 running ISC 2.2 at the
time, and so didn&rsquo;t have symbolic links.  An awful experience.)
</p>
<span id="index-MacKenzie_002c-David"></span>
<p>The ChangeLogs for Xdvik and Dvipsk record initial releases of those
distributions in May and June 1992.  I think it was because I was tired
of the different configuration strategies of each program, not so much
because of the path searching.  Autoconf was being developed by David
MacKenzie and others, and I was adapting it to TeX and friends.
</p>
<span id="index-zuhn_002c-david"></span>
<p>I started to make a separate library that other programs could link with
on my birthday in April 1993, according to the ChangeLog.  I don&rsquo;t
remember exactly why I finally took the time to make it a separate
library; a conversation with david zuhn initiated it.  Just seemed
like it was time.
</p>
<span id="index-Walsh_002c-Norman"></span>
<span id="index-Neumann_002c-Gustaf"></span>
<p>Dviljk got started in March 1994 after I bought a Laserjet 4.  (Kpathsea
work got suspended while Norm Walsh and I, with Gustaf Neumann&rsquo;s help,
implemented a way for TeX to get at all those neat builtin LJ4 fonts
&hellip; such a treat to have something to typeset in besides Palatino!)
</p>
<p>By spring of 1995, I had implemented just about all the path-searching
features in Kpathsea that I plan to, driven beyond my initial goals by
Thomas Esser and others.  I then started to integrate Web2c with
Kpathsea. After the release of a stable Web2c, I hope to be able to stop
development, and turn most of my attention back to making fonts for GNU.
(Always assuming Micros**t hasn&rsquo;t completely obliterated Unix by then,
or that software patents haven&rsquo;t stopped software development by anybody
smaller than a company with a million-dollar-a-year legal budget.  Which
is actually what I think is likely to happen, but that&rsquo;s another
story&hellip;)
</p>
<span id="index-Weber_002c-Olaf"></span>
<p>[Olaf writes.]  At the end of 1997, Unix is still alive and kicking,
individuals still develop software, and Web2c development still
continues.  Karl had been looking for some time for someone to take up
part of the burden, and I volunteered.
</p>
<span id="index-Hoekwater_002c-Taco"></span>
<span id="index-Breitenlohner_002c-Peter"></span>
<p>[Karl writes again.]  Indeed, time goes on.  As of 2006 or so, Olaf&rsquo;s
available time for Kpathsea was reduced, and I started taking overall
care of it again, although I did not do any significant new
development.  In 2009, Taco Hoekwater implemented a major
rearrangement to make the library suitable for use within the MetaPost
library (see <a href="#Programming-overview">Programming overview</a>).  Also, for some years now,
Peter Breitenlohner has made many improvements to the infrastructure
and kept it up-to-date with respect to the overall TeX Live build,
where Kpathsea is now maintained.
</p>


<hr>
<span id="unixtex_002eftp"></span><div class="header">
<p>
Next: <a href="#Security" accesskey="n" rel="next">Security</a>, Previous: <a href="#Introduction" accesskey="p" rel="prev">Introduction</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="unixtex_002eftp_003a-Obtaining-TeX"></span><h2 class="chapter">2 <samp>unixtex.ftp</samp>: Obtaining TeX</h2>

<span id="index-obtaining-TeX"></span>
<span id="index-retrieving-TeX"></span>

<span id="index-unixtex_002eftp"></span>
<span id="index-tug_002eorg"></span>
<span id="index-www_002etug_002eorg"></span>
<span id="index-ftp_002etug_002eorg"></span>
<p>This
is <a href="ftp://tug.org/tex/unixtex.ftp">ftp://tug.org/tex/unixtex.ftp</a>, a.k.a.
<a href="https://tug.org/unixtex.ftp">https://tug.org/unixtex.ftp</a>, last updated 29 February 2020.
Email <a href="mailto:tex-k@tug.org">tex-k@tug.org</a> with comments or questions.
</p>
<p>The principal free TeX distribution for Unix-like systems is TeX
Live, on the web at <a href="http://tug.org/texlive">http://tug.org/texlive</a>.  The pages there
describe many ways to acquire and/or build TeX, over the Internet
or on physical media, both the sources and precompiled binaries for
many systems, either standalone or as part of various operating system
distributions.
</p>
<p>Web2c, Kpathsea, Dvips, and Dviljk, among others, are no longer
released as a separate packages.  Their sources are now maintained as
part of TeX Live.
</p>
<span id="index-ftp_002ecs_002estanford_002eedu"></span>
<span id="index-tex_002eweb"></span>
<span id="index-Knuth_002c-Donald-E_002e_002c-archive-of-programs-by"></span>
<p>The host <tt>ftp.cs.stanford.edu</tt> is the original source for the files
for which Donald Knuth is directly responsible: <samp>tex.web</samp>,
<samp>plain.tex</samp>, etc. However, unless you want to undertake the
project of building your TeX system from scratch, it is more
reliable and less work to retrieve these files as part of a larger
package.
</p>
<p>In any case, the Stanford ftp site is not the canonical source for
anything except what was created as part of Knuth&rsquo;s original TeX,
so do not rely on any other files available there being up-to-date.
The best place to check for up-to-date files is CTAN (the
Comprehensive TeX Archive Network), <a href="https://ctan.org">https://ctan.org</a>.
</p>


<hr>
<span id="Security"></span><div class="header">
<p>
Next: <a href="#TeX-directory-structure" accesskey="n" rel="next">TeX directory structure</a>, Previous: <a href="#unixtex_002eftp" accesskey="p" rel="prev">unixtex.ftp</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Security-1"></span><h2 class="chapter">3 Security</h2>

<span id="index-security-considerations"></span>

<p>None of the programs in the TeX system require any special system
privileges, so there&rsquo;s no first-level security concern of people gaining
illegitimate root access.
</p>
<span id="index-trojan-horse-attack"></span>
<span id="index-_002erhosts_002c-writable-by-TeX"></span>
<p>A TeX document, however, can write to arbitrary files, e.g.,
<samp>~/.rhosts</samp>, and thus an unwitting user who runs TeX on a random
document is vulnerable to a trojan horse attack.  This loophole is
closed by default, but you can be permissive if you so desire in
<samp>texmf.cnf</samp>.  See <a href="https://tug.org/texinfohtml/web2c.html#tex-invocation">tex invocation</a> in <cite>Web2c</cite>.  MetaPost has
the same issue.
</p>
<p>Dvips, Xdvi, and TeX can also execute shell commands under some
circumstances.  To disable this, see the &lsquo;<samp>-R</samp>&rsquo; option in <a href="https://tug.org/texinfohtml/dvips.html#Option-details">Option
details</a> in <cite>Dvips</cite>, the xdvi man page, and <a href="https://tug.org/texinfohtml/web2c.html#tex-invocation">tex
invocation</a> in <cite>Web2c</cite>, respectively.
</p>
<span id="index-local-cache-of-fonts"></span>
<span id="index-cache-of-fonts_002c-local"></span>
<p>Another security issue arises because it&rsquo;s very useful&mdash;almost
necessary&mdash;to make arbitrary fonts on user demand with <code>mktexpk</code>
and friends.  Where do these files get installed?  By default, the
<code>mktexpk</code> distributed with Kpathsea assumes a world-writable
<samp>/var/tmp</samp> directory; this is a simple and convenient approach, but
it may not suit your situation because it means that a local cache of
fonts is created on every machine.
</p>
<span id="index-globally-writable-directories"></span>
<p>To avoid this duplication, many people consider a shared, globally
writable font tree desirable, in spite of the potential security
problems.  To do this you should change the value of <code>VARTEXFONTS</code>
in <samp>texmf.cnf</samp> to refer to some globally known directory.
See <a href="#mktex-configuration">mktex configuration</a>.
</p>
<span id="index-append_002donly-directories-and-mktexpk"></span>
<p>The first restriction you can apply is to make newly-created directories
under <samp>texmf</samp> be append-only with an option in <samp>mktex.cnf</samp>.
See <a href="#mktex-configuration">mktex configuration</a>.
</p>
<span id="index-group_002dwritable-directories"></span>
<span id="index-setgid-scripts"></span>
<p>Another approach is to establish a group (or user) for TeX files,
make the <samp>texmf</samp> tree writable only to that group (or user), and
make <code>mktexpk</code> et al. setgid to that group (or setuid to that
user).  Then users must invoke the scripts to install things.  (If
you&rsquo;re worried about the inevitable security holes in scripts, then you
could write a C wrapper to exec the script.)
</p>
<span id="index-file-permissions"></span>
<span id="index-permissions_002c-file"></span>
<p>The <samp>mktex&hellip;</samp> scripts install files with the same read and
write permissions as the directory they are installed in.  The
executable, sgid, suid, and sticky bits are always cleared.
</p>
<span id="index-directory-permissions"></span>
<span id="index-permissions_002c-directory"></span>
<p>Any directories created by the <samp>mktex&hellip;</samp> scripts have the
same permissions as their parent directory, unless the
<code>appendonlydir</code> feature is used, in which case the sticky bit is
always set.
</p>

<hr>
<span id="TeX-directory-structure"></span><div class="header">
<p>
Next: <a href="#Path-searching" accesskey="n" rel="next">Path searching</a>, Previous: <a href="#Security" accesskey="p" rel="prev">Security</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="TeX-directory-structure-1"></span><h2 class="chapter">4 TeX directory structure</h2>

<span id="index-TEXMF"></span>
<span id="index-TeX-directory-structure"></span>
<span id="index-directory-structure_002c-for-TeX-files"></span>
<span id="index-skeleton-TeX-directory"></span>
<span id="index-TDS"></span>

<p>This section describes the default installation hierarchy of the
distribution.  It conforms to both the GNU coding standards and the
TeX directory structure (TDS) standard.  For rationale and further
explanation, please see those documents.  The GNU document is
available from <a href="https://gnu.org/prep/standards">https://gnu.org/prep/standards</a>.  The TDS
document is available from <a href="http://mirror.ctan.org/tds">http://mirror.ctan.org/tds</a>
(see <a href="#unixtex_002eftp">unixtex.ftp</a>).
</p>
<p>In short, here is a skeleton of the default directory structure,
extracted from the TDS document:
</p>
<div class="example">
<pre class="example"><var>prefix</var>/      <span class="roman">installation root (<samp>/usr/local</samp> by default)</span>
 bin/         <span class="roman">executables</span>
 man/         <span class="roman">man pages</span>
 include/     <span class="roman">C header files</span>
 info/        <span class="roman">GNU info files</span>
 lib/         <span class="roman">libraries (<samp>libkpathsea.*</samp>)</span>
 share/       <span class="roman">architecture-independent files</span>
  texmf/      <span class="roman">TDS root</span>
   bibtex/     <span class="roman">BibTeX input files</span>
    bib/        <span class="roman">BibTeX databases</span>
     base/       <span class="roman">base distribution (e.g., &lsquo;<samp>xampl.bib</samp>&rsquo;)</span>
     misc/       <span class="roman">single-file databases</span>
     <var>pkg</var>/       <span class="roman">name of a package</span>
    bst/        <span class="roman">BibTeX style files</span>
     base/       <span class="roman">base distribution (e.g., &lsquo;<samp>plain.bst</samp>&rsquo;, &lsquo;<samp>acm.bst</samp>&rsquo;)</span>
     misc/       <span class="roman">single-file styles</span>
     <var>pkg</var>/       <span class="roman">name of a package</span>
   doc/         <span class="roman">additional documentation</span>
   dvips/       <span class="roman">&lsquo;<samp>.pro</samp>&rsquo;, &lsquo;<samp>.ps</samp>&rsquo;, &lsquo;<samp>psfonts.map</samp>&rsquo;</span>
   fonts/       <span class="roman">font-related files</span>
    <var>type</var>/         <span class="roman">file type (e.g., &lsquo;<samp>tfm</samp>&rsquo;, &lsquo;<samp>pk</samp>&rsquo;)</span>
     <var>mode</var>/          <span class="roman">type of output device (types &lsquo;<samp>pk</samp>&rsquo; and &lsquo;<samp>gf</samp>&rsquo; only)</span>
      <var>supplier</var>/       <span class="roman">name of a font supplier (e.g., &lsquo;<samp>public</samp>&rsquo;)</span>
       <var>typeface</var>/        <span class="roman">name of a typeface (e.g., &lsquo;<samp>cm</samp>&rsquo;)</span>
        dpi<var>nnn</var>/           <span class="roman">font resolution (types &lsquo;<samp>pk</samp>&rsquo; and &lsquo;<samp>gf</samp>&rsquo; only)</span>
   metafont/    <span class="roman">Metafont (non-font) input files</span>
    base/        <span class="roman">base distribution (e.g., &lsquo;<samp>plain.mf</samp>&rsquo;)</span>
    misc/        <span class="roman">single-file packages (e.g., &lsquo;<samp>modes.mf</samp>&rsquo;)</span>
    <var>pkg</var>/           <span class="roman">name of a package (e.g., &lsquo;<samp>mfpic</samp>&rsquo;)</span>
   metapost/    <span class="roman">MetaPost input files</span>
    base/        <span class="roman">base distribution (e.g., &lsquo;<samp>plain.mp</samp>&rsquo;)</span>
    misc/        <span class="roman">single-file packages</span>
    <var>pkg</var>/           <span class="roman">name of a package</span>
    support/     <span class="roman">support files for MetaPost-related utilities (e.g., &lsquo;<samp>trfonts.map</samp>&rsquo;)</span>
   mft/         <span class="roman">&lsquo;<samp>MFT</samp>&rsquo; inputs (e.g., &lsquo;<samp>plain.mft</samp>&rsquo;)</span>
   tex/         <span class="roman">TeX input files</span>
    <var>format</var>/         <span class="roman">name of a format (e.g., &lsquo;<samp>plain</samp>&rsquo;)</span>
     base/        <span class="roman">base distribution for <var>format</var> (e.g., &lsquo;<samp>plain.tex</samp>&rsquo;)</span>
     misc/        <span class="roman">single-file packages (e.g., &lsquo;<samp>webmac.tex</samp>&rsquo;)</span>
     local/       <span class="roman">local additions to or local configuration files for <var>format</var></span>
     <var>pkg</var>/           <span class="roman">name of a package (e.g., &lsquo;<samp>graphics</samp>&rsquo;, &lsquo;<samp>mfnfss</samp>&rsquo;)</span>
    generic/     <span class="roman">format-independent packages</span>
     hyphen/      <span class="roman">hyphenation patterns (e.g., &lsquo;<samp>hyphen.tex</samp>&rsquo;)</span>
     images/      <span class="roman">image input files (e.g., Encapsulated PostScript)</span>
     misc/        <span class="roman">single-file format-independent packages (e.g., &lsquo;<samp>null.tex</samp>&rsquo;).</span>
     <var>pkg</var>/           <span class="roman">name of a package (e.g., &lsquo;<samp>babel</samp>&rsquo;)</span>
   web2c/        <span class="roman">implementation-dependent files (<samp>.pool</samp>, <samp>.fmt</samp>, <samp>texmf.cnf</samp>, etc.)</span>
</pre></div>

<p>Some concrete examples for most file types:
</p>
<div class="example">
<pre class="example">/usr/local/bin/tex
/usr/local/man/man1/xdvi.1
/usr/local/info/kpathsea.info
/usr/local/lib/libkpathsea.a
/usr/local/share/texmf/bibtex/bst/base/plain.bst
/usr/local/share/texmf/fonts/pk/ljfour/public/cm/cmr10.600pk
/usr/local/share/texmf/fonts/source/public/pandora/pnr10.mf
/usr/local/share/texmf/fonts/tfm/public/cm/cmr10.tfm
/usr/local/share/texmf/fonts/type1/adobe/utopia/putr.pfa
/usr/local/share/texmf/metafont/base/plain.mf
/usr/local/share/texmf/metapost/base/plain.mp
/usr/local/share/texmf/tex/plain/base/plain.tex
/usr/local/share/texmf/tex/generic/hyphen/hyphen.tex
/usr/local/share/texmf/web2c/tex.pool
/usr/local/share/texmf/web2c/tex.fmt
/usr/local/share/texmf/web2c/texmf.cnf
</pre></div>


<hr>
<span id="Path-searching"></span><div class="header">
<p>
Next: <a href="#TeX-support" accesskey="n" rel="next">TeX support</a>, Previous: <a href="#TeX-directory-structure" accesskey="p" rel="prev">TeX directory structure</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Path-searching-1"></span><h2 class="chapter">5 Path searching</h2>

<span id="index-path-searching"></span>

<p>This chapter describes the generic path searching mechanism Kpathsea
provides.  For information about searching for particular file types
(e.g., TeX fonts), see the next chapter.
</p>
<span id="index-translations_002c-of-path-searching-description"></span>
<p>This section, with minor differences, has been translated into several
other languages (Chinese, Spanish, Russian, Japanese, French, German,
&hellip;) as part of the TeX Live guide; see
<a href="https://tug.org/texlive/doc.html">https://tug.org/texlive/doc.html</a> for links.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Searching-overview" accesskey="1">Searching overview</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Basic scheme for searching.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Path-sources" accesskey="2">Path sources</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Where search paths can be defined.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Path-expansion" accesskey="3">Path expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Special constructs in search paths.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Casefolding-search" accesskey="4">Casefolding search</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Fallback to case-insensitive search.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Filename-database" accesskey="5">Filename database</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Using an externally-built list to search.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Invoking-kpsewhich" accesskey="6">Invoking kpsewhich</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Standalone path lookup.
</td></tr>
</table>


<hr>
<span id="Searching-overview"></span><div class="header">
<p>
Next: <a href="#Path-sources" accesskey="n" rel="next">Path sources</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Searching-overview-1"></span><h3 class="section">5.1 Searching overview</h3>

<span id="index-searching-overview"></span>
<span id="index-path-searching_002c-overview"></span>
<span id="index-overview-of-path-searching"></span>

<span id="index-search-path_002c-defined"></span>
<p>A <em>search path</em> is a colon-separated list of <em>path elements</em>,
which are directory names with a few extra frills.  A search path can
come from (a combination of) many sources; see below.  To look up a file
&lsquo;<samp>foo</samp>&rsquo; along a path &lsquo;<samp>.:/dir</samp>&rsquo;, Kpathsea checks each element of
the path in turn: first <samp>./foo</samp>, then <samp>/dir/foo</samp>, returning
the first match (or possibly all matches).
</p>
<span id="index-magic-characters"></span>
<span id="index-_003a-may-not-be-_003a"></span>
<span id="index-_002f-may-not-be-_002f"></span>
<p>The &ldquo;colon&rdquo; and &ldquo;slash&rdquo; mentioned here aren&rsquo;t necessarily &lsquo;<samp>:</samp>&rsquo;
and &lsquo;<samp>/</samp>&rsquo; on non-Unix systems.  Kpathsea tries to adapt to other
operating systems&rsquo; conventions.
</p>
<span id="index-database-search"></span>
<span id="index-searching-the-database"></span>
<p>To check a particular path element <var>e</var>, Kpathsea first sees if a
prebuilt database (see <a href="#Filename-database">Filename database</a>) applies to <var>e</var>, i.e.,
if the database is in a directory that is a prefix of <var>e</var>.  If so,
the path specification is matched against the contents of the database.
</p>
<span id="index-floating-directories"></span>
<span id="index-filesystem-search"></span>
<span id="index-disk-search"></span>
<span id="index-searching-the-disk"></span>
<p>If the database does not exist, or does not apply to this path element,
or contains no matches, the filesystem is searched (if this was not
forbidden by the specification with &lsquo;<samp>!!</samp>&rsquo; and if the file being
searched for must exist).  Kpathsea constructs the list of directories
that correspond to this path element, and then checks in each for the
file being searched for.  (To help speed future lookups of files in the
same directory, the directory in which a file is found is floated to the
top of the directory list.)
</p>
<span id="index-must-exist"></span>
<span id="index-VF-files_002c-not-found"></span>
<span id="index-cmr10_002evf"></span>
<span id="index-_005copenin"></span>
<p>The &ldquo;file must exist&rdquo; condition comes into play with VF files and
input files read by the TeX &lsquo;<samp>\openin</samp>&rsquo; command.  These files
might very well not exist (consider <samp>cmr10.vf</samp>), and so it would
be wrong to search the disk for them.  Therefore, if you fail to
update <samp>ls-R</samp> when you install a new VF file, it will not be
found.
</p>
<p>Each path element is checked in turn: first the database, then the
disk.  If a match is found, the search stops and the result is
returned (unless the search explicitly requested all matches).  This
avoids possibly-expensive processing of path specifications that are
never needed on a particular run.
</p>
<p>On Unix-like systems, if no match is found by any of the above, and
the path element allows checking the filesystem (per the above), a
final check is made for a case-insensitive match. Thus, looking for a
name like &lsquo;<samp>./FooBar.TeX</samp>&rsquo; will match a file &lsquo;<samp>./foobar.tex</samp>&rsquo;,
and vice versa.  This is not done on Windows.  See <a href="#Casefolding-search">Casefolding search</a>.
</p>
<span id="index-expansion_002c-path-element"></span>
<p>Although the simplest and most common path element is a directory name,
Kpathsea supports additional features in search paths: layered default
values, environment variable names, config file values, users&rsquo; home
directories, and recursive subdirectory searching.  Thus, we say that
Kpathsea <em>expands</em> a path element, meaning transforming all the
magic specifications into the basic directory name or names.  This
process is described in the sections below.  It happens in the same
order as the sections.
</p>
<span id="index-absolute-filenames"></span>
<span id="index-relative-filenames"></span>
<span id="index-explicitly-relative-filenames"></span>
<span id="index-filenames_002c-absolute-or-explicitly-relative"></span>
<p>Exception to all of the above: If the filename being searched for is
absolute or explicitly relative, i.e., starts with &lsquo;<samp>/</samp>&rsquo; or &lsquo;<samp>./</samp>&rsquo;
or &lsquo;<samp>../</samp>&rsquo;, Kpathsea simply checks if that file exists, with a
fallback to a casefolding match if needed and enabled, as described above.
</p>
<span id="index-permission-denied"></span>
<span id="index-unreadable-files"></span>
<span id="index-access-warnings"></span>
<span id="index-warnings_002c-file-access"></span>
<span id="index-lost_002bfound-directory"></span>
<span id="index-TEX_005fHUSH"></span>
<p>Ordinarily, if Kpathsea tries to access a file or directory that
cannot be read, it gives a warning.  This is so you will be alerted to
directories or files that accidentally lack any read permission (for
example, a <samp>lost+found</samp> directory).  If you prefer not to see
these warnings, include the value &lsquo;<samp>readable</samp>&rsquo; in the
<code>TEX_HUSH</code> environment variable or config file value.
</p>
<p>This generic path searching algorithm is implemented in
<samp>kpathsea/pathsearch.c</samp>.  It is employed by a higher-level
algorithm when searching for a file of a particular type (see <a href="#File-lookup">File lookup</a>, and <a href="#Glyph-lookup">Glyph lookup</a>).
</p>

<hr>
<span id="Path-sources"></span><div class="header">
<p>
Next: <a href="#Path-expansion" accesskey="n" rel="next">Path expansion</a>, Previous: <a href="#Searching-overview" accesskey="p" rel="prev">Searching overview</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Path-sources-1"></span><h3 class="section">5.2 Path sources</h3>

<span id="index-path-sources"></span>
<span id="index-sources-for-search-paths"></span>

<p>A search path or other configuration value can come from many sources.
In the order in which Kpathsea looks for them:
</p>
<ol>
<li> <span id="index-_002d_002dcnf_002dline_002c-source-for-path"></span>
A command-line option such as <code>--cnf-line</code>, available in
<samp>kpsewhich</samp> and most TeX engines.  See <a href="#Path-searching-options">Path searching options</a>. 

<span id="index-environment-variable_002c-source-for-path"></span>
<p>A user-set environment variable, e.g., <code>TEXINPUTS</code>.
Environment variables with an underscore and the program name appended
override; for example, <code>TEXINPUTS_latex</code> overrides <code>TEXINPUTS</code>
if the program being run is named &lsquo;<samp>latex</samp>&rsquo;.
</p>
</li><li> A program-specific configuration file, e.g., an &lsquo;<samp>S /a:/b</samp>&rsquo; line in
Dvips&rsquo; <samp>config.ps</samp> (see <a href="https://tug.org/texinfohtml/dvips.html#Config-files">Config files</a> in <cite>Dvips</cite>).

</li><li> <span id="index-configuration-file_002c-source-for-path"></span>
<span id="index-Kpathsea-config-file_002c-source-for-path"></span>
<span id="index-texmf_002ecnf_002c-source-for-path"></span>
A line in a Kpathsea configuration file <samp>texmf.cnf</samp>, e.g.,
&lsquo;<samp>TEXINPUTS=/c:/d</samp>&rsquo; (see below).

</li><li> <span id="index-compilation-value_002c-source-for-path"></span>
The compile-time default (specified in <samp>kpathsea/paths.h</samp>).
</li></ol>

<p>You can see each of these values for a given search path by using the
debugging options (see <a href="#Debugging">Debugging</a>).
</p>
<p>These sources may be combined via default expansion (see <a href="#Default-expansion">Default expansion</a>).
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Config-files" accesskey="1">Config files</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Kpathsea&rsquo;s runtime config files (texmf.cnf).
</td></tr>
</table>


<hr>
<span id="Config-files"></span><div class="header">
<p>
Up: <a href="#Path-sources" accesskey="u" rel="up">Path sources</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Config-files-1"></span><h4 class="subsection">5.2.1 Config files</h4>

<span id="index-config-files"></span>
<span id="index-texmf_002ecnf_002c-definition-for"></span>

<span id="index-runtime-configuration-files"></span>
<span id="index-TEXMFCNF"></span>
<p>As mentioned above, Kpathsea reads <em>runtime configuration files</em>
named <samp>texmf.cnf</samp> for search path and other definitions.  The
search path used to look for these configuration files is named
<code>TEXMFCNF</code>, and is constructed in the usual way, as described
above, except that configuration files cannot be used to define the
path, naturally; also, an <samp>ls-R</samp> database is not used to search for
them.
</p>
<p>Kpathsea reads <em>all</em> <samp>texmf.cnf</samp> files in the search path, not
just the first one found; definitions in earlier files override those in
later files.  Thus, if the search path is &lsquo;<samp>.:$TEXMF</samp>&rsquo;, values from
<samp>./texmf.cnf</samp> override those from <samp>$TEXMF/texmf.cnf</samp>.
</p>
<span id="index-KPATHSEA_005fWARNING"></span>
<span id="index-warning_002c-about-missing-texmf_002ecnf"></span>
<span id="index-texmf_002ecnf-missing_002c-warning-about"></span>
<p>If Kpathsea cannot find any <samp>texmf.cnf</samp> file, it reports a
warning including all the directories it checked.  If you don&rsquo;t want
to see this warning, set the environment variable
<code>KPATHSEA_WARNING</code> to the single character &lsquo;<samp>0</samp>&rsquo; (zero, not
oh).
</p>
<p>While (or instead of) reading this description, you may find it helpful
to look at the distributed <samp>texmf.cnf</samp>, which uses or at least
mentions most features.  The format of <samp>texmf.cnf</samp> files follows:
</p>
<ul>
<li> <span id="index-comments_002c-in-texmf_002ecnf"></span>
Comments start with &lsquo;<samp>%</samp>&rsquo;, either at the beginning of a line or
preceded by whitespace, and continue to the end of the line.  That is,
similar to most shells, a &lsquo;<samp>%</samp>&rsquo; in the &ldquo;middle&rdquo; of a value does not
start a comment.  Examples:

<div class="example">
<pre class="example">% this is a comment
var = a%b  % but the value of var will be &quot;a%b&quot;
</pre></div>

</li><li> <span id="index-blank-lines_002c-in-texmf_002ecnf"></span>
Blank lines are ignored.

</li><li> <span id="index-backslash_002dnewline"></span>
<span id="index-continuation-character"></span>
<span id="index-whitespace_002c-not-ignored-on-continuation-lines"></span>
<span id="index-_005c_002c-line-continuation-in-texmf_002ecnf"></span>
A &lsquo;<samp>\</samp>&rsquo; at the end of a line acts as a continuation character, i.e.,
the next line is appended.  Whitespace at the beginning of continuation
lines is not ignored.

</li><li> Each remaining line will look like:

<div class="example">
<pre class="example"><var>variable</var> <span class="roman">[</span>. <var>progname</var><span class="roman">]</span> <span class="roman">[</span>=<span class="roman">]</span> <var>value</var>
</pre></div>

<p>where the &lsquo;<samp>=</samp>&rsquo; and surrounding whitespace is optional.
</p>
</li><li> <span id="index-identifiers_002c-characters-valid-in"></span>
The <var>variable</var> name may contain any character other than whitespace,
&lsquo;<samp>=</samp>&rsquo;, or &lsquo;<samp>.</samp>&rsquo;, but sticking to &lsquo;<samp>A-Za-z_</samp>&rsquo; is safest.

</li><li> <span id="index-_002eprogname-qualifier-in-texmf_002ecnf"></span>
If &lsquo;<samp>.<var>progname</var></samp>&rsquo; is present (preceding spaces are
ignored), the definition only applies if the program that is running
is named (i.e., the last component of <code>argv[0]</code> is)
<var>progname</var> or <samp><var>progname</var>.{exe,bat,cmd,...}</samp>.  Most
notably, this allows different flavors of TeX to have different
search paths.  The <var>progname</var> value is used literally, without
variable or other expansions.

</li><li> <span id="index-right_002dhand-side-of-variable-assignments"></span>
Considered as strings, <var>value</var> may contain any character.
However, in practice most <samp>texmf.cnf</samp> values are related to path
expansion, and since various special characters are used in expansion,
such as braces and commas, they cannot be used in directory names.
  
<p>The &lsquo;<samp>$<var>var</var>.<var>prog</var></samp>&rsquo; feature is not available on the
right-hand side; instead, you must use an additional variable (see
below for example).
</p>
<span id="index-_003b-translated-to-_003a-in-texmf_002ecnf"></span>
<p>A &lsquo;<samp>;</samp>&rsquo; in <var>value</var> is translated to &lsquo;<samp>:</samp>&rsquo; if running under
Unix, in order to have a single <samp>texmf.cnf</samp> that can support both
Unix and Windows systems. This translation happens with any value, not
just search paths, but fortunately in practice &lsquo;<samp>;</samp>&rsquo; is not needed
in other values.
</p>
</li><li> All definitions are read before anything is expanded, so you can
use variables before they are defined (like Make, unlike most other
programs).
</li></ul>

<p>Here is a configuration file fragment illustrating most of
these points:
</p>
<div class="example">
<pre class="example">% TeX input files -- i.e., anything to be found by \input or \openin ...
latex209_inputs = .:$TEXMF/tex/latex209//:$TEXMF/tex//
latex2e_inputs = .:$TEXMF/tex/latex//:$TEXMF/tex//
TEXINPUTS = .:$TEXMF/tex//
TEXINPUTS.latex209 = $latex209_inputs
TEXINPUTS.latex2e = $latex2e_inputs
TEXINPUTS.latex = $latex2e_inputs
</pre></div>

<span id="index-shell-scripts-as-configuration-files"></span>
<span id="index-configuration-files-as-shell-scripts_002e"></span>
<p>This format has some similarity to Bourne shell scripts&mdash;change the
comment character to <code>#</code>, disallow spaces around the <code>=</code>,
and get rid of the <code>.<var>name</var></code> convention, and it could be run
through the shell.  However, there seemed little advantage in this,
since all the information would have to passed back to Kpathsea and
parsed there anyway, since the <code>sh</code> process couldn&rsquo;t affect its
parent&rsquo;s environment.
</p>
<span id="index-_003d-omitted-in-texmf_002ecnf-and-misparsing"></span>
<p>The combination of spaces being ignored before the <code>.</code> of a
program name qualifer and the optional &lsquo;<samp>=</samp>&rsquo; for the assignment has
an unexpected consequence: if the value begins with a literal &lsquo;<samp>.</samp>&rsquo;
and the &lsquo;<samp>=</samp>&rsquo; is omitted, the intended value is interpreted as a
program name.  For example, a line <code>var .;/some/path</code> is taken as
an empty value for <code>var</code> running under the program named
&lsquo;<samp>;/some/path</samp>&rsquo;.  To diagnose this, Kpathsea warns if the program
name contains a path separator or other special character.  The
simplest way to avoid the problem is to use the <code>=</code>.
</p>
<p>Exactly when a character will be considered special or act as itself
depends on the context in which it is used. The rules are inherent in
the multiple levels of interpretation of the configuration (parsing,
expansion, search, &hellip;) and so cannot be concisely stated,
unfortunately. There is no general escape mechanism; in particular,
&lsquo;<samp>\</samp>&rsquo; is not an &ldquo;escape character&rdquo; in <samp>texmf.cnf</samp> files.
When it comes choosing directory names for installation, it is safest to
avoid them all.
</p>
<span id="index-cnf_002ec"></span>
<p>The implementation of all this is in <samp>kpathsea/cnf.c</samp>.
</p>

<hr>
<span id="Path-expansion"></span><div class="header">
<p>
Next: <a href="#Casefolding-search" accesskey="n" rel="next">Casefolding search</a>, Previous: <a href="#Path-sources" accesskey="p" rel="prev">Path sources</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Path-expansion-1"></span><h3 class="section">5.3 Path expansion</h3>

<span id="index-path-expansion"></span>
<span id="index-expansion_002c-search-path"></span>

<p>Kpathsea recognizes certain special characters and constructions in
search paths, similar to that in shells.  As a general example:
&lsquo;<samp>~$USER/{foo,bar}//baz</samp>&rsquo; expands to all subdirectories under
directories <samp>foo</samp> and <samp>bar</samp> in <tt>$USER</tt>&rsquo;s home directory that
contain a directory or file <samp>baz</samp>.
</p>
<p>These expansions are explained in the sections below.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Default-expansion" accesskey="1">Default expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">a: or :a or a::b expands to a default.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Variable-expansion" accesskey="2">Variable expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">$foo and ${foo} expand to environment values.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Tilde-expansion" accesskey="3">Tilde expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">~ and ~user expand to home directories.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Brace-expansion" accesskey="4">Brace expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">a{foo,bar}b expands to afoob abarb.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#KPSE_005fDOT-expansion" accesskey="5">KPSE_DOT expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">. is replaced with $KPSE_DOT if it is defined.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Subdirectory-expansion" accesskey="6">Subdirectory expansion</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">a// and a//b recursively expand to subdirs.
</td></tr>
</table>


<hr>
<span id="Default-expansion"></span><div class="header">
<p>
Next: <a href="#Variable-expansion" accesskey="n" rel="next">Variable expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Default-expansion-1"></span><h4 class="subsection">5.3.1 Default expansion</h4>

<span id="index-_003a_003a-expansion"></span>
<span id="index-doubled-colons"></span>
<span id="index-leading-colons"></span>
<span id="index-trailing-colons"></span>
<span id="index-extra-colons"></span>
<span id="index-default-expansion"></span>
<span id="index-expansion_002c-default"></span>

<p>If the highest-priority search path (see <a href="#Path-sources">Path sources</a>) contains an
<em>extra colon</em> (i.e., leading, trailing, or doubled), Kpathsea
inserts at that point the next-highest-priority search path that is
defined.  If that inserted path has an extra colon, the same happens
with the next-highest.  (An extra colon in the compile-time default
value has unpredictable results, so installers beware.)
</p>
<p>For example, given an environment variable setting
</p>
<div class="example">
<pre class="example">setenv TEXINPUTS /home/karl:
</pre></div>

<p>and a <code>TEXINPUTS</code> value from <samp>texmf.cnf</samp> of
</p>
<div class="example">
<pre class="example">.:$TEXMF//tex
</pre></div>

<p>then the final value used for searching will be:
</p>
<div class="example">
<pre class="example">/home/karl:.:$TEXMF//tex
</pre></div>

<p>Put another way, default expansion works on &ldquo;formats&rdquo; (search
paths), and not directly on environment variables.  Example, showing
the trailing &lsquo;<samp>:</samp>&rsquo; ignored in the first case and expanded in the second:
</p>
<div class="example">
<pre class="example">$ env TTFONTS=/tmp: kpsewhich --expand-path '$TTFONTS'
/tmp
$ env TTFONTS=/tmp: kpsewhich --show-path=.ttf
/tmp:.:/home/olaf/texmf/fonts/truetype//:...
</pre></div>

<p>Since Kpathsea looks for multiple configuration files, it would be
natural to expect that (for example) an extra colon in
<samp>./texmf.cnf</samp> would expand to the path in <samp>$TEXMF/texmf.cnf</samp>.
Or, with Dvips&rsquo; configuration files, that an extra colon in
<samp>config.$PRINTER</samp> would expand to the path in <samp>config.ps</samp>.
This doesn&rsquo;t happen.  It&rsquo;s not clear this would be desirable in all
cases, and trying to devise a way to specify the path to which the extra
colon should expand seemed truly baroque.
<span id="index-Bach_002c-Johann-Sebastian"></span>
</p>
<p>Technicality: Since it would be useless to insert the default value in
more than one place, Kpathsea changes only one extra &lsquo;<samp>:</samp>&rsquo; and leaves
any others in place (they will eventually be ignored).  Kpathsea checks
first for a leading &lsquo;<samp>:</samp>&rsquo;, then a trailing &lsquo;<samp>:</samp>&rsquo;, then a doubled
&lsquo;<samp>:</samp>&rsquo;.
</p>
<span id="index-kdefault_002ec"></span>
<p>You can trace this by debugging &ldquo;paths&rdquo; (see <a href="#Debugging">Debugging</a>).
Default expansion is implemented in the source file
<samp>kpathsea/kdefault.c</samp>.
</p>

<hr>
<span id="Variable-expansion"></span><div class="header">
<p>
Next: <a href="#Tilde-expansion" accesskey="n" rel="next">Tilde expansion</a>, Previous: <a href="#Default-expansion" accesskey="p" rel="prev">Default expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Variable-expansion-1"></span><h4 class="subsection">5.3.2 Variable expansion</h4>

<span id="index-_0024-expansion"></span>
<span id="index-environment-variables-in-paths"></span>
<span id="index-variable-expansion"></span>
<span id="index-expansion_002c-variable"></span>
<span id="index-texmf_002ecnf_002c-and-variable-expansion"></span>

<p>&lsquo;<samp>$foo</samp>&rsquo; or &lsquo;<samp>${foo}</samp>&rsquo; in a path element is replaced by (1) the
value of an environment variable &lsquo;<samp>foo</samp>&rsquo; (if defined); (2) the value
of &lsquo;<samp>foo</samp>&rsquo; from <samp>texmf.cnf</samp> (if defined); (3) the empty string.
</p>
<p>If the character after the &lsquo;<samp>$</samp>&rsquo; is alphanumeric or &lsquo;<samp>_</samp>&rsquo;, the
variable name consists of all consecutive such characters. If the
character after the &lsquo;<samp>$</samp>&rsquo; is a &lsquo;<samp>{</samp>&rsquo;, the variable name consists
of everything up to the next &lsquo;<samp>}</samp>&rsquo; (braces may not be nested around
variable names).  Otherwise, Kpathsea gives a warning and ignores the
&lsquo;<samp>$</samp>&rsquo; and its following character.
</p>
<span id="index-quoting-variable-values"></span>
<span id="index-shell-variables"></span>
<p>You must quote the <tt>$</tt>&rsquo;s and braces as necessary for your shell.
<em>Shell</em> variable values cannot be seen by Kpathsea, i.e., ones
defined by <code>set</code> in C shells and without <code>export</code> in Bourne
shells.
</p>
<p>For example, given
</p><div class="example">
<pre class="example">setenv tex /home/texmf
setenv TEXINPUTS .:$tex:${tex}prev
</pre></div>
<p>the final <code>TEXINPUTS</code> path is the three directories:
</p><div class="example">
<pre class="example">.:/home/texmf:/home/texmfprev
</pre></div>

<p>The &lsquo;<samp>.<var>progname</var></samp>&rsquo; suffix on variables and
&lsquo;<samp>_<var>progname</var></samp>&rsquo; on environment variable names are not implemented
for general variable expansions.  These are only recognized when search
paths are initialized (see <a href="#Path-sources">Path sources</a>).
</p>
<span id="index-variable_002ec"></span>
<p>Variable expansion is implemented in the source file
<samp>kpathsea/variable.c</samp>.
</p>

<hr>
<span id="Tilde-expansion"></span><div class="header">
<p>
Next: <a href="#Brace-expansion" accesskey="n" rel="next">Brace expansion</a>, Previous: <a href="#Variable-expansion" accesskey="p" rel="prev">Variable expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Tilde-expansion-1"></span><h4 class="subsection">5.3.3 Tilde expansion</h4>

<span id="index-_007e-expansion"></span>
<span id="index-home-directories-in-paths"></span>
<span id="index-tilde-expansion"></span>
<span id="index-expansion_002c-tilde"></span>

<span id="index-HOME_002c-as-_007e-expansion"></span>
<span id="index-USERPROFILE_002c-as-_007e-expansion"></span>
<p>A leading &lsquo;<samp>~</samp>&rsquo; in a path element is replaced by the value of the
environment variable <code>HOME</code>, or <samp>.</samp> if <code>HOME</code> is not
set.  On Windows, the environment variable <code>USERPROFILE</code> is
checked instead of <code>HOME</code>.
</p>
<p>A leading &lsquo;<samp>~<var>user</var></samp>&rsquo; in a path element is replaced by
<var>user</var>&rsquo;s home directory from the system <samp>passwd</samp> database.
</p>
<p>For example,
</p><div class="example">
<pre class="example">setenv TEXINPUTS ~/mymacros:
</pre></div>

<p>will prepend a directory <samp>mymacros</samp> in your home
directory to the default path.
</p>
<span id="index-root-user"></span>
<span id="index-trailing-_002f-in-home-directory"></span>
<span id="index-_002f_002c-trailing-in-home-directory"></span>
<p>As a special case, if a home directory ends in &lsquo;<samp>/</samp>&rsquo;, the trailing
slash is dropped, to avoid inadvertently creating a &lsquo;<samp>//</samp>&rsquo; construct
in the path.  For example, if the home directory of the user &lsquo;<samp>root</samp>&rsquo;
is &lsquo;<samp>/</samp>&rsquo;, the path element &lsquo;<samp>~root/mymacros</samp>&rsquo; expands to just
&lsquo;<samp>/mymacros</samp>&rsquo;, not &lsquo;<samp>//mymacros</samp>&rsquo;.
</p>
<span id="index-tilde_002ec"></span>
<p>Tilde expansion is implemented in the source file <samp>kpathsea/tilde.c</samp>.
</p>

<hr>
<span id="Brace-expansion"></span><div class="header">
<p>
Next: <a href="#KPSE_005fDOT-expansion" accesskey="n" rel="next">KPSE_DOT expansion</a>, Previous: <a href="#Tilde-expansion" accesskey="p" rel="prev">Tilde expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Brace-expansion-1"></span><h4 class="subsection">5.3.4 Brace expansion</h4>

<span id="index-_007b-expansion"></span>
<span id="index-brace-expansion"></span>

<p>&lsquo;<samp>x{<var>a</var>,<var>b</var>}y</samp>&rsquo; expands to &lsquo;<samp>x<var>a</var>y:x<var>b</var>y</samp>&rsquo;.
For example:
</p>
<div class="example">
<pre class="example">foo/{1,2}/baz
</pre></div>

<p>expands to &lsquo;<samp>foo/1/baz:foo/2/baz</samp>&rsquo;.  &lsquo;<samp>:</samp>&rsquo; is the path
separator on the current system; e.g., on a Windows system, it&rsquo;s &lsquo;<samp>;</samp>&rsquo;.
</p>
<p>Braces can be nested; for example, &lsquo;<samp>x{A,B{1,2}}y</samp>&rsquo; expands to
&lsquo;<samp>xAy:xB1y:xB2y</samp>&rsquo;.
</p>
<p>Multiple non-nested braces are expanded from right to left; for example,
&lsquo;<samp>x{A,B}{1,2}y</samp>&rsquo; expands to &lsquo;<samp>x{A,B}1y:x{A,B}2y</samp>&rsquo;, which
expands to &lsquo;<samp>xA1y:xB1y:xA2y:xB2y</samp>&rsquo;.
</p>
<span id="index-multiple-TeX-hierarchies"></span>
<p>This feature can be used to implement multiple TeX hierarchies, by
assigning a brace list to <code>$TEXMF</code>, as mentioned in
<samp>texmf.in</samp>.
</p>
<p>You can also use the path separator instead of the comma.  The last
example could have been written &lsquo;<samp>x{A:B}{1:2}y</samp>&rsquo; (on Unix).
</p>

<span id="index-expand_002ec"></span>
<p>Brace expansion is implemented in the source file
<samp>kpathsea/expand.c</samp>.
</p>

<hr>
<span id="KPSE_005fDOT-expansion"></span><div class="header">
<p>
Next: <a href="#Subdirectory-expansion" accesskey="n" rel="next">Subdirectory expansion</a>, Previous: <a href="#Brace-expansion" accesskey="p" rel="prev">Brace expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="KPSE_005fDOT-expansion-1"></span><h4 class="subsection">5.3.5 <code>KPSE_DOT</code> expansion</h4>

<span id="index-KPSE_005fDOT-expansion"></span>

<p>When <code>KPSE_DOT</code> is defined in the environment, it names a directory
that should be considered the current directory for the purpose of
looking up files in the search paths.  This feature is needed by the
&lsquo;<samp>mktex&hellip;</samp>&rsquo; scripts <a href="#mktex-scripts">mktex scripts</a>, because these
change the working directory.  You should not ever define it yourself.
</p>

<hr>
<span id="Subdirectory-expansion"></span><div class="header">
<p>
Previous: <a href="#KPSE_005fDOT-expansion" accesskey="p" rel="prev">KPSE_DOT expansion</a>, Up: <a href="#Path-expansion" accesskey="u" rel="up">Path expansion</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Subdirectory-expansion-1"></span><h4 class="subsection">5.3.6 Subdirectory expansion</h4>

<span id="index-_002f_002f"></span>
<span id="index-subdirectory-searching"></span>
<span id="index-expansion_002c-subdirectory"></span>

<span id="index-alphabetical-order_002c-not"></span>
<p>Two or more consecutive slashes in a path element following a directory
<var>d</var> is replaced by all subdirectories of <var>d</var>: first those
subdirectories directly under <var>d</var>, then the subsubdirectories under
those, and so on.  At each level, the order in which the directories are
searched is unspecified.  (It&rsquo;s &ldquo;directory order&rdquo;, and definitely not
alphabetical.)
</p>
<p>If you specify any filename components after the &lsquo;<samp>//</samp>&rsquo;, only
subdirectories which match those components are included.  For example,
&lsquo;<samp>/a//b</samp>&rsquo; would expand into directories <samp>/a/1/b</samp>, <samp>/a/2/b</samp>,
<samp>/a/1/1/b</samp>, and so on, but not <samp>/a/b/c</samp> or <samp>/a/1</samp>.
</p>
<p>You can include multiple &lsquo;<samp>//</samp>&rsquo; constructs in the path.
</p>
<p>&lsquo;<samp>//</samp>&rsquo; at the beginning of a path is ignored; you didn&rsquo;t really want
to search every directory on the system, did you?
</p>
<span id="index-trick-for-detecting-leaf-directories"></span>
<span id="index-leaf-directory-trick"></span>
<span id="index-Farwell_002c-Matthew"></span>
<span id="index-MacKenzie_002c-David-1"></span>
<p>I should mention one related implementation trick, which I took from GNU
find.  Matthew Farwell suggested it, and David MacKenzie implemented it.
</p>
<span id="index-st_005fnlink"></span>
<p>The trick is that in every real Unix implementation (as opposed to the
POSIX specification), a directory which contains no subdirectories will
have exactly two links (namely, one for <samp>.</samp> and one for <samp>..</samp>).
That is to say, the <code>st_nlink</code> field in the &lsquo;<samp>stat</samp>&rsquo; structure
will be two.  Thus, we don&rsquo;t have to stat everything in the bottom-level
(leaf) directories&mdash;we can just check <code>st_nlink</code>, notice it&rsquo;s two,
and do no more work.
</p>
<p>But if you have a directory that contains a single subdirectory and 500
regular files, <code>st_nlink</code> will be 3, and Kpathsea has to stat every
one of those 501 entries.  Therein lies slowness.
</p>
<span id="index-ST_005fNLINK_005fTRICK"></span>
<p>You can disable the trick by undefining <code>ST_NLINK_TRICK</code> in
<samp>kpathsea/config.h</samp>. (It is undefined by default except under Unix.)
</p>
<span id="index-elt_002ddirs_002ec"></span>
<p>Unfortunately, in some cases files in leaf directories are
<code>stat</code>&rsquo;d: if the path specification is, say,
&lsquo;<samp>$TEXMF/fonts//pk//</samp>&rsquo;, then files in a subdirectory
&lsquo;<samp>&hellip;/pk</samp>&rsquo;, even if it is a leaf, are checked. The reason
cannot be explained without reference to the implementation, so read
<samp>kpathsea/elt-dirs.c</samp> (search for &lsquo;<samp>may descend</samp>&rsquo;) if you are
curious.  And if you find a way to solve the problem, please let me
know.
</p>
<span id="index-elt_002ddirs_002ec-1"></span>
<p>Subdirectory expansion is implemented in the source file
<samp>kpathsea/elt-dirs.c</samp>.
</p>

<hr>
<span id="Casefolding-search"></span><div class="header">
<p>
Next: <a href="#Filename-database" accesskey="n" rel="next">Filename database</a>, Previous: <a href="#Path-expansion" accesskey="p" rel="prev">Path expansion</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Casefolding-search-1"></span><h3 class="section">5.4 Casefolding search</h3>

<span id="index-casefolding-search"></span>
<span id="index-search_002c-case_002dinsensitive"></span>

<p>In Kpathsea version 6.3.0 (released with TeX Live 2018), a new
fallback search was implemented on Unix-like systems, including Macs:
for each path element in turn, if no match is found by the normal
search, and the path element allows for checking the filesystem, a
second check is made for a case-insensitive match.
</p>
<span id="index-texmf_005fcasefold_005fsearch"></span>
<p>This is enabled at compile-time on Unix systems, and enabled at
runtime by setting the configuration variable
<code>texmf_casefold_search</code>, to a true value, e.g., &lsquo;<samp>1</samp>&rsquo;; this is
done by default in TeX Live.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Casefolding-rationale" accesskey="1">Rationale</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Casefolding-examples" accesskey="2">Examples</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
</table>

<hr>
<span id="Casefolding-rationale"></span><div class="header">
<p>
Next: <a href="#Casefolding-examples" accesskey="n" rel="next">Casefolding examples</a>, Up: <a href="#Casefolding-search" accesskey="u" rel="up">Casefolding search</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Casefolding-rationale-1"></span><h4 class="subsection">5.4.1 Casefolding rationale</h4>

<span id="index-casefolding-fallback-rationale"></span>
<span id="index-rationale-for-casefolding-fallback"></span>
<span id="index-system_002ddependent-casefolding-behavior"></span>

<span id="index-filesystem_002c-case_002d_0028in_0029sensitive"></span>
<span id="index-Apple-filesystem_002c-case_002dinsensitive"></span>
<span id="index-Mac-filesystem_002c-case_002dinsensitive"></span>
<p>The purpose of the fallback casefolding search is to ease moving
complex documents between case-insensitive (file)systems and
case-sensitive ones.  In particular, Apple decided to make the default
filesystem on Macs be case-insensitive some years ago, and this has
exacerbated a problem of people creating documents that use, say, an
image under the name <samp>foo.jpg</samp>, while the actual file is named
<samp>foo.JPG</samp> or <samp>Foo.jpg</samp>. It works on the Mac but if the
document is transferred and run on a standard case-sensitive Unix
(file)system, the file can&rsquo;t be found, due only to differences in
case.
</p>
<p>This same problematic scenario has always existed on Windows, but for
whatever reason, it has become much more common since Apple also went
to a case-insensitive filesystem.  Hence the relatively late change
to the Kpathsea behavior.
</p>
<span id="index-Windows-and-casefolding"></span>
<p>The fallback case-insensitive search is omitted at compile-time on
Windows, where (for practical purposes) all file names are
case-insensitive at the kernel level, and so the normal search will
already have definitively matched or not.  Therefore, search results
in unusual cases can be different on Windows and Unix&mdash;but this has
always been true.
</p>

<hr>
<span id="Casefolding-examples"></span><div class="header">
<p>
Previous: <a href="#Casefolding-rationale" accesskey="p" rel="prev">Casefolding rationale</a>, Up: <a href="#Casefolding-search" accesskey="u" rel="up">Casefolding search</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Casefolding-examples-1"></span><h4 class="subsection">5.4.2 Casefolding examples</h4>

<span id="index-casefolding-examples"></span>
<span id="index-examples_002c-of-casefolding-searches"></span>

<p>The casefolding implementation prefers exact matches to casefolded
matches within a given path element, so as to retain most
compatibility.  Backward compatibility is not perfect, however, as a
casefolded match may be found in an earlier path element than an exact
match was previously found (see example #4 below).  Still, preferring
the match in the earlier element seemed potentially less confusing
than otherwise, and is in fact consistent with past behavior on
Windows.  Since case mismatches are rare to begin with, and name
collisions with respect only to case thus even more rare, the hope is
that it will not cause difficulties in practice.
</p>
<p>If it&rsquo;s desirable in a given situation to have the exact same search
behavior as previously, that can be accomplished by setting the
configuration variable <code>texmf_casefold_search</code> to &lsquo;<samp>0</samp>&rsquo;
(see <a href="#Path-sources">Path sources</a>).
</p>
<p>Some examples to illustrate the new behavior follow.
</p>
<p>Example #1: suppose the file <samp>./foobar.tex</samp> exists. Now,
searching for <samp>./FooBar.TeX</samp> (or any other case variation) will
succeed, returning <samp>./foobar.tex</samp>&mdash;the name as stored on disk.
In previous releases, or if <code>texmf_casefold_search</code> is false, the
search would fail.
</p>
<p>Example #2: suppose we are using a case-sensitive (file)system, and
the search path is &lsquo;<samp>.:/somedir</samp>&rsquo;, and the files
<samp>./foobar.tex</samp> and <samp>/somedir/FooBar.TeX</samp> both exist.  Both
now and previously, searching for <samp>foobar.tex</samp> returns
<samp>./foobar.tex</samp>.  However, searching for <samp>FooBar.TeX</samp> now
returns <samp>./foobar.tex</samp> instead of <samp>/somedir/FooBar.TeX</samp>;
this is the incompatibility mentioned above.  Also (as expected),
searching for <samp>FOOBAR.TEX</samp> (or whatever variation) will now
return <samp>./foobar.tex</samp>, whereas before it would fail.  Searching
for all (&lsquo;<samp>kpsewhich --all</samp>&rsquo;) <samp>foobar.tex</samp> will return both
matches.
</p>
<p>Example #3: same as example #2, but on a case-insensitive
(file)system: both now and previously, searching for <samp>FooBar.TeX</samp>
returns <samp>./foobar.tex</samp>, since the system considers that a match.
The Kpathsea casefolding never comes into play.
</p>
<p>Example #4: if we have (on a case-sensitive system) both
<samp>./foobar.tex</samp> and <samp>./FOOBAR.TEX</samp>, searching with the exact
case returns that exact match, now and previously.  Searching for
<samp>FooBar.tex</samp> will now return one or the other (chosen
arbitrarily), rather than failing.  Perhaps unexpectedly, searching
for all <samp>foobar.tex</samp> or <samp>FooBar.tex</samp> will also return only
one or the other, not both (see more below).
</p>
<p>Example #5: the font file <samp>STIX-Regular.otf</samp> is included in
TeX Live in the system directory
<samp>texmf-dist/fonts/opentype/public/stix</samp>.  Because Kpathsea never
searches the disk in the big system directory, the casefolding is not
done, and a search for &lsquo;<samp>stix-regular.otf</samp>&rsquo; will fail (on
case-sensitive systems), as it always has.
</p>
<span id="index-_0021_0021-and-casefolding"></span>
<p>The caveat about not searching the disk amounts to saying that
casefolding does not happen in the trees specified with &lsquo;<samp>!!</samp>&rsquo;
(see <a href="#ls_002dR">ls-R</a>), that is, where only database (<samp>ls-R</samp>) searching
is done.  In TeX Live, that is the &lsquo;<samp>texmf-local</samp>&rsquo; and
&lsquo;<samp>texmf-dist</samp>&rsquo; trees (also <code>$TEXMFSYSCONFIG</code> and
<code>$TEXMFSYSVAR</code>, but those are rarely noticed).  The rationale for
this is that in practice, case mangling happens with user-created
files, not with packages distributed as part of the TeX system.
</p>
<p>One more caveat: the purpose of <code>kpsewhich</code> is to exercise the
path searching in Kpathsea as it is actually done.  Therefore, as
shown above, &lsquo;<samp>kpsewhich --all</samp>&rsquo; will not return all matches
regardless of case within a given path element.  If you want to find
all matches in all directories, <code>find</code> is the best tool, although
the setup takes a couple steps:
</p>
<div class="example">
<pre class="example">kpsewhich -show-path=tex &gt;/tmp/texpath      # search path specification
kpsewhich -expand-path=&quot;`cat /tmp/texpath`&quot; &gt;/tmp/texdirs  # all dirs
tr ':' '\n' &lt;/tmp/texdirs &gt;/tmp/texdirlist  # colons to newlines
find `cat /tmp/texdirlist` -iname somefile.tex -print &lt;/tmp/texdirlist
</pre></div>

<span id="index-Findutils_002c-GNU-package"></span>
<span id="index-_002diname_002c-find-predicate"></span>
<p>Sorry that it&rsquo;s annoyingly lengthy, but implementing this inside
Kpathsea would be a lot of error-prone trouble for something that is
only useful for debugging.  If your <code>find</code> does not support
<code>-iname</code>, you can get GNU Find from
<a href="https://gnu.org/software/findutils">https://gnu.org/software/findutils</a>.
</p>
<p>The casefolding search is implemented in the source file
<samp>kpathsea/pathsearch.c</samp>.  Two implementation points:
</p>
<ul>
<li> <span id="index-access-system-call"></span>
Kpathsea never tries to check if a given directory resides on a
case-insensitive filesystem, because there is no efficient and
portable way to do so.  All it does is try to see if a potential file
name is a readable normal file (with, usually, the <code>access</code>
system call).

</li><li> Kpathsea does not do any case-insensitive matching of the directories
along the path.  It&rsquo;s not going to find <samp>/Some/Random/file.tex</samp>
when looking for <samp>/some/random/file.tex</samp>.  The casefolding only
happens with the elements of the leaf directory.

</li></ul>


<hr>
<span id="Filename-database"></span><div class="header">
<p>
Next: <a href="#Invoking-kpsewhich" accesskey="n" rel="next">Invoking kpsewhich</a>, Previous: <a href="#Casefolding-search" accesskey="p" rel="prev">Casefolding search</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Filename-database-_0028ls_002dR_0029"></span><h3 class="section">5.5 Filename database (<code>ls-R</code>)</h3>

<span id="index-filename-database"></span>
<span id="index-database_002c-for-filenames"></span>
<span id="index-externally_002dbuilt-filename-database"></span>

<p>Kpathsea goes to some lengths to minimize disk accesses for searches
(see <a href="#Subdirectory-expansion">Subdirectory expansion</a>).  Nevertheless, in practice searching
every possible directory in typical TeX installations takes an
excessively long time.
</p>
<p>Therefore, Kpathsea can use an externally-built <em>filename
database</em> file named <samp>ls-R</samp> that maps files to directories, thus
avoiding the need to exhaustively search the disk.
</p>
<p>A second database file <samp>aliases</samp> allows you to give additional
names to the files listed in <samp>ls-R</samp>.
</p>
<p>The <samp>ls-R</samp> and <samp>aliases</samp> features are implemented in the
source file <samp>kpathsea/db.c</samp>.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#ls_002dR" accesskey="1">ls-R</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">The main filename database.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Filename-aliases" accesskey="2">Filename aliases</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Aliases for those names.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Database-format" accesskey="3">Database format</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Syntax details of the database file.
</td></tr>
</table>


<hr>
<span id="ls_002dR"></span><div class="header">
<p>
Next: <a href="#Filename-aliases" accesskey="n" rel="next">Filename aliases</a>, Up: <a href="#Filename-database" accesskey="u" rel="up">Filename database</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="ls_002dR-1"></span><h4 class="subsection">5.5.1 <samp>ls-R</samp></h4>

<span id="index-ls_002dR-database-file"></span>

<p>As mentioned above, you must name the main filename database
<samp>ls-R</samp>.  You can put one at the root of each TeX installation
hierarchy you wish to search (<code>$TEXMF</code> by default, which expands
to a braced list of several hierarchies in TeX Live). 
</p>
<span id="index-TEXMFDBS"></span>
<span id="index-_0021_0021-in-TEXMFDBS"></span>
<p>Kpathsea looks for <samp>ls-R</samp> files along the <code>TEXMFDBS</code>
path. It is best for this to contain all and only those hierarchies
from <code>$TEXMF</code> which are specified with <code>!!</code>&mdash;and also to
specify them with <code>!!</code> in <code>TEXMFDBS</code>. (See the end of this
section for more on <code>!!</code>.)
</p>
<p>The recommended way to create and maintain &lsquo;<samp>ls-R</samp>&rsquo; is to run the
<code>mktexlsr</code> script, which is installed in &lsquo;<samp>$(bindir)</samp>&rsquo;
(<samp>/usr/local/bin</samp> by default).  That script goes to some trouble to
follow symbolic links as necessary, etc.  It&rsquo;s also invoked by the
distributed &lsquo;<samp>mktex&hellip;</samp>&rsquo; scripts.
</p>
<span id="index-ls_002dR_002c-simplest-build"></span>
<p>At its simplest, though, you can build <samp>ls-R</samp> with the command
</p><div class="example">
<pre class="example">cd <var>/your/texmf/root</var> &amp;&amp; ls -LAR ./ &gt;ls-R
</pre></div>

<p><span id="index-_002d_002dcolor_003dtty"></span>
<span id="index-_002fetc_002fprofile-and-aliases"></span>
presuming your <code>ls</code> produces the right output format (see the
section below).  GNU <code>ls</code>, for example, outputs in this format.
Also presuming your <code>ls</code> hasn&rsquo;t been aliased in a system file
(e.g., <samp>/etc/profile</samp>) to something problematic, e.g., &lsquo;<samp>ls
--color=tty</samp>&rsquo;.  In that case, you will have to disable the alias before
generating <samp>ls-R</samp>.  For the precise definition of the file format,
see <a href="#Database-format">Database format</a>.
</p>
<p>Regardless of whether you use the supplied script or your own, you
will almost certainly want to invoke it via <code>cron</code>, so when you
make changes in the installed files (say if you install a new LaTeX
package), <samp>ls-R</samp> will be automatically updated.  However, for
those using TeX Live or system distributions, the package managers
should run <code>mktexlsr</code> as needed.
</p>
<span id="index-_002dA-option-to-ls"></span>
<span id="index-dot-files"></span>
<span id="index-_002e-files"></span>
<span id="index-_002e-directories_002c-ignored"></span>
<span id="index-_002etex-file_002c-included-in-ls_002dR"></span>
<p>The &lsquo;<samp>-A</samp>&rsquo; option to <code>ls</code> includes files beginning with &lsquo;<samp>.</samp>&rsquo;
(except for <samp>.</samp> and <samp>..</samp>), such as the file <samp>.tex</samp>
included with the LaTeX tools package.  (On the other hand,
<em>directories</em> whose names begin with &lsquo;<samp>.</samp>&rsquo; are always ignored.)
</p>
<span id="index-symbolic-links_002c-and-ls_002dR"></span>
<span id="index-_002dL-option-to-ls"></span>
<p>If your system does not support symbolic links, omit the &lsquo;<samp>-L</samp>&rsquo;.
</p>
<span id="index-automounter_002c-and-ls_002dR"></span>
<span id="index-NFS-and-ls_002dR"></span>
<p><code>ls -LAR <var>/your/texmf/root</var></code> will also work.  But using
&lsquo;<samp>./</samp>&rsquo; avoids embedding absolute pathnames, so the hierarchy can be
easily transported.  It also avoids possible trouble with automounters
or other network filesystem conventions.
</p>
<span id="index-warning-about-unusable-ls_002dR"></span>
<span id="index-unusable-ls_002dR-warning"></span>
<p>Kpathsea warns you if it finds an <samp>ls-R</samp> file, but the file does
not contain any usable entries.  The usual culprit is running plain
&lsquo;<samp>ls -R</samp>&rsquo; instead of &lsquo;<samp>ls -LR ./</samp>&rsquo; or &lsquo;<samp>ls -R
<var>/your/texmf/root</var></samp>&rsquo;.  Another possibility is some system directory
name starting with a &lsquo;<samp>.</samp>&rsquo; (perhaps if you are using AFS); Kpathsea
ignores everything under such directories.
</p>
<span id="index-_0021_0021-in-path-specifications"></span>
<span id="index-disk-searching_002c-avoiding"></span>
<p>If a particular path element begins with &lsquo;<samp>!!</samp>&rsquo;, <em>only</em> the
database will be searched for that element, never the disk; and if the
database does not exist, nothing at all will be searched.  In TeX
Live, most of the trees are specified with &lsquo;<samp>!!</samp>&rsquo;.
</p>
<p>For path elements that do not begin with &lsquo;<samp>!!</samp>&rsquo;, if the database
exists, it will be used, and the disk will not be searched.  However,
in this case, if the database does not exist, the disk will be
searched.  In TeX Live, the most notable case of this is the
<code>TEXMFHOME</code> tree, to allow users to add and remove files from
their own tree without having to worry about <code>ls-R</code>.
</p>
<p>(Aside: there are uncommon cases where a &lsquo;<samp>!!</samp>&rsquo; tree will be
searched on disk even if the <code>ls-R</code> file exists; they are too
obscure to try to explain here.  See <samp>pathsearch.c</samp> in the source
if you need to know.)
</p>
<p>To sum up: do not create an <code>ls-R</code> file unless you also take care
to keep it up to date. Otherwise newly-installed files will not be
found.
</p>


<hr>
<span id="Filename-aliases"></span><div class="header">
<p>
Next: <a href="#Database-format" accesskey="n" rel="next">Database format</a>, Previous: <a href="#ls_002dR" accesskey="p" rel="prev">ls-R</a>, Up: <a href="#Filename-database" accesskey="u" rel="up">Filename database</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Filename-aliases-1"></span><h4 class="subsection">5.5.2 Filename aliases</h4>

<span id="index-filename-aliases"></span>
<span id="index-aliases_002c-for-filenames"></span>

<p>In some circumstances, you may wish to find a file under several names.
For example, suppose a TeX document was created using a DOS system
and tries to read <samp>longtabl.sty</samp>.  But now it&rsquo;s being run on a Unix
system, and the file has its original name, <samp>longtable.sty</samp>.  The
file won&rsquo;t be found.  You need to give the actual file
<samp>longtable.sty</samp> an alias &lsquo;<samp>longtabl.sty</samp>&rsquo;.
</p>

<p>You can handle this by creating a file <samp>aliases</samp> as a companion to
the <samp>ls-R</samp> for the hierarchy containing the file in question.  (You
must have an <samp>ls-R</samp> for the alias feature to work.)
</p>
<p>The format of <samp>aliases</samp> is simple: two whitespace-separated words
per line; the first is the real name <samp>longtable.sty</samp>, and second is
the alias (<samp>longtabl.sty</samp>).  These must be base filenames, with no
directory components.  <samp>longtable.sty</samp> must be in the sibling
<samp>ls-R</samp>.
</p>
<p>Also, blank lines and lines starting with &lsquo;<samp>%</samp>&rsquo; or &lsquo;<samp>#</samp>&rsquo; are
ignored in <samp>aliases</samp>, to allow for comments.
</p>
<p>If a real file <samp>longtabl.sty</samp> exists, it is used regardless of any
aliases.
</p>

<hr>
<span id="Database-format"></span><div class="header">
<p>
Previous: <a href="#Filename-aliases" accesskey="p" rel="prev">Filename aliases</a>, Up: <a href="#Filename-database" accesskey="u" rel="up">Filename database</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Database-format-1"></span><h4 class="subsection">5.5.3 Database format</h4>

<span id="index-format-of-external-database"></span>
<span id="index-database_002c-format-of"></span>

<p>The &ldquo;database&rdquo; read by Kpathsea is a line-oriented file of plain
text. The format is that generated by GNU (and most other) <code>ls</code>
programs given the &lsquo;<samp>-R</samp>&rsquo; option, as follows.
</p>
<ul>
<li> Blank lines are ignored.

</li><li> If a line begins with &lsquo;<samp>/</samp>&rsquo; or &lsquo;<samp>./</samp>&rsquo; or &lsquo;<samp>../</samp>&rsquo; and ends with
a colon, it&rsquo;s the name of a directory.  (&lsquo;<samp>../</samp>&rsquo; lines aren&rsquo;t useful,
however, and should not be generated.)

</li><li> All other lines define entries in the most recently seen directory.
<tt>/</tt>&rsquo;s in such lines will produce possibly-strange results.

</li><li> Files with no preceding directory line are ignored.
</li></ul>

<p>For example, here&rsquo;s the first few lines of <samp>ls-R</samp> (which totals
about 30K bytes) on my system:
</p>
<div class="example">
<pre class="example">bibtex
dvips
fonts
ls-R
metafont
metapost
tex
web2c

./bibtex:
bib
bst
doc

./bibtex/bib:
asi.bib
btxdoc.bib
&hellip;
</pre></div>


<hr>
<span id="Invoking-kpsewhich"></span><div class="header">
<p>
Previous: <a href="#Filename-database" accesskey="p" rel="prev">Filename database</a>, Up: <a href="#Path-searching" accesskey="u" rel="up">Path searching</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="kpsewhich_003a-Standalone-path-searching"></span><h3 class="section">5.6 <code>kpsewhich</code>: Standalone path searching</h3>

<span id="index-kpsewhich"></span>
<span id="index-path-searching_002c-standalone"></span>
<span id="index-standalone-path-searching"></span>

<p>The Kpsewhich program exercises the path searching functionality
independent of any particular application.  This can also be useful as a
sort of <code>find</code> program to locate files in your TeX hierarchies,
perhaps in administrative scripts.  It is used heavily in the
distributed &lsquo;<samp>mktex&hellip;</samp>&rsquo; scripts.
</p>
<p>Synopsis:
</p>
<div class="example">
<pre class="example">kpsewhich <var>option</var>&hellip; <var>filename</var>&hellip;
</pre></div>

<p>The options and filename(s) to look up can be intermixed.
Options can start with either &lsquo;<samp>-</samp>&rsquo; or &lsquo;<samp>--</samp>&rsquo;, and any unambiguous
abbreviation is accepted.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Path-searching-options" accesskey="1">Path searching options</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Changing the mode, resolution, etc.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Specially_002drecognized-files" accesskey="2">Specially-recognized files</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Default formats for texmf.cnf, etc.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Auxiliary-tasks" accesskey="3">Auxiliary tasks</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Path and variable expansion, etc.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Standard-options" accesskey="4">Standard options</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">&lsquo;<samp>--help</samp>&rsquo; and &lsquo;<samp>--version</samp>&rsquo;.
</td></tr>
</table>


<hr>
<span id="Path-searching-options"></span><div class="header">
<p>
Next: <a href="#Specially_002drecognized-files" accesskey="n" rel="next">Specially-recognized files</a>, Up: <a href="#Invoking-kpsewhich" accesskey="u" rel="up">Invoking kpsewhich</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Path-searching-options-1"></span><h4 class="subsection">5.6.1 Path searching options</h4>

<span id="index-path-searching-options"></span>

<p>Kpsewhich looks up each non-option argument on the command line as a
filename, and returns the first file found.
</p>
<p>Various options alter the path searching behavior:
</p>
<dl compact="compact">
<dt>&lsquo;<samp>--all</samp>&rsquo;</dt>
<dd><span id="index-_002d_002dall"></span>
<span id="index-all-matches_002c-finding"></span>
<p>Report all matches found, one per line.  By default, if there is more
than one match, just one will be reported (chosen effectively at
random).  Exception: with the glyph formats (<code>pk</code>, <code>gf</code>),
this option has no effect and only the first match is returned.
</p>
</dd>
<dt>&lsquo;<samp>--casefold-search</samp>&rsquo;</dt>
<dt>&lsquo;<samp>--no-casefold-search</samp>&rsquo;</dt>
<dd><span id="index-_002d_002dcasefold_002dsearch"></span>
<span id="index-_002d_002dno_002dcasefold_002dsearch"></span>
<p>Explicitly enable or disable the fallback to a case-insensitive search
on Unix platforms (see <a href="#Casefolding-search">Casefolding search</a>); no effect on Windows.
The default is enabled, set in <code>texmf.cnf</code>.  Disabling
(<code>--no-casefold-search</code>) does not mean that searches magically
become case-sensitive when the underlying (file)system is
case-insensitive, it merely means that Kpathsea does not do any
casefolding itself.
</p>
</dd>
<dt>&lsquo;<samp>--cnf-line=<var>str</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dcnf_002dline"></span>
<p>Parse <var>str</var> as if it were a line in the <samp>texmf.cnf</samp>
configuration file (see <a href="#Config-files">Config files</a>), overriding settings in the
actual configuration files, and also in the environment (see <a href="#Path-sources">Path sources</a>).  This is implemented by making any settings from <var>str</var>
in the environment, overwriting any value already there.  Thus, an
extra colon in a &lsquo;<samp>--cnf-line</samp>&rsquo; value will refer to the value from
a configuration file, not a user-set environment variable.
</p>
<p>Furthermore, any variable set from <var>str</var> will also be set with the
program name suffix.  For example, <code>pdftex
--cnf-line=TEXINPUTS=/foo:</code> will set both <code>TEXINPUTS</code> and
<code>TEXINPUTS_pdftex</code> in the environment (and the value will be
<samp>/foo</samp> followed by the setting from <samp>texmf.cnf</samp>, ignoring
any user-set <code>TEXINPUTS</code>).
</p>
<p>This behavior is desirable because, in practice, many variables in the
distributed <samp>texmf.cnf</samp> are program-specific, and the intuitive
behavior is for values set on the command line with <code>--cnf-line</code>
to override them.
</p>
</dd>
<dt>&lsquo;<samp>--dpi=<var>num</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002ddpi_003dnum"></span>
<span id="index-_002dD-num"></span>
<span id="index-resolution_002c-setting"></span>
<p>Set the resolution to <var>num</var>; this only affects &lsquo;<samp>gf</samp>&rsquo; and
&lsquo;<samp>pk</samp>&rsquo; lookups.  &lsquo;<samp>-D</samp>&rsquo; is a synonym, for compatibility with
Dvips.  Default is 600.
</p>
</dd>
<dt>&lsquo;<samp>--engine=<var>name</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dengine_003dname"></span>
<span id="index-engine-name"></span>
<p>Set the engine name to <var>name</var>.  By default it is not set.  The
engine name is used in some search paths to allow files with the same
name but used by different engines to coexist.
</p>
<p>In particular, since the memory dump files
(<samp>.fmt</samp>/<samp>.base</samp>/<samp>.mem</samp>) are now stored in
subdirectories named for the engine (<samp>tex</samp>, <samp>pdftex</samp>,
<samp>xetex</samp>, etc.), you must specify an engine name in order to find
them.  For example, <samp>cont-en.fmt</samp> typically exists for both
<samp>pdftex</samp> and <samp>xetex</samp>.  With the default path settings, you
can use &lsquo;<samp>--engine=/</samp>&rsquo; to look for any dump file, regardless of
engine; if a dump file exists for more than one engine, it&rsquo;s
indeterminate which one is returned.  (The &lsquo;<samp>/</samp>&rsquo; ends up specifying
a normal recursive search along the path where the dumps are stored,
namely &lsquo;<samp>$TEXMF/web2c{/$engine,}</samp>&rsquo;.)
</p>
</dd>
<dt>&lsquo;<samp>--format=<var>name</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dformat_003dname"></span>
<p>Set the format for lookup to <var>name</var>.  By default, the format is
guessed from the filename, with &lsquo;<samp>tex</samp>&rsquo; being used if nothing else
fits.  The recognized filename extensions (including any leading
&lsquo;<samp>.</samp>&rsquo;) are also allowable <var>name</var>s.
</p>
<p>All formats also have a name, which is the only way to specify formats
with no associated suffix.  For example, for Dvips configuration files
you can use &lsquo;<samp>--format=&quot;dvips config&quot;</samp>&rsquo;.  (The quotes are for the
sake of the shell.)
</p>
<p>Here&rsquo;s the current list of recognized names and the associated suffixes.
See <a href="#Supported-file-formats">Supported file formats</a>, for more information on each of these.
</p>
<p>The strings in parentheses are abbreviations recognized only by
<code>kpsewhich</code> (not the underlying library calls).  They are
provided when it would otherwise require an argument containing a
space to specify the format, to simplify quoting of calls from shells.
</p>
<div class="example">
<pre class="example">gf: gf
pk: pk
bitmap font (bitmapfont):
tfm: .tfm
afm: .afm
base: .base
bib: .bib
bst: .bst
cnf: .cnf
ls-R: ls-R ls-r
fmt: .fmt
map: .map
mem: .mem
mf: .mf
mfpool: .pool
mft: .mft
mp: .mp
mppool: .pool
MetaPost support (mpsupport):
ocp: .ocp
ofm: .ofm .tfm
opl: .opl  .pl
otp: .otp
ovf: .ovf .vf
ovp: .ovp  .vpl
graphic/figure:  .eps .epsi
tex: .tex  .sty .cls .fd .aux .bbl .def .clo .ldf
TeX system documentation (doc):
texpool: .pool
TeX system sources (source):  .dtx .ins
PostScript header:  .pro
Troff fonts (trofffont):
type1 fonts: .pfa .pfb
vf: .vf
dvips config (dvipsconfig):
ist: .ist
truetype fonts: .ttf .ttc .TTF .TTC .dfont
type42 fonts: .t42 .T42
web2c files (web2c):
other text files (othertext):
other binary files (otherbin):
misc fonts (miscfont):
web: .web  .ch
cweb: .w .web  .ch
enc files: .enc
cmap files (cmap):
subfont definition files: .sfd
opentype fonts: .otf
pdftex config (pdftexconfig):
lig files: .lig
texmfscripts:
lua: .lua .luatex .luc .luctex .texlua .texluc .tlu
font feature files: .fea
cid maps: .cid .cidmap
mlbib: .mlbib .bib
mlbst: .mlbst .bst
clua: .dll .so
ris: .ris
bltxml: .bltxml
</pre></div>

<p>This option and &lsquo;<samp>--path</samp>&rsquo; are mutually exclusive.
</p>
</dd>
<dt>&lsquo;<samp>--interactive</samp>&rsquo;</dt>
<dd><span id="index-_002d_002dinteractive"></span>
<span id="index-interactive-query"></span>
<p>After processing the command line, read additional filenames to look up
from standard input.
</p>
</dd>
<dt>&lsquo;<samp>--mktex=<var>filetype</var></samp>&rsquo;</dt>
<dt>&lsquo;<samp>--no-mktex=<var>filetype</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dmktex_003dfiletype"></span>
<span id="index-_002d_002dno_002dmktex_003dfiletype"></span>
<p>Turn on or off the &lsquo;<samp>mktex</samp>&rsquo; script associated with <var>filetype</var>.
Usual values for <var>filetype</var> are &lsquo;<samp>pk</samp>&rsquo;, &lsquo;<samp>mf</samp>&rsquo;, &lsquo;<samp>tex</samp>&rsquo;,
and &lsquo;<samp>tfm</samp>&rsquo;.  By default, all are off in Kpsewhich, even if they
are enabled for TeX.  This option implies setting
<code>--must-exist</code>.  See <a href="#mktex-scripts">mktex scripts</a>.
</p>
</dd>
<dt>&lsquo;<samp>--mode=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dmode_003dstring"></span>
<p>Set the mode name to <var>string</var>; this also only affects &lsquo;<samp>gf</samp>&rsquo; and
&lsquo;<samp>pk</samp>&rsquo; lookups.  No default: any mode will be found.  See <a href="#mktex-script-arguments">mktex script arguments</a>.
</p>
</dd>
<dt>&lsquo;<samp>--must-exist</samp>&rsquo;</dt>
<dd><span id="index-_002d_002dmust_002dexist"></span>
<p>Do everything possible to find the files, notably including searching
the disk and running the &lsquo;<samp>mktex</samp>&rsquo; scripts.  By default, only the
<samp>ls-R</samp> database is checked, in the interest of efficiency.
</p>
</dd>
<dt>&lsquo;<samp>--path=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dpath_003dstring"></span>
<p>Search along the path <var>string</var> (colon-separated as usual), instead
of guessing the search path from the filename.  &lsquo;<samp>//</samp>&rsquo; and all the
usual expansions are supported (see <a href="#Path-expansion">Path expansion</a>).  This option
and &lsquo;<samp>--format</samp>&rsquo; are mutually exclusive.  To output the complete
directory expansion of a path, instead of doing a one-shot lookup, see
&lsquo;<samp>--expand-path</samp>&rsquo; and &lsquo;<samp>--show-path</samp>&rsquo; in the following section.
</p>
</dd>
<dt>&lsquo;<samp>--progname=<var>name</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dprogname_003dname"></span>
<p>Set the program name to <var>name</var>; default is &lsquo;<samp>kpsewhich</samp>&rsquo;.  This
can affect the search paths via the &lsquo;<samp>.<var>prognam</var></samp>&rsquo; feature in
configuration files (see <a href="#Config-files">Config files</a>).
</p>
</dd>
<dt>&lsquo;<samp>--subdir=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dsubdir_003dstring"></span>
<p>Report only those matches whose directory part <em>ends</em> with
<var>string</var> (compared literally, except case is ignored on a
case-insensitive operating system).  For example, suppose there are
two matches for a given name:
</p>
<div class="example">
<pre class="example">kpsewhich foo.sty
&rArr; /some/where/foo.sty
/another/place/foo.sty
</pre></div>

<p>Then we can narrow the result to what we are interested in with
<samp>--subdir</samp>:
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=where foo.sty
&rArr; /some/where/foo.sty

kpsewhich --subdir=place foo.sty
&rArr; /another/place/foo.sty
</pre></div>

<p>The string to match must be at the end of the directory part of the
match, and it is taken literally, with no pattern matching:
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=another foo.sty
&rArr;
</pre></div>

<p>The string to match may cross directory components:
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=some/where foo.sty
&rArr; /some/where/foo.sty
</pre></div>

<p><samp>--subdir</samp> implies <samp>--all</samp>; if there is more than one
match, they will all be reported (in our example, both &lsquo;<samp>where</samp>&rsquo;
and &lsquo;<samp>place</samp>&rsquo; end in &lsquo;<samp>e</samp>&rsquo;):
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=e
&rArr; /some/where/foo.sty
/another/place/foo.sty
</pre></div>

<p>Because of the above rules, the presence of a leading &lsquo;<samp>/</samp>&rsquo; is
important, since it &ldquo;anchors&rdquo; the match to a full component name:
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=/lace foo.sty
&rArr;
</pre></div>

<p>However, a trailing &lsquo;<samp>/</samp>&rsquo; is immaterial (and ignored), since the
match always takes place at the end of the directory part:
</p>
<div class="example">
<pre class="example">kpsewhich --subdir=lace/ foo.sty
&rArr; /another/place/foo.sty
</pre></div>

<p>The purpose of these rules is to make it convenient to find results
only within a particular area of the tree.  For instance, a given
script named <samp>foo.lua</samp> might exist within both
<samp>texmf-dist/scripts/pkg1/</samp> and <samp>texmf-dist/scripts/pkg2/</samp>.
By specifying, say, &lsquo;<samp>--subdir=/pkg1</samp>&rsquo;, you can be sure of getting
the one you are interested in.
</p>
<p>We only match at the end because a site might happen to install TeX
in <samp>/some/coincidental/pkg1/path/</samp>, and we wouldn&rsquo;t want to match
<samp>texmf-dist/scripts/pkg2/</samp> that when searching for &lsquo;<samp>/pkg1</samp>&rsquo;.
</p>
</dd>
</dl>


<hr>
<span id="Specially_002drecognized-files"></span><div class="header">
<p>
Next: <a href="#Auxiliary-tasks" accesskey="n" rel="next">Auxiliary tasks</a>, Previous: <a href="#Path-searching-options" accesskey="p" rel="prev">Path searching options</a>, Up: <a href="#Invoking-kpsewhich" accesskey="u" rel="up">Invoking kpsewhich</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Specially_002drecognized-files-for-kpsewhich"></span><h4 class="subsection">5.6.2 Specially-recognized files for <code>kpsewhich</code></h4>

<p><code>kpsewhich</code> recognizes a few special filenames on the command
line and defaults to using the &lsquo;known&rsquo; file formats for them, merely
to save the time and trouble of specifying the format.  This is only a
feature of <code>kpsewhich</code>; when using the Kpathsea library
itself, none of these special filenames are recognized, and it&rsquo;s still
up to the caller to specify the desired format.
</p>
<p>Here is the list of special filenames to <code>kpsewhich</code>, along
with their corresponding format:
</p>
<dl compact="compact">
<dd>
<span id="index-config_002eps"></span>
</dd>
<dt><samp>config.ps</samp></dt>
<dd><p><code>dvips config</code>
</p>
<span id="index-dvipdfmx_002ecfg"></span>
</dd>
<dt><samp>dvipdfmx.cfg</samp></dt>
<dd><p>&lsquo;<samp>other text files</samp>&rsquo;
</p>
<span id="index-fmtutil_002ecnf"></span>
</dd>
<dt><samp>fmtutil.cnf</samp></dt>
<dd><p>&lsquo;<samp>web2c files</samp>&rsquo;
</p>
<span id="index-glyphlist_002etxt"></span>
</dd>
<dt><samp>glyphlist.txt</samp></dt>
<dd><p>&lsquo;<samp>map</samp>&rsquo;
</p>
<span id="index-mktex_002ecnf"></span>
</dd>
<dt><samp>mktex.cnf</samp></dt>
<dd><p>&lsquo;<samp>web2c files</samp>&rsquo;
</p>
<span id="index-pdfglyphlist_002etxt"></span>
</dd>
<dt><samp>pdfglyphlist.txt</samp></dt>
<dd><p>&lsquo;<samp>map</samp>&rsquo;
</p>
<span id="index-pdftex_002ecfg"></span>
<span id="index-pdftexconfig_002etex"></span>
</dd>
<dt><samp>pdftex.cfg</samp></dt>
<dd><p>&lsquo;<samp>pdftex config</samp>&rsquo; (although <samp>pdftex.cfg</samp> is not used any more;
look for the file <samp>pdftexconfig.tex</samp> instead.)
</p>
<span id="index-texmf_002ecnf"></span>
</dd>
<dt><samp>texmf.cnf</samp></dt>
<dd><p>&lsquo;<samp>cnf</samp>&rsquo;
</p>
<span id="index-XDvi"></span>
</dd>
<dt><samp>XDvi</samp></dt>
<dd><p>&lsquo;<samp>other text files</samp>&rsquo;
</p>
</dd>
</dl>

<p>A user-specified format will override the above defaults.
</p>
<span id="index-tcfmgr_002emap"></span>
<p>Another useful configuration file in this regard is <samp>tcfmgr.map</samp>,
found in <samp>texmf/texconfig/tcfmgr.map</samp>, which records various
information about the above configuration files (among others).
</p>

<hr>
<span id="Auxiliary-tasks"></span><div class="header">
<p>
Next: <a href="#Standard-options" accesskey="n" rel="next">Standard options</a>, Previous: <a href="#Specially_002drecognized-files" accesskey="p" rel="prev">Specially-recognized files</a>, Up: <a href="#Invoking-kpsewhich" accesskey="u" rel="up">Invoking kpsewhich</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Auxiliary-tasks-1"></span><h4 class="subsection">5.6.3 Auxiliary tasks</h4>

<span id="index-auxiliary-tasks"></span>

<p>Kpsewhich provides some features in addition to path lookup as such:
</p>
<dl compact="compact">
<dt>&lsquo;<samp>--debug=<var>num</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002ddebug_003dnum"></span>
<p>Set debugging options to <var>num</var>.  See <a href="#Debugging">Debugging</a>.
</p>
</dd>
<dt>&lsquo;<samp>--expand-braces=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dexpand_002dbraces_003dstring"></span>
<p>Output variable, tilde, and brace expansion of <var>string</var>, which is
assumed to be a single path element.  See <a href="#Path-expansion">Path expansion</a>.
</p>
</dd>
<dt>&lsquo;<samp>--expand-path=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dexpand_002dpath_003dstring"></span>
<p>Output the complete expansion of <var>string</var>, with each element
separated by the usual path separator on the current system (&lsquo;<samp>;</samp>&rsquo;
on Windows, &lsquo;<samp>:</samp>&rsquo; otherwise).  This may be useful to construct a
custom search path for a format not otherwise supported.  To retrieve
the search path for a format that is already supported, see
&lsquo;<samp>--show-path</samp>&rsquo;.
</p>
<p>Nonexistent directories are culled from the output:
</p>
<div class="example">
<pre class="example">$ kpsewhich --expand-path '/tmp'
&rArr; /tmp
$ kpsewhich --expand-path '/nonesuch'
&rArr;
</pre></div>

<p>For one-shot uses of an arbitrary (not built in to Kpathsea) path, see
&lsquo;<samp>--path</samp>&rsquo; (see <a href="#Path-searching-options">Path searching options</a>).
</p>
</dd>
<dt>&lsquo;<samp>--expand-var=<var>string</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dexpand_002dvar_003dstring"></span>
<p>Output the variable and tilde expansion of <var>string</var>.  For example,
with the usual <samp>texmf.cnf</samp>, &lsquo;<samp>kpsewhich
--expand-var='$TEXMF'</samp>&rsquo; returns the TeX system hierarchy root(s).
See <a href="#Path-expansion">Path expansion</a>.  The specified <var>string</var> can contain
anything, though, not just variable references.  This calls
<code>kpse_var_expand</code> (see <a href="#Programming-with-config-files">Programming with config files</a>).
</p>
</dd>
<dt>&lsquo;<samp>--help-formats</samp>&rsquo;</dt>
<dd><span id="index-_002d_002dhelp_002dformats"></span>
<p>Output information about each supported format (see <a href="#Supported-file-formats">Supported file formats</a>), including the names and abbreviations, variables
looked for, and the original path.
</p>
</dd>
<dt>&lsquo;<samp>--safe-in-name=<var>name</var></samp>&rsquo;</dt>
<dt>&lsquo;<samp>--safe-out-name=<var>name</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dsafe_002din_002dname_003dname"></span>
<span id="index-_002d_002dsafe_002dout_002dname_003dname"></span>
<p>Exit successfully if <var>name</var> is safe to open for reading or
writing, respectively, else unsuccessfully.  No output is written.
These tests take account of the related Kpathsea configuration
settings (see <a href="#Calling-sequence">Calling sequence</a>).
</p>
</dd>
<dt>&lsquo;<samp>--show-path=<var>name</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dshow_002dpath_003dname"></span>
<p>Show the path that would be used for file lookups of file type
<var>name</var>.  Either a filename extension (&lsquo;<samp>pk</samp>&rsquo;, &lsquo;<samp>.vf</samp>&rsquo;, etc.)
or an integer can be used, just as with &lsquo;<samp>--format</samp>&rsquo;, described in
the previous section.
</p>
</dd>
<dt>&lsquo;<samp>--var-brace-value=<var>variable</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dvar_002dbrace_002dvalue_003dvariable"></span>
<p>Like &lsquo;<samp>--var-value</samp>&rsquo; (next), but also expands &lsquo;<samp>{...}</samp>&rsquo;
constructs.  (see <a href="#Brace-expansion">Brace expansion</a>).  Thus, the value is assumed to
possibly be several path elements, and &lsquo;<samp>~</samp>&rsquo; is expanded at the
beginning of each.  The path separator is changed to that of the
current system in the expansion.
</p>
<p>Example: &lsquo;<samp>FOO='.;~' kpsewhich --var-brace-value=FOO</samp>&rsquo; outputs (on
a Unix-ish system) &lsquo;<samp>.:/home/karl</samp>&rsquo;, supposing the latter is the
current user&rsquo;s home directory.  Note that the &lsquo;<samp>;</samp>&rsquo; in the source
value, as commonly used in <samp>texmf.cnf</samp>, has changed to a
&lsquo;<samp>:</samp>&rsquo;, as the normal path separator on the current system.  On a
Windows-ish system, the &lsquo;<samp>;</samp>&rsquo; would remain.
</p>
</dd>
<dt>&lsquo;<samp>--var-value=<var>variable</var></samp>&rsquo;</dt>
<dd><span id="index-_002d_002dvar_002dvalue_003dvariable"></span>
<p>Outputs the value of <var>variable</var> (a simple identifier like
&lsquo;<samp>TEXMFDIST</samp>&rsquo;, with no &lsquo;<samp>$</samp>&rsquo; or other constructs), expanding
&lsquo;<samp>$</samp>&rsquo; (see <a href="#Variable-expansion">Variable expansion</a>) and &lsquo;<samp>~</samp>&rsquo; (see <a href="#Tilde-expansion">Tilde expansion</a>) constructs in the value.  &lsquo;<samp>~</samp>&rsquo; expansion happens at the
beginning of the overall value and at the beginning of a variable
expansion, but not arbitrarily within the string.  Braces are not expanded.
</p>
<p>Example: &lsquo;<samp>--var-value=texmf_casefold_search</samp>&rsquo; outputs (if the
default is not changed) &lsquo;<samp>1</samp>&rsquo;.
</p>
<p>Example to contrast with &lsquo;<samp>--var-brace-value</samp>&rsquo;: &lsquo;<samp>FOO='.;~'
kpsewhich --var-value=FOO</samp>&rsquo; outputs &lsquo;<samp>.;~</samp>&rsquo;, i.e., the same as the
input value, on all systems.
</p>
</dd>
</dl>


<hr>
<span id="Standard-options"></span><div class="header">
<p>
Previous: <a href="#Auxiliary-tasks" accesskey="p" rel="prev">Auxiliary tasks</a>, Up: <a href="#Invoking-kpsewhich" accesskey="u" rel="up">Invoking kpsewhich</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Standard-options-1"></span><h4 class="subsection">5.6.4 Standard options</h4>

<span id="index-standard-options"></span>

<p>Kpsewhich accepts the standard GNU options:
</p>
<ul>
<li> <span id="index-_002d_002dhelp"></span>
&lsquo;<samp>--help</samp>&rsquo; prints a help message on standard output and exits
successfully.

</li><li> <span id="index-_002d_002dversion"></span>
&lsquo;<samp>--version</samp>&rsquo; prints the Kpathsea version number and exits successfully.
</li></ul>


<hr>
<span id="TeX-support"></span><div class="header">
<p>
Next: <a href="#Programming" accesskey="n" rel="next">Programming</a>, Previous: <a href="#Path-searching" accesskey="p" rel="prev">Path searching</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="TeX-support-1"></span><h2 class="chapter">6 TeX support</h2>

<span id="index-TeX-support"></span>

<p>Although the basic features in Kpathsea can be used for any type of
path searching, it came about, as usual, with a specific application
in mind: I wrote Kpathsea specifically for TeX system programs.  I
had been struggling with the programs I was using (Dvips, Xdvi, and
TeX itself) having slightly different notions of how to specify
paths; and debugging was painful, since no code was shared.
</p>
<p>Therefore, Kpathsea provides some TeX-specific formats and
features.  Indeed, many of the purportedly generic path searching
features were provided because they seemed useful in that conTeXt
(font lookup, particularly).
</p>
<p>Kpathsea provides a standard way to search for files of any of the
supported file types; glyph fonts are a bit different than all the
rest.  Searches are based solely on names of files, not their
contents&mdash;if a GF file is (mis)named <samp>cmr10.600pk</samp>, it will be
found as a PK file.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Supported-file-formats" accesskey="1">Supported file formats</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">File types Kpathsea knows about.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#File-lookup" accesskey="2">File lookup</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Searching for most kinds of files.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Glyph-lookup" accesskey="3">Glyph lookup</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Searching for bitmap fonts.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Suppressing-warnings" accesskey="4">Suppressing warnings</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Avoiding warnings via TEX_HUSH.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#mktex-scripts" accesskey="5">mktex scripts</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Generating files at runtime.
</td></tr>
</table>


<hr>
<span id="Supported-file-formats"></span><div class="header">
<p>
Next: <a href="#File-lookup" accesskey="n" rel="next">File lookup</a>, Up: <a href="#TeX-support" accesskey="u" rel="up">TeX support</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Supported-file-formats-1"></span><h3 class="section">6.1 Supported file formats</h3>

<span id="index-supported-file-formats"></span>
<span id="index-file-formats_002c-supported"></span>

<span id="index-environment-variables-for-TeX"></span>
<span id="index-TeX-environment-variables"></span>

<p>Kpathsea has support for a number of file types.  Each file type has a
list of environment and config file variables that are checked to define
the search path, and most have a default suffix that plays a role in
finding files (see the next section).  Some also define additional
suffixes, and/or a program to be run to create missing files on the fly.
</p>
<span id="index-program_002dvarying-paths"></span>
<p>Since environment variables containing periods, such as
&lsquo;<samp>TEXINPUTS.latex</samp>&rsquo;, are not allowed on some systems, Kpathsea looks
for environment variables with an underscore, e.g.,
&lsquo;<samp>TEXINPUTS_latex</samp>&rsquo; (see <a href="#Config-files">Config files</a>).
</p>
<p>The following table lists the above information.  You can also get the
list by giving the &lsquo;<samp>--help-formats</samp>&rsquo; option to <code>kpsewhich</code>
(see <a href="#Auxiliary-tasks">Auxiliary tasks</a>).
</p>
<dl compact="compact">
<dt>&lsquo;<samp>afm</samp>&rsquo;</dt>
<dd><span id="index-_002eafm"></span>
<span id="index-AFMFONTS"></span>
<p>(Adobe font metrics, see <a href="https://tug.org/texinfohtml/dvips.html#Metric-files">Metric files</a> in <cite>Dvips</cite>)
<code>AFMFONTS</code>;
suffix &lsquo;<samp>.afm</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>base</samp>&rsquo;</dt>
<dd><span id="index-_002ebase"></span>
<span id="index-MFBASES"></span>
<span id="index-TEXMFINI"></span>
<p>(Metafont memory dump, see <a href="https://tug.org/texinfohtml/web2c.html#Memory-dumps">Memory dumps</a> in <cite>Web2c</cite>)
<code>MFBASES</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.base</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>bib</samp>&rsquo;</dt>
<dd><span id="index-_002ebib"></span>
<span id="index-BIBINPUTS"></span>
<span id="index-TEXBIB"></span>
<p>(BibTeX bibliography source, see <a href="https://tug.org/texinfohtml/web2c.html#bibtex-invocation">bibtex invocation</a> in <cite>Web2c</cite>)
<code>BIBINPUTS</code>, <code>TEXBIB</code>;
suffix &lsquo;<samp>.bib</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>bltxml</samp>&rsquo;</dt>
<dd><span id="index-_002ebltxml"></span>
<span id="index-BLTXMLINPUTS"></span>
<p>(BibLaTeXML bibliography files for Biber, <a href="https://ctan.org/pkg/biber">https://ctan.org/pkg/biber</a>)
<code>BLTXMLINPUTS</code>
suffix &lsquo;<samp>.bltxml</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>bst</samp>&rsquo;</dt>
<dd><span id="index-_002ebst"></span>
<span id="index-BSTINPUTS"></span>
<p>(BibTeX style, see <a href="https://tug.org/texinfohtml/web2c.html#Basic-BibTeX-style-files">Basic BibTeX
style files</a> in <cite>Web2c</cite>)
<code>BSTINPUTS</code>;
suffix &lsquo;<samp>.bst</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>clua</samp>&rsquo;</dt>
<dd><span id="index-_002edll"></span>
<span id="index-_002eso"></span>
<span id="index-CLUAINPUTS"></span>
<p>(dynamic libraries for Lua, <a href="https://ctan.org/pkg/luatex">https://ctan.org/pkg/luatex</a>)
<code>CLUAINPUTS</code>
suffixes &lsquo;<samp>.dll</samp>&rsquo; and &lsquo;<samp>.so</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>cmap</samp>&rsquo;</dt>
<dd><span id="index-_002ecmap"></span>
<span id="index-CMAPFONTS"></span>
<p>(character map files)
<code>CMAPFONTS</code>;
suffix &lsquo;<samp>.cmap</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>cnf</samp>&rsquo;</dt>
<dd><span id="index-_002ecnf"></span>
<span id="index-TEXMFCNF-1"></span>
<p>(Runtime configuration files, see <a href="#Config-files">Config files</a>)
<code>TEXMFCNF</code>;
suffix &lsquo;<samp>.cnf</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>cweb</samp>&rsquo;</dt>
<dd><span id="index-_002ew"></span>
<span id="index-_002eweb"></span>
<span id="index-CWEBINPUTS"></span>
<p>(CWEB input files)
<code>CWEBINPUTS</code>;
suffixes &lsquo;<samp>.w</samp>&rsquo;, &lsquo;<samp>.web</samp>&rsquo;;
additional suffix &lsquo;<samp>.ch</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>dvips config</samp>&rsquo;</dt>
<dd><span id="index-TEXCONFIG"></span>
<span id="index-config_002eps_002c-search-path-for"></span>
<p>(Dvips &lsquo;<samp>config.*</samp>&rsquo; files, such as <samp>config.ps</samp>, see <a href="https://tug.org/texinfohtml/dvips.html#Config-files">Config
files</a> in <cite>Dvips</cite>)
<code>TEXCONFIG</code>.
</p>
</dd>
<dt>&lsquo;<samp>enc files</samp>&rsquo;</dt>
<dd><span id="index-_002eenc"></span>
<span id="index-ENCFONTS"></span>
<p>(encoding vectors)
<code>ENCFONTS</code>;
suffix &lsquo;<samp>.enc</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>fmt</samp>&rsquo;</dt>
<dd><span id="index-_002efmt"></span>
<span id="index-TEXFORMATS"></span>
<span id="index-TEXMFINI-1"></span>
<p>(TeX memory dump, see <a href="https://tug.org/texinfohtml/web2c.html#Memory-dumps">Memory dumps</a> in <cite>Web2c</cite>)
<code>TEXFORMATS</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.fmt</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>font cid map</samp>&rsquo;</dt>
<dd><span id="index-_002ecid"></span>
<span id="index-FONTCIDMAPS"></span>
<p>(CJK mapping)
<code>FONTCIDMAPS</code>
suffix &lsquo;<samp>.cid</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>font feature files</samp>&rsquo;</dt>
<dd><span id="index-_002efea"></span>
<span id="index-FONTFEATURES"></span>
<p>(primarily for OpenType font features)
<code>FONTFEATURES</code>
suffix &lsquo;<samp>.fea</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>gf</samp>&rsquo;</dt>
<dd><span id="index-gf"></span>
<span id="index-GFFONTS"></span>
<span id="index-GLYPHFONTS"></span>
<span id="index-TEXFONTS"></span>
<p>(generic font bitmap, see <a href="https://tug.org/texinfohtml/dvips.html#Glyph-files">Glyph files</a> in <cite>Dvips</cite>)
<code><var>program</var>FONTS</code>, <code>GFFONTS</code>, <code>GLYPHFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>gf</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>graphic/figure</samp>&rsquo;</dt>
<dd><span id="index-_002eeps"></span>
<span id="index-_002eepsi"></span>
<span id="index-TEXPICTS"></span>
<span id="index-TEXINPUTS"></span>
<p>(Encapsulated PostScript figures, see <a href="https://tug.org/texinfohtml/dvips.html#PostScript-figures">PostScript figures</a> in <cite>Dvips</cite>)
<code>TEXPICTS</code>, <code>TEXINPUTS</code>;
additional suffixes: &lsquo;<samp>.eps</samp>&rsquo;, &lsquo;<samp>.epsi</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ist</samp>&rsquo;</dt>
<dd><span id="index-_002eist"></span>
<span id="index-TEXINDEXSTYLE"></span>
<span id="index-INDEXSTYLE"></span>
<p>(makeindex style files)
<code>TEXINDEXSTYLE</code>, <code>INDEXSTYLE</code>;
suffix &lsquo;<samp>.ist</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>lig files</samp>&rsquo;</dt>
<dd><span id="index-_002elig"></span>
<span id="index-LIGFONTS"></span>
<p>(ligature definition files)
<code>LIGFONTS</code>;
suffix &lsquo;<samp>.lig</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ls-R</samp>&rsquo;</dt>
<dd><span id="index-ls_002dR"></span>
<span id="index-TEXMFDBS-1"></span>
<p>(Filename databases, see <a href="#Filename-database">Filename database</a>)
<code>TEXMFDBS</code>.
</p>
</dd>
<dt>&lsquo;<samp>map</samp>&rsquo;</dt>
<dd><span id="index-_002emap"></span>
<span id="index-TEXFONTMAPS"></span>
<p>(Fontmaps, see <a href="#Fontmap">Fontmap</a>)
<code>TEXFONTMAPS</code>;
suffix &lsquo;<samp>.map</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>mem</samp>&rsquo;</dt>
<dd><span id="index-_002emem"></span>
<span id="index-MPMEMS"></span>
<span id="index-TEXMFINI-2"></span>
<p>(MetaPost memory dump, see <a href="https://tug.org/texinfohtml/web2c.html#Memory-dumps">Memory dumps</a> in <cite>Web2c</cite>)
<code>MPMEMS</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.mem</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp><span class="roman">MetaPost support</span></samp>&rsquo;</dt>
<dd><span id="index-MPSUPPORT"></span>
<p>(MetaPost support files, used by DMP; see <a href="https://tug.org/texinfohtml/web2c.html#dmp-invocation">dmp invocation</a> in <cite>Web2c</cite>)
<code>MPSUPPORT</code>.
</p>
</dd>
<dt>&lsquo;<samp>mf</samp>&rsquo;</dt>
<dd><span id="index-_002emf"></span>
<span id="index-MFINPUTS"></span>
<p>(Metafont source, see <a href="https://tug.org/texinfohtml/web2c.html#mf-invocation">mf invocation</a> in <cite>Web2c</cite>)
<code>MFINPUTS</code>;
suffix &lsquo;<samp>.mf</samp>&rsquo;;
dynamic creation program: <code>mktexmf</code>.
</p>
</dd>
<dt>&lsquo;<samp>mfpool</samp>&rsquo;</dt>
<dd><span id="index-_002epool"></span>
<span id="index-MFPOOL"></span>
<p>(Metafont program strings, see <a href="https://tug.org/texinfohtml/web2c.html#pooltype-invocation">pooltype invocation</a> in <cite>Web2c</cite>)
<code>MFPOOL</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.pool</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>mft</samp>&rsquo;</dt>
<dd><span id="index-_002emft"></span>
<span id="index-MFTINPUTS"></span>
<p>(<code>MFT</code> style file, see <a href="https://tug.org/texinfohtml/web2c.html#mft-invocation">mft invocation</a> in <cite>Web2c</cite>)
<code>MFTINPUTS</code>;
suffix &lsquo;<samp>.mft</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>misc fonts</samp>&rsquo;</dt>
<dd><span id="index-MISCFONTS"></span>
<p>(font-related files that don&rsquo;t fit the other categories)
<code>MISCFONTS</code>
</p>
</dd>
<dt>&lsquo;<samp>mlbib</samp>&rsquo;</dt>
<dd><span id="index-_002emlbib"></span>
<span id="index-MLBIBINPUTS"></span>
<span id="index-BIBINPUTS-1"></span>
<span id="index-TEXBIB-1"></span>
<p>(MlBibTeX bibliography source)
<code>MLBIBINPUTS</code>, <code>BIBINPUTS</code>, <code>TEXBIB</code>;
suffixes &lsquo;<samp>.mlbib</samp>&rsquo;, &lsquo;<samp>.mlbib</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>mlbst</samp>&rsquo;</dt>
<dd><span id="index-_002emlbst"></span>
<span id="index-MLBSTINPUTS"></span>
<span id="index-BSTINPUTS-1"></span>
<p>(MlBibTeX style)
<code>MLBSTINPUTS</code>, <code>BSTINPUTS</code>;
suffixes &lsquo;<samp>.mlbst</samp>&rsquo;, &lsquo;<samp>.bst</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>mp</samp>&rsquo;</dt>
<dd><span id="index-_002emp"></span>
<span id="index-MPINPUTS"></span>
<p>(MetaPost source, see <a href="https://tug.org/texinfohtml/web2c.html#mpost-invocation">mpost invocation</a> in <cite>Web2c</cite>)
<code>MPINPUTS</code>;
suffix &lsquo;<samp>.mp</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>mppool</samp>&rsquo;</dt>
<dd><span id="index-_002epool-1"></span>
<span id="index-MPPOOL"></span>
<p>(MetaPost program strings, see <a href="https://tug.org/texinfohtml/web2c.html#pooltype-invocation">pooltype invocation</a> in <cite>Web2c</cite>)
<code>MPPOOL</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.pool</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ocp</samp>&rsquo;</dt>
<dd><span id="index-_002eocp"></span>
<span id="index-OCPINPUTS"></span>
<p>(Omega compiled process files)
<code>OCPINPUTS</code>; <br>
suffix &lsquo;<samp>.ocp</samp>&rsquo;;
dynamic creation program: <code>MakeOmegaOCP</code>.
</p>
</dd>
<dt>&lsquo;<samp>ofm</samp>&rsquo;</dt>
<dd><span id="index-_002eofm"></span>
<span id="index-OFMFONTS"></span>
<p>(Omega font metrics)
<code>OFMFONTS</code>, <code>TEXFONTS</code>; <br>
suffixes &lsquo;<samp>.ofm</samp>&rsquo;, &lsquo;<samp>.tfm</samp>&rsquo;;
dynamic creation program: <code>MakeOmegaOFM</code>.
</p>
</dd>
<dt>&lsquo;<samp>opentype fonts</samp>&rsquo;</dt>
<dd><span id="index-OPENTYPEFONTS"></span>
<p>(OpenType fonts)
<code>OPENTYPEFONTS</code>.
</p>
</dd>
<dt>&lsquo;<samp>opl</samp>&rsquo;</dt>
<dd><span id="index-_002eopl"></span>
<p>(Omega property lists)
<code>OPLFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>.opl</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>otp</samp>&rsquo;</dt>
<dd><span id="index-_002eotp"></span>
<span id="index-OTPINPUTS"></span>
<p>(Omega translation process files)
<code>OTPINPUTS</code>;
suffix &lsquo;<samp>.otp</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ovf</samp>&rsquo;</dt>
<dd><span id="index-_002eovf"></span>
<span id="index-OVFFONTS"></span>
<p>(Omega virtual fonts)
<code>OVFFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>.ovf</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ovp</samp>&rsquo;</dt>
<dd><span id="index-_002eovp"></span>
<span id="index-OVPFONTS"></span>
<p>(Omega virtual property lists)
<code>OVPFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>.ovp</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>pdftex config</samp>&rsquo;</dt>
<dd><span id="index-PDFTEXCONFIG"></span>
<p>(PDFTeX-specific configuration files)
<code>PDFTEXCONFIG</code>.
</p>
</dd>
<dt>&lsquo;<samp>pk</samp>&rsquo;</dt>
<dd><span id="index-_002epk"></span>
<span id="index-PKFONTS"></span>
<span id="index-TEXPKS"></span>
<span id="index-GLYPHFONTS-1"></span>
<span id="index-TEXFONTS-1"></span>
<p>(packed bitmap fonts, see <a href="https://tug.org/texinfohtml/dvips.html#Glyph-files">Glyph files</a> in <cite>Dvips</cite>)
<code><var>PROGRAM</var>FONTS</code> (<var>program</var> being &lsquo;<samp>XDVI</samp>&rsquo;, etc.),
<code>PKFONTS</code>, <code>TEXPKS</code>, <code>GLYPHFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>pk</samp>&rsquo;;
dynamic creation program: <code>mktexpk</code>.
</p>
</dd>
<dt>&lsquo;<samp>PostScript header</samp>&rsquo;</dt>
<dd><span id="index-_002epro"></span>
<span id="index-TEXPSHEADERS"></span>
<span id="index-PSHEADERS"></span>
<p>(downloadable PostScript, see <a href="https://tug.org/texinfohtml/dvips.html#Header-files">Header files</a> in <cite>Dvips</cite>)
<code>TEXPSHEADERS</code>, <code>PSHEADERS</code>;
additional suffix &lsquo;<samp>.pro</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>ris</samp>&rsquo;</dt>
<dd><span id="index-_002eris"></span>
<span id="index-RISINPUTS"></span>
<p>(RIS bibliography files, primarily for Biber, <a href="https://ctan.org/pkg/biber">https://ctan.org/pkg/biber</a>)
<code>RISINPUTS</code>
suffix &lsquo;<samp>.ris</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>subfont definition files</samp>&rsquo;</dt>
<dd><span id="index-_002esfd"></span>
<span id="index-SFDFONTS"></span>
<p>(subfont definition files)
<code>SFDFONTS</code>
suffix &lsquo;<samp>.sfd</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>tex</samp>&rsquo;</dt>
<dd><span id="index-_002etex"></span>
<span id="index-TEXINPUTS-1"></span>
<p>(TeX source, see <a href="https://tug.org/texinfohtml/web2c.html#tex-invocation">tex invocation</a> in <cite>Web2c</cite>)
<code>TEXINPUTS</code>;
suffix &lsquo;<samp>.tex</samp>&rsquo;;
additional suffixes: none, because such a list cannot be complete;
dynamic creation program: <code>mktextex</code>.
</p>
</dd>
<dt>&lsquo;<samp>TeX system documentation</samp>&rsquo;</dt>
<dd><span id="index-doc-files"></span>
<span id="index-TEXDOCS"></span>
<p>(Documentation files for the TeX system)
<code>TEXDOCS</code>.
</p>
</dd>
<dt>&lsquo;<samp>TeX system sources</samp>&rsquo;</dt>
<dd><span id="index-source-files"></span>
<span id="index-TEXSOURCES"></span>
<p>(Source files for the TeX system)
<code>TEXSOURCES</code>.
</p>
</dd>
<dt>&lsquo;<samp>texmfscripts</samp>&rsquo;</dt>
<dd><span id="index-TEXMFSCRIPTS"></span>
<p>(Architecture-independent executables distributed in the texmf trees)
<code>TEXMFSCRIPTS</code>.
</p>
</dd>
<dt>&lsquo;<samp>texpool</samp>&rsquo;</dt>
<dd><span id="index-_002epool-2"></span>
<span id="index-TEXPOOL"></span>
<p>(TeX program strings, see <a href="https://tug.org/texinfohtml/web2c.html#pooltype-invocation">pooltype invocation</a> in <cite>Web2c</cite>)
<code>TEXPOOL</code>, <code>TEXMFINI</code>;
suffix &lsquo;<samp>.pool</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>tfm</samp>&rsquo;</dt>
<dd><span id="index-_002etfm"></span>
<span id="index-TFMFONTS"></span>
<span id="index-TEXFONTS-2"></span>
<p>(TeX font metrics, see <a href="https://tug.org/texinfohtml/dvips.html#Metric-files">Metric files</a> in <cite>Dvips</cite>)
<code>TFMFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>.tfm</samp>&rsquo;;
dynamic creation program: <code>mktextfm</code>.
</p>
</dd>
<dt>&lsquo;<samp>Troff fonts</samp>&rsquo;</dt>
<dd><span id="index-TRFONTS"></span>
<p>(Troff fonts, used by DMP; see <a href="https://tug.org/texinfohtml/web2c.html#DMP-invocation">DMP invocation</a> in <cite>Web2c</cite>)
<code>TRFONTS</code>.
</p>
</dd>
<dt>&lsquo;<samp>truetype fonts</samp>&rsquo;</dt>
<dd><span id="index-_002ettf"></span>
<span id="index-_002ettc"></span>
<span id="index-TTFONTS"></span>
<p>(TrueType outline fonts) <code>TTFONTS</code>; suffixes &lsquo;<samp>.ttf</samp>&rsquo; and
&lsquo;<samp>.TTF</samp>&rsquo;, &lsquo;<samp>.ttc</samp>&rsquo; and &lsquo;<samp>.TTC</samp>&rsquo;, &lsquo;<samp>.dfont</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>type1 fonts</samp>&rsquo;</dt>
<dd><span id="index-_002epfa"></span>
<span id="index-_002epfb"></span>
<span id="index-T1FONTS"></span>
<span id="index-T1INPUTS"></span>
<span id="index-TEXPSHEADERS-1"></span>
<span id="index-DVIPSHEADERS"></span>
<p>(Type 1 PostScript outline fonts, see <a href="https://tug.org/texinfohtml/dvips.html#Glyph-files">Glyph files</a> in <cite>Dvips</cite>)
<code>T1FONTS</code>, <code>T1INPUTS</code>, <code>TEXPSHEADERS</code>, <code>DVIPSHEADERS</code>;
suffixes &lsquo;<samp>.pfa</samp>&rsquo;, &lsquo;<samp>.pfb</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>type42 fonts</samp>&rsquo;</dt>
<dd><span id="index-T42FONTS"></span>
<p>(Type 42 PostScript outline fonts) <code>T42FONTS</code>.
</p>
</dd>
<dt>&lsquo;<samp>vf</samp>&rsquo;</dt>
<dd><span id="index-_002evf"></span>
<span id="index-VFFONTS"></span>
<span id="index-TEXFONTS-3"></span>
<p>(virtual fonts, see <a href="https://tug.org/texinfohtml/dvips.html#Virtual-fonts">Virtual fonts</a> in <cite>Dvips</cite>)
<code>VFFONTS</code>, <code>TEXFONTS</code>;
suffix &lsquo;<samp>.vf</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>web</samp>&rsquo;</dt>
<dd><span id="index-_002eweb-1"></span>
<span id="index-WEBINPUTS"></span>
<p>(WEB input files)
<code>WEBINPUTS</code>;
suffix &lsquo;<samp>.web</samp>&rsquo;;
additional suffix &lsquo;<samp>.ch</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>web2c files</samp>&rsquo;</dt>
<dd><span id="index-WEB2C"></span>
<p>(files specific to the web2c implementation)
<code>WEB2C</code>.
</p></dd>
</dl>

<p>There are two special cases, because the paths and environment variables
always depend on the name of the program: the variable name is
constructed by converting the program name to upper case, and then
appending &lsquo;<samp>INPUTS</samp>&rsquo;.  Assuming the program is called &lsquo;<samp>foo</samp>&rsquo;,
this gives us the following table.
</p>
<dl compact="compact">
<dt>&lsquo;<samp>other text files</samp>&rsquo;</dt>
<dd><span id="index-FOOINPUTS"></span>
<p>(text files used by &lsquo;<samp>foo</samp>&rsquo;)
<code>FOOINPUTS</code>.
</p>
</dd>
<dt>&lsquo;<samp>other binary files</samp>&rsquo;</dt>
<dd><span id="index-FOOINPUTS-1"></span>
<p>(binary files used by &lsquo;<samp>foo</samp>&rsquo;)
<code>FOOINPUTS</code>.
</p></dd>
</dl>

<p>If an environment variable by these names are set, the corresponding
<samp>texmf.cnf</samp> definition won&rsquo;t be looked at (unless, as usual, the
environment variable value has an extra &lsquo;<samp>:</samp>&rsquo;).  See <a href="#Default-expansion">Default expansion</a>.
</p>
<p>For the font variables, the intent is that:
</p><ul>
<li> <code>TEXFONTS</code> is the default for everything.

</li><li> <code>GLYPHFONTS</code> is the default for bitmap (or, more precisely,
non-metric) files.

</li><li> Each font format has a variable of its own.

</li><li> <span id="index-XDVIFONTS"></span>
<span id="index-DVIPSFONTS"></span>
Each program has its own font override path as well; e.g.,
<code>DVIPSFONTS</code> for Dvipsk.  Again, this is for bitmaps, not metrics.

</li></ul>


<hr>
<span id="File-lookup"></span><div class="header">
<p>
Next: <a href="#Glyph-lookup" accesskey="n" rel="next">Glyph lookup</a>, Previous: <a href="#Supported-file-formats" accesskey="p" rel="prev">Supported file formats</a>, Up: <a href="#TeX-support" accesskey="u" rel="up">TeX support</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="File-lookup-1"></span><h3 class="section">6.2 File lookup</h3>

<span id="index-file-lookup"></span>
<span id="index-searching-for-files"></span>
<span id="index-TeX-file-lookup"></span>

<p>This section describes how Kpathsea searches for most files (bitmap font
searches are the exception, as described in the next section).
</p>
<p>Here is the search strategy for a file <var>name</var>:
</p>
<ol>
<li> If the file format defines default suffixes, and the suffix of
<var>name</var> name is not already a known suffix for that format, try the
name with each default appended, and use alternative names found in
the fontmaps if necessary.  Example: given &lsquo;<samp>foo.bar</samp>&rsquo;, look for
&lsquo;<samp>foo.bar.tex</samp>&rsquo;.

</li><li> Search for <var>name</var>, and if necessary for alternative names found in
the fontmaps.  Example: given &lsquo;<samp>foo.bar</samp>&rsquo;, we also look for
&lsquo;<samp>foo.bar</samp>&rsquo;.

</li><li> If the file format defines a program to invoke to create missing files,
run it (see <a href="#mktex-scripts">mktex scripts</a>).
</li></ol>

<span id="index-extensions_002c-filename"></span>
<span id="index-suffixes_002c-filename"></span>
<span id="index-try_005fstd_005fextension_005ffirst"></span>
<p>The order in which we search for &ldquo;suffixed&rdquo; name (item&nbsp;1) or
the &ldquo;as-is&rdquo; name (item&nbsp;2) is controlled by the
<samp>try_std_extension_first</samp> configuration value.  The default set
in <samp>texmf.cnf</samp> is true, since common suffixes are already
recognized: &lsquo;<samp>babel.sty</samp>&rsquo; will only look for &lsquo;<samp>babel.sty</samp>&rsquo;, not
&lsquo;<samp>babel.sty.tex</samp>&rsquo;, regardless of this setting.
</p>
<p>When the suffix is unknown (e.g., &lsquo;<samp>foo.bar</samp>&rsquo;), both names are
always tried; the difference is the order in which they are tried.
</p>
<p><samp>try_std_extension_first</samp> only affects names being looked up
which *already* have an extension.  A name without an extension (e.g.,
&lsquo;<samp>tex story</samp>&rsquo;) will always have an extension added first.
</p>
<span id="index-tex_002dfile_002ec"></span>
<span id="index-kpathsea_005ffind_005ffile"></span>
<p>This algorithm is implemented in the function
<code>kpathsea_find_file</code> in the source file
<samp>kpathsea/tex-file.c</samp>.  You can watch it in action with the
debugging options (see <a href="#Debugging">Debugging</a>).
</p>

<hr>
<span id="Glyph-lookup"></span><div class="header">
<p>
Next: <a href="#Suppressing-warnings" accesskey="n" rel="next">Suppressing warnings</a>, Previous: <a href="#File-lookup" accesskey="p" rel="prev">File lookup</a>, Up: <a href="#TeX-support" accesskey="u" rel="up">TeX support</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Glyph-lookup-1"></span><h3 class="section">6.3 Glyph lookup</h3>

<span id="index-glyph-lookup"></span>
<span id="index-searching-for-glyphs"></span>
<span id="index-TeX-glyph-lookup"></span>

<p>This section describes how Kpathsea searches for a bitmap font in GF or
PK format (or either) given a font name (e.g., &lsquo;<samp>cmr10</samp>&rsquo;) and a
resolution (e.g., 600).
</p>
<p>Here is an outline of the search strategy (details in the sections
below) for a file <var>name</var> at resolution <var>dpi</var>.  The search stops
at the first successful lookup.
</p>
<ol>
<li> Look for an existing file <var>name</var>.<var>dpi</var><var>format</var> in the
specified format(s).

</li><li> If <var>name</var> is an alias for a file <var>f</var> in the fontmap
file <samp>texfonts.map</samp>, look for <var>f</var>.<var>dpi</var>.

</li><li> Run an external program (typically named &lsquo;<samp>mktexpk</samp>&rsquo;) to
generate the font (see <a href="#mktex-scripts">mktex scripts</a>)

</li><li> Look for <var>fallback</var>.<var>dpi</var>, where <var>fallback</var> is some
last-resort font (typically &lsquo;<samp>cmr10</samp>&rsquo;).
</li></ol>

<span id="index-tex_002dglyph_002ec"></span>
<span id="index-kpathsea_005ffind_005fglyph"></span>
<p>This is implemented in <code>kpathsea_find_glyph</code> in
<samp>kpathsea/tex-glyph.c</samp>.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Basic-glyph-lookup" accesskey="1">Basic glyph lookup</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Features common to all glyph lookups.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Fontmap" accesskey="2">Fontmap</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Aliases for fonts.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Fallback-font" accesskey="3">Fallback font</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Resolutions and fonts of last resort.
</td></tr>
</table>


<hr>
<span id="Basic-glyph-lookup"></span><div class="header">
<p>
Next: <a href="#Fontmap" accesskey="n" rel="next">Fontmap</a>, Up: <a href="#Glyph-lookup" accesskey="u" rel="up">Glyph lookup</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Basic-glyph-lookup-1"></span><h4 class="subsection">6.3.1 Basic glyph lookup</h4>

<span id="index-basic-glyph-lookup"></span>
<span id="index-common-features-in-glyph-lookup"></span>

<p>When Kpathsea looks for a bitmap font <var>name</var> at resolution <var>dpi</var>
in a format <var>format</var>, it first checks each directory in the search
path for a file &lsquo;<samp><var>name</var>.<var>dpi</var><var>format</var></samp>&rsquo;; for example,
&lsquo;<samp>cmr10.600pk</samp>&rsquo;.  Kpathsea looks for a PK file first, then a GF file.
</p>
<p>If that fails, Kpathsea looks for
&lsquo;<samp>dpi<var>dpi</var>/<var>name</var>.<var>format</var></samp>&rsquo;; for example,
&lsquo;<samp>dpi600/cmr10.pk</samp>&rsquo;. This is how fonts are typically stored on
filesystems (such as DOS) that permit only three-character extensions.
</p>
<span id="index-tolerance-for-glyph-lookup"></span>
<span id="index-glyph-lookup-bitmap-tolerance"></span>
<span id="index-KPSE_005fBITMAP_005fTOLERANCE"></span>
<p>If that fails, Kpathsea looks for a font with a close-enough <var>dpi</var>.
&ldquo;Close enough&rdquo; is defined by the macro <code>KPSE_BITMAP_TOLERANCE</code> in
<samp>kpathsea/tex-glyph.h</samp> to be <code><var>dpi</var> / 500 + 1</code>.  This is
slightly more than the 0.2% minimum allowed by the DVI standard
(<a href="CTAN:/dviware/driv-standard/level-0">CTAN:/dviware/driv-standard/level-0</a>).
</p>

<hr>
<span id="Fontmap"></span><div class="header">
<p>
Next: <a href="#Fallback-font" accesskey="n" rel="next">Fallback font</a>, Previous: <a href="#Basic-glyph-lookup" accesskey="p" rel="prev">Basic glyph lookup</a>, Up: <a href="#Glyph-lookup" accesskey="u" rel="up">Glyph lookup</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Fontmap-1"></span><h4 class="subsection">6.3.2 Fontmap</h4>

<span id="index-fontmap-files"></span>
<span id="index-font-alias-files"></span>
<span id="index-aliases-for-fonts"></span>

<span id="index-texfonts_002emap"></span>
<p>If a bitmap font or metric file is not found with the original name (see
the previous section), Kpathsea looks through any <em>fontmap</em> files
for an <em>alias</em> for the original font name.  These files are named
<samp>texfonts.map</samp> and searched for along the <code>TEXFONTMAPS</code>
environment/config file variable.  All <samp>texfonts.map</samp> files that
are found are read; earlier definitions override later ones.
</p>
<p>This feature is intended to help in two respects:
</p>
<ol>
<li> <span id="index-fontnames_002c-arbitrary-length"></span>
An alias name is limited in length only by available memory, not by your
filesystem.  Therefore, if you want to ask for &lsquo;<samp>Times-Roman</samp>&rsquo;
instead of <samp>ptmr</samp>, you can (you get &lsquo;<samp>ptmr8r</samp>&rsquo;).

</li><li> <span id="index-circle-fonts"></span>
<span id="index-lcircle10"></span>
A few fonts have historically had multiple names: specifically,
LaTeX&rsquo;s &ldquo;circle font&rdquo; has variously been known as <samp>circle10</samp>,
<samp>lcircle10</samp>, and <samp>lcirc10</samp>.  Aliases can make all the names
equivalent, so that it no longer matters what the name of the installed
file is; TeX documents will find their favorite name.

</li></ol>

<p>The format of fontmap files is straightforward:
</p>
<ul>
<li> <span id="index-comments_002c-in-fontmap-files"></span>
Comments start with the last &lsquo;<samp>%</samp>&rsquo; on a line and continue to
the end of the line. (This provides for names that include a %,
ill-advised as that may be.)

</li><li> <span id="index-whitespace_002c-in-fontmap-files"></span>
Blank lines are ignored.

</li><li> Each nonblank line is broken up into a series of <em>words</em>:
  a sequence of non-whitespace characters.

</li><li> <span id="index-include-fontmap-directive"></span>
If the first word is &lsquo;<samp>include</samp>&rsquo;, the second word is used as
  a filename, and it is searched for and read.

</li><li> Otherwise, the first word on each line is the true filename;

</li><li> the second word is the alias;

</li><li> subsequent words are ignored.
</li></ul>

<p>If an alias has an extension, it matches only those files with that
extension; otherwise, it matches anything with the same root, regardless
of extension.  For example, an alias &lsquo;<samp>foo.tfm</samp>&rsquo; matches only when
<samp>foo.tfm</samp> is being searched for; but an alias &lsquo;<samp>foo</samp>&rsquo; matches
<samp>foo.vf</samp>, <samp>foo.600pk</samp>, etc.
</p>
<p>As an example, here is an excerpt from the <samp>texfonts.map</samp> in the
Web2c distribution.  It makes the old and new names of the LaTeX
circle fonts equivalent.
</p>
<div class="example">
<pre class="example">circle10        lcircle10
circle10        lcirc10
lcircle10       circle10
lcircle10       lcirc10
lcirc10         circle10
lcirc10         lcircle10
&hellip;
</pre></div>

<p>Fontmaps are implemented in the file <samp>kpathsea/fontmap.c</samp>.
The Fontname distribution has much more information on font naming
(see <cite><a href="fontname.html#Top">Filenames for TeX fonts</a></cite>).
</p>

<hr>
<span id="Fallback-font"></span><div class="header">
<p>
Previous: <a href="#Fontmap" accesskey="p" rel="prev">Fontmap</a>, Up: <a href="#Glyph-lookup" accesskey="u" rel="up">Glyph lookup</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Fallback-font-1"></span><h4 class="subsection">6.3.3 Fallback font</h4>

<span id="index-fallback-font"></span>
<span id="index-fallback-resolutions"></span>
<span id="index-font-of-last-resort"></span>
<span id="index-resolutions_002c-last_002dresort"></span>
<span id="index-last_002dresort-font"></span>

<span id="index-DVIPSSIZES"></span>
<span id="index-XDVISIZES"></span>
<span id="index-DVILJSIZES"></span>
<span id="index-TEXSIZES"></span>
<span id="index-default_005ftexsizes"></span>
<p>If a bitmap font cannot be found or created at the requested size,
Kpathsea looks for the font at a set of <em>fallback resolutions</em>.  You
specify these resolutions as a colon-separated list (like search paths).
Kpathsea looks first for a program-specific environment variable (e.g.,
<code>DVIPSSIZES</code> for Dvipsk), then the environment variable
<code>TEXSIZES</code>, then a default specified at compilation time (the Make
variable <code>default_texsizes</code>).  You can set this list to be empty if
you prefer to find fonts at their stated size or not at all.
</p>
<span id="index-cmr10_002c-as-fallback-font"></span>
<span id="index-kpathsea_005finit_005fprog"></span>
<p>Finally, if the font cannot be found even at the fallback resolutions,
Kpathsea looks for a fallback font, typically <samp>cmr10</samp>.  Programs
must enable this feature by  calling <code>kpathsea_init_prog</code>
(see <a href="#Calling-sequence">Calling sequence</a>); the default is no fallback font.
</p>

<hr>
<span id="Suppressing-warnings"></span><div class="header">
<p>
Next: <a href="#mktex-scripts" accesskey="n" rel="next">mktex scripts</a>, Previous: <a href="#Glyph-lookup" accesskey="p" rel="prev">Glyph lookup</a>, Up: <a href="#TeX-support" accesskey="u" rel="up">TeX support</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Suppressing-warnings-1"></span><h3 class="section">6.4 Suppressing warnings</h3>

<span id="index-warnings_002c-suppressing"></span>
<span id="index-suppressing-warnings"></span>

<span id="index-TEX_005fHUSH-1"></span>
<p>Kpathsea provides a way to suppress selected usually-harmless warnings;
this is useful at large sites where most users are not administrators,
and thus the warnings are merely a source of confusion, not a help.  To
do this, you set the environment variable or configuration file value
<code>TEX_HUSH</code> to a colon-separated list of values.  Here are the
possibilities:
</p>
<dl compact="compact">
<dt>&lsquo;<samp>all</samp>&rsquo;
<span id="index-all"></span>
</dt>
<dd><p>Suppress everything possible.
</p>
</dd>
<dt>&lsquo;<samp>checksum</samp>&rsquo;
<span id="index-checksum"></span>
</dt>
<dd><span id="index-mismatched-checksum-warnings"></span>
<p>Suppress mismatched font checksum warnings.
</p>
</dd>
<dt>&lsquo;<samp>lostchar</samp>&rsquo;
<span id="index-lostchar"></span>
</dt>
<dd><span id="index-missing-character-warnings"></span>
<p>Suppress warnings when a character is missing from a font that a DVI or
VF file tries to typeset.
</p>
</dd>
<dt>&lsquo;<samp>none</samp>&rsquo;
<span id="index-none"></span>
</dt>
<dd><p>Don&rsquo;t suppress any warnings.
</p>
</dd>
<dt>&lsquo;<samp>readable</samp>&rsquo;
<span id="index-readable"></span>
</dt>
<dd><span id="index-unreadable-file-warnings"></span>
<p>Suppress warnings about attempts to access a file whose permissions
render it unreadable.
</p>
</dd>
<dt>&lsquo;<samp>special</samp>&rsquo;
<span id="index-special"></span>
</dt>
<dd><span id="index-unknown-special-warnings"></span>
<span id="index-_005cspecial_002c-suppressing-warnings-about"></span>
<p>Suppresses warnings about an unimplemented or unparsable
&lsquo;<samp>\special</samp>&rsquo; command.
</p></dd>
</dl>

<p><samp>tex-hush.c</samp> defines the function that checks the
variable value.  Each driver implements its own checks where
appropriate.
</p>

<hr>
<span id="mktex-scripts"></span><div class="header">
<p>
Previous: <a href="#Suppressing-warnings" accesskey="p" rel="prev">Suppressing warnings</a>, Up: <a href="#TeX-support" accesskey="u" rel="up">TeX support</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="mktex-scripts-1"></span><h3 class="section">6.5 <samp>mktex</samp> scripts</h3>

<span id="index-mktex-scripts"></span>
<span id="index-scripts-for-file-creation"></span>

<span id="index-font-set_002c-infinite"></span>
<span id="index-dynamic-creation-of-files"></span>
<span id="index-Sauter-fonts_002c-and-dynamic-source-creation"></span>
<span id="index-EC-fonts_002c-and-dynamic-source-creation"></span>
<p>If Kpathsea cannot otherwise find a file, for some file types it is
configured by default to invoke an external program to create it
dynamically (see <a href="#mktex-configuration">mktex configuration</a>).  These are collectively
known as <em><code>mktex</code> scripts</em>, since most of them are named
<code>mktex...</code>.
</p>
<p>For example, this is useful for fonts (bitmaps, TFM&rsquo;s, and
arbitrarily-sizable Metafont sources such as the Sauter and EC fonts),
since any given document can use fonts never before referenced.
Building all fonts in advance is therefore impractical, if not
impossible.
</p>
<p>It is also useful for the TeX &lsquo;<samp>.fmt</samp>&rsquo; (and Metafont
&lsquo;<samp>.base</samp>&rsquo; and Metapost &lsquo;<samp>.mem</samp>&rsquo; files, see <a href="Web2c.html#Memory-dumps">Memory
dumps</a> in <cite>web2c</cite>), where pre-generating every format consumes a
lot of both time and space.
</p>
<p>The script is passed the name of the file to create and possibly other
arguments, as explained below.  It must echo the full pathname of the
file it created (and nothing else) to standard output; it can write
diagnostics to standard error.
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#mktex-configuration" accesskey="1">config</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#mktex-script-names" accesskey="2">names</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#mktex-script-arguments" accesskey="3">args</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
</td></tr>
</table>


<hr>
<span id="mktex-configuration"></span><div class="header">
<p>
Next: <a href="#mktex-script-names" accesskey="n" rel="next">mktex script names</a>, Up: <a href="#mktex-scripts" accesskey="u" rel="up">mktex scripts</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="mktex-configuration-1"></span><h4 class="subsection">6.5.1 <samp>mktex</samp> configuration</h4>

<span id="index-mktex-script-configuration"></span>
<span id="index-configuration-of-mktex-scripts"></span>
<span id="index-enabling-mktex-scripts"></span>
<span id="index-disabling-mktex-scripts"></span>

<p>The list of file types and program names that can run an external
program to create missing files is listed in the next section.  In the
absence of <code>configure</code> options specifying otherwise, everything
but <samp>mktextex</samp> will be enabled by default.  The <code>configure</code>
options to change the defaults are:
</p>
<span id="index-configure-options-for-mktex-scripts"></span>
<span id="index-_002d_002dwithout_002dmktexfmt_002ddefault"></span>
<span id="index-_002d_002dwithout_002dmktexmf_002ddefault"></span>
<span id="index-_002d_002dwithout_002dmktexocp_002ddefault"></span>
<span id="index-_002d_002dwithout_002dmktexofm_002ddefault"></span>
<span id="index-_002d_002dwithout_002dmktexpk_002ddefault"></span>
<span id="index-_002d_002dwithout_002dmktextfm_002ddefault"></span>
<span id="index-_002d_002dwith_002dmktextex_002ddefault"></span>
<div class="example">
<pre class="example">--without-mktexfmt-default
--without-mktexmf-default
--without-mktexocp-default
--without-mktexofm-default
--without-mktexpk-default
--without-mktextfm-default
--with-mktextex-default
</pre></div>

<p>The <code>configure</code> setting is overridden if the environment variable
or configuration file value named for the script is set; e.g.,
<samp>MKTEXPK</samp> (see <a href="#mktex-script-arguments">mktex script arguments</a>).
</p>
<span id="index-fmtutils_002ecnf"></span>
<p><code>mktexfmt</code> reads a file <samp>fmtutil.cnf</samp>, typically located in
<samp>texmf/web2c/</samp> to glean its configuration information.  The rest
of the files and features in this section are primarily intended for
the font generation scripts.
</p>
<span id="index-mktex_002ecnf-1"></span>
<span id="index-mktex_002eopt"></span>
<span id="index-site-overrides-for-mktex_2026"></span>
<p>As distributed, all the scripts source a file
<samp>texmf/web2c/mktex.cnf</samp> if it exists, so you can override various
defaults.  
See <samp>mktex.opt</samp>, for instance, which defines the default mode,
resolution, some special directory names, etc.  If you prefer not to
change the distributed scripts, you can simply create <samp>mktex.cnf</samp>
with the appropriate definitions (you do not need to create it if you
have nothing to put in it).  <samp>mktex.cnf</samp> has no special syntax;
it&rsquo;s an arbitrary Bourne shell script.  The distribution contains a
sample <samp>mktex.cnf</samp> for you to copy and modify as you please (it
is not installed anywhere).
</p>
<span id="index-mktex_002eopt-1"></span>
<span id="index-MT_005fFEATURES"></span>
<p>In addition, you can configure a number of features with the
<code>MT_FEATURES</code> variable, which you can define:
</p>
<ul>
<li> in <samp>mktex.opt</samp>, as just mentioned;

</li><li> by editing the file <samp>mktex.opt</samp>, either before &lsquo;<samp>make
install</samp>&rsquo; (in the source hierarchy) or after (in the installed
hierarchy);

</li><li> or in the environment.
</li></ul>

<p>If none of the options below are enabled, <code>mktexpk</code>,
<code>mktextfm</code>, and <code>mktexmf</code> follow the following procedure to
decide where fonts should be installed.  Find the tree where the font&rsquo;s
sources are, and test the permissions of the &lsquo;<samp>fonts</samp>&rsquo; directory of
that tree to determine whether it is writable.  If it is, put the files
in the tree in appropriate locations.  If it isn&rsquo;t writable, see whether
the tree is a system tree (named in <code>SYSTEXMF</code>).  If so, the
<code>VARTEXFONTS</code> tree is used.  In all other cases the working
directory is used.
</p>
<p>The &lsquo;<samp>appendonlydir</samp>&rsquo; option is enabled by default.
</p>
<dl compact="compact">
<dt>&lsquo;<samp>appendonlydir</samp>&rsquo;
<span id="index-appendonlydir"></span>
</dt>
<dd><span id="index-directories_002c-making-append_002donly"></span>
<span id="index-mktexdir"></span>
<p>Tell <code>mktexdir</code> to create directories append-only, i.e., set
their sticky bit (see <a href="https://www.gnu.org/software/coreutils/manual/coreutils#Mode-Structure">Mode Structure</a> in <cite>GNU Core
Utilities</cite>).  This feature is silently ignored on non-Unix platforms
(e.g. Windows/NT and MS-DOS) which don&rsquo;t support similar functionality.
This feature is enabled by default.
</p>
</dd>
<dt>&lsquo;<samp>dosnames</samp>&rsquo;
<span id="index-dosnames"></span>
</dt>
<dd><span id="index-8_002e3-filenames_002c-using"></span>
<span id="index-DOS-compatible-names"></span>
<span id="index-dpinnn-directories"></span>
<p>Use 8.3 names; e.g., <samp>dpi600/cmr10.pk</samp> instead of
<samp>cmr10.600pk</samp>.  Note that this feature only affects filenames that
would otherwise clash with other TeX-related filenames; <samp>mktex</samp>
scripts do nothing about filenames which exceed the 8+3 MS-DOS limits
but remain unique when truncated (by the OS) to these limits, and nether
do the scripts care about possible clashes with files which aren&rsquo;t
related with TeX.  For example, <samp>cmr10.600pk</samp> would clash with
<samp>cmr10.600gf</samp> and is therefore changed when &lsquo;<samp>dosnames</samp>&rsquo; is in
effect, but <samp>mf.pool</samp> and <samp>mp.base</samp> don&rsquo;t clash with any
TeX-related files and are therefore unchanged.
</p>
<p>This feature is turned on by default on MS-DOS.  If you do not wish
&lsquo;<samp>dosnames</samp>&rsquo; to be set on an MS-DOS platform, you need to set the
<code>MT_FEATURES</code> environment variable to a value that doesn&rsquo;t include
&lsquo;<samp>dosnames</samp>&rsquo;.  You can also change the default setting by editing
<samp>mktex.opt</samp>, but only if you use the <samp>mktex</samp> shell scripts;
the emulation programs don&rsquo;t consult <samp>mktex.opt</samp>.
</p>
</dd>
<dt>&lsquo;<samp>fontmaps</samp>&rsquo;
<span id="index-fontmaps-1"></span>
</dt>
<dd><span id="index-fontmaps"></span>
<span id="index-fontname"></span>
<p>Instead of deriving the location of a font in the destination tree from
the location of the sources, the aliases and directory names from the
Fontname distribution are used. (see <a href="fontname.html#Top">Introduction</a> in <cite>Fontname</cite>).
</p>
</dd>
<dt>&lsquo;<samp>nomfdrivers</samp>&rsquo;
<span id="index-nomfdrivers"></span>
</dt>
<dd><span id="index-metafont-driver-files"></span>
<p>Let mktexpk and mktextfm create metafont driver files in a temporary
directory.  These will be used for just one metafont run and not
installed permanently.
</p>
</dd>
<dt>&lsquo;<samp>nomode</samp>&rsquo;
<span id="index-nomode"></span>
</dt>
<dd><span id="index-mode-directory_002c-omitting"></span>
<p>Omit the directory level for the mode name; this is fine as long as
you generate fonts for only one mode.
</p>
</dd>
<dt>&lsquo;<samp>stripsupplier</samp>&rsquo;
<span id="index-stripsupplier"></span>
</dt>
<dd><span id="index-supplier-directory_002c-omitting"></span>
<p>Omit the font supplier name directory level.
</p>
</dd>
<dt>&lsquo;<samp>striptypeface</samp>&rsquo;
<span id="index-striptypeface"></span>
</dt>
<dd><span id="index-typeface-directory_002c-omitting"></span>
<p>Omit the font typeface name directory level.
</p>
</dd>
<dt>&lsquo;<samp>strip</samp>&rsquo;
<span id="index-strip"></span>
</dt>
<dd><span id="index-supplier-directory_002c-omitting-1"></span>
<span id="index-typeface-directory_002c-omitting-1"></span>
<p>Omit the font supplier and typeface name directory levels.  This feature
is deprecated in favour of &lsquo;<samp>stripsupplier</samp>&rsquo; and &lsquo;<samp>striptypeface</samp>&rsquo;.
</p>
</dd>
<dt>&lsquo;<samp>varfonts</samp>&rsquo;
<span id="index-varfonts"></span>
</dt>
<dd><span id="index-_002fvar_002ftmp_002ftexfonts"></span>
<span id="index-VARTEXFONTS"></span>
<span id="index-Linux-File-System-Standard"></span>
<p>When this option is enabled, fonts that would otherwise be written in
system texmf tree go to the <code>VARTEXFONTS</code> tree instead.  The
default value in <samp>kpathsea/Makefile.in</samp> is
<samp>/var/tmp/texfonts</samp>.  The <cite>Linux File System Standard</cite>
recommends <samp>/var/tex/fonts</samp>.
</p>
<span id="index-USE_005fVARTEXFONTS"></span>
<p>The &lsquo;<samp>varfonts</samp>&rsquo; setting in <code>MT_FEATURES</code> is overridden by the
<code>USE_VARTEXFONTS</code> environment variable: if set to &lsquo;<samp>1</samp>&rsquo;, the
feature is enabled, and if set to &lsquo;<samp>0</samp>&rsquo;, the feature is disabled.
</p>
</dd>
<dt>&lsquo;<samp>texmfvar</samp>&rsquo;
<span id="index-texmfvar"></span>
</dt>
<dd><span id="index-TEXMFVAR"></span>
<p>Force generated files that would go into a system tree (as defined by
<code>SYSTEXMF</code>) into <code>TEXMFVAR</code>. Starting with teTeX-3.0, the
variable <code>TEXMFVAR</code> is always set.  The &lsquo;<samp>varfonts</samp>&rsquo; feature takes
precedence if also set.
</p>
<span id="index-USE_005fTEXMFVAR"></span>
<p>The &lsquo;<samp>texmfvar</samp>&rsquo; setting in <code>MT_FEATURES</code> is overridden by the
<code>USE_TEXMFVAR</code> environment variable: if set to &lsquo;<samp>1</samp>&rsquo;, the
feature is enabled, and if set to &lsquo;<samp>0</samp>&rsquo;, the feature is disabled.
</p></dd>
</dl>


<hr>
<span id="mktex-script-names"></span><div class="header">
<p>
Next: <a href="#mktex-script-arguments" accesskey="n" rel="next">mktex script arguments</a>, Previous: <a href="#mktex-configuration" accesskey="p" rel="prev">mktex configuration</a>, Up: <a href="#mktex-scripts" accesskey="u" rel="up">mktex scripts</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="mktex-script-names-1"></span><h4 class="subsection">6.5.2 <samp>mktex</samp> script names</h4>

<span id="index-mktex-script-names"></span>
<span id="index-names-for-mktex-scripts"></span>

<p>The following table shows the default name of the script for each
of the file types which support runtime generation.
</p>
<dl compact="compact">
<dt><samp>mktexfmt</samp></dt>
<dd><span id="index-mktexfmt"></span>
<span id="index-fmtutil"></span>
<p>(&lsquo;<samp>.fmt</samp>&rsquo;, &lsquo;<samp>.base</samp>&rsquo;, &lsquo;<samp>.mem</samp>&rsquo;) TeX/Metafont/MetaPost
formats.  This script is also named <code>fmtutil</code>, and reads
<samp>fmtutil.cnf</samp> for configuration information.
</p>
</dd>
<dt><samp>mktexmf</samp></dt>
<dd><span id="index-mktexmf"></span>
<p>(&lsquo;<samp>.mf</samp>&rsquo;) Metafont input files.
</p>
</dd>
<dt><samp>mkocp</samp></dt>
<dd><span id="index-mkocp"></span>
<p>(&lsquo;<samp>.ocp</samp>&rsquo;) Omega compiled process files.
</p>
</dd>
<dt><samp>mkofm</samp></dt>
<dd><span id="index-mkofm"></span>
<p>(&lsquo;<samp>.ofm</samp>&rsquo;) Omega font metric files.
</p>
</dd>
<dt><samp>mktexpk</samp></dt>
<dd><span id="index-mktexpk"></span>
<p>(&lsquo;<samp>pk</samp>&rsquo;) Glyph fonts.
</p>
</dd>
<dt><samp>mktextex</samp></dt>
<dd><span id="index-mktextex"></span>
<p>(&lsquo;<samp>.tex</samp>&rsquo;) TeX input files (disabled by default).
</p>
</dd>
<dt><samp>mktextfm</samp></dt>
<dd><span id="index-mktextfm"></span>
<p>(&lsquo;<samp>.tfm</samp>&rsquo;) TFM files.
</p></dd>
</dl>

<span id="index-DVIPSMAKEPK"></span>
<span id="index-XDVIMAKEPK"></span>
<span id="index-DVILJMAKEPK"></span>
<p>These names can be overridden by an environment variable specific
to the program&mdash;for example, <code>DVIPSMAKEPK</code> for Dvipsk.
</p>
<span id="index-missfont_002elog"></span>
<span id="index-failed-mktex_2026-script-invocation"></span>
<p>If a <code>mktex&hellip;</code> script fails, the invocation is appended to a
file <samp>missfont.log</samp> (by default) in the current directory.  You can
then execute the log file to create the missing files after fixing the
problem.
</p>
<span id="index-TEXMFOUTPUT"></span>
<span id="index-MISSFONT_005fLOG"></span>
<p>If the current directory is not writable and the environment variable or
configuration file value <code>TEXMFOUTPUT</code> is set, its value is
used.  Otherwise, nothing is written.  The name &lsquo;<samp>missfont.log</samp>&rsquo; is
overridden by the <code>MISSFONT_LOG</code> environment variable or
configuration file value.
</p>

<hr>
<span id="mktex-script-arguments"></span><div class="header">
<p>
Previous: <a href="#mktex-script-names" accesskey="p" rel="prev">mktex script names</a>, Up: <a href="#mktex-scripts" accesskey="u" rel="up">mktex scripts</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="mktex-script-arguments-1"></span><h4 class="subsection">6.5.3 <samp>mktex</samp> script arguments</h4>

<span id="index-arguments-to-mktex"></span>

<p>The first argument to a <samp>mktex</samp> script is always the name
of the file to be created.
</p>
<p>In the default <samp>mktexpk</samp> implementation, additional arguments may
also be passed:
</p>
<dl compact="compact">
<dt>&lsquo;<samp>--dpi <var>num</var></samp>&rsquo;</dt>
<dd><p>Sets the resolution of the generated font to <var>num</var>.
</p></dd>
<dt>&lsquo;<samp>--mfmode <var>name</var></samp>&rsquo;</dt>
<dd><p>Sets the Metafont mode to <var>name</var>.
</p></dd>
<dt>&lsquo;<samp>--bdpi <var>num</var></samp>&rsquo;</dt>
<dd><p>Sets the &ldquo;base dpi&rdquo; for the font.  This must match the mode being
used.
</p></dd>
<dt>&lsquo;<samp>--mag <var>string</var></samp>&rsquo;</dt>
<dd><p>A &ldquo;magstep&rdquo; string suitable for the Metafont <code>mag</code> variable.
This must match the combination of <var>bdpi</var> and <var>dpi</var> being used.
</p></dd>
<dt>&lsquo;<samp>--destdir <var>string</var></samp>&rsquo;</dt>
<dd><p>A directory name. If the directory is absolute, it is used as-is.
Otherwise, it is appended to the root destination directory set in the
script.
</p></dd>
</dl>


<hr>
<span id="Programming"></span><div class="header">
<p>
Next: <a href="#Reporting-bugs" accesskey="n" rel="next">Reporting bugs</a>, Previous: <a href="#TeX-support" accesskey="p" rel="prev">TeX support</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Programming-1"></span><h2 class="chapter">7 Programming</h2>

<p>This chapter is for programmers who wish to use Kpathsea.
See <a href="#Introduction">Introduction</a>, for the conditions under which you may do so (in
short, it is released under LGPLv2.1 or later).
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Programming-overview" accesskey="1">Overview</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Introduction.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Calling-sequence" accesskey="2">Calling sequence</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Specifics of what to call.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Program_002dspecific-files" accesskey="3">Program-specific files</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">How to handle these.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Programming-with-config-files" accesskey="4">Config</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Getting info from texmf.cnf.
</td></tr>
</table>


<hr>
<span id="Programming-overview"></span><div class="header">
<p>
Next: <a href="#Calling-sequence" accesskey="n" rel="next">Calling sequence</a>, Up: <a href="#Programming" accesskey="u" rel="up">Programming</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Programming-overview-1"></span><h3 class="section">7.1 Programming overview</h3>

<span id="index-programming-overview"></span>
<span id="index-overview-of-programming-with-Kpathsea"></span>

<p>Aside from this manual, your best source of information is the source
to the programs that use Kpathsea (see <a href="#Introduction">Introduction</a>).  First,
Kpsewhich is a small utility program whose sole purpose is to exercise
the main path-searching functionality.  Of the drivers, Dviljk is
probably the simplest full application program.  Xdvik adds VF support
and the complication of X resources.  Dvipsk adds the complication of
its own config files.  Web2c is source code I also maintain, so it
uses Kpathsea rather straightforwardly, but is of course complicated
by the Web to C translation.
</p>
<span id="index-re_002dentrant-API"></span>
<span id="index-API_002c-re_002dentrant"></span>
<p>When looking at these program sources, you should know that previous
versions of the library had a different programming interface; the
current interface supports re-entrancy.  Historically, the library
function names were prefixed with <code>kpse_</code> instead of
<code>kpathsea_</code>, and they did not need an instance variable as first
argument.  This change was made in 2009.  The old functions will never
disappear, and can reliably continue to be used when they suffice, as
they do for the programs above.  The main application using the
re-entrant API is the MetaPost library used by MetaPost and LuaTeX.
</p>
<span id="index-pathsearch_002eh"></span>
<span id="index-tex_002dfile_002eh"></span>
<span id="index-tex_002dglyph_002eh"></span>
<span id="index-kpathsea_002eh"></span>
<p>Beyond these examples, the <samp>.h</samp> files in the Kpathsea source
describe the interfaces and functionality (and of course the <samp>.c</samp>
files define the actual routines, which are the ultimate documentation).
<samp>pathsearch.h</samp> declares the basic searching routine.
<samp>tex-file.h</samp> and <samp>tex-glyph.h</samp> define the interfaces for
looking up particular kinds of files.  In view of the way the headers
depend on each other, it is recommended to use <code>#include
&lt;kpathsea/kpathsea.h&gt;</code>, which includes every Kpathsea header.
</p>
<span id="index-config_002eh"></span>
<span id="index-c_002dauto_002eh"></span>
<p>If you want to include only specific headers, you should still consider
including <samp>kpathsea/config.h</samp> before including any other Kpathsea
header, as it provides symbols used in the other headers.  Note that
<samp>kpathsea/config.h</samp> includes <samp>kpathsea/c-auto.h</samp>, which is
generated by Autoconf.
</p>
<span id="index-file-types_002c-registering-new"></span>
<p>The library provides no way for an external program to register new file
types: <samp>tex-file.[ch]</samp> must be modified to do this. For example,
Kpathsea has support for looking up Dvips config files, even though no
program other than Dvips will likely ever want to do so.  I felt this
was acceptable, since along with new file types should also come new
defaults in <samp>texmf.cnf</samp> (and its descendant <samp>paths.h</samp>), since
it&rsquo;s simplest for users if they can modify one configuration file for
all kinds of paths.
</p>
<p>Kpathsea does not parse any formats itself; it barely opens any files.
Its primary purpose is to return filenames.  The GNU font utilities does
contain libraries to read TFM, GF, and PK files, as do the programs
above, of course.
</p>

<hr>
<span id="Calling-sequence"></span><div class="header">
<p>
Next: <a href="#Program_002dspecific-files" accesskey="n" rel="next">Program-specific files</a>, Previous: <a href="#Programming-overview" accesskey="p" rel="prev">Programming overview</a>, Up: <a href="#Programming" accesskey="u" rel="up">Programming</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Calling-sequence-1"></span><h3 class="section">7.2 Calling sequence</h3>

<span id="index-programming-with-Kpathsea"></span>
<span id="index-calling-sequence"></span>

<p>The typical way to use Kpathsea in your program goes something like this:
</p>
<ol>
<li> <span id="index-kpathsea_005fnew"></span>
Call <code>kpathsea_new</code> to create a new library instance. This variable
must be passed as the first argument to all the following library functions.
The rest of this manual will be using <code>kpse</code> as a placeholder for
the name of this variable.

</li><li> <span id="index-kpathsea_005fset_005fprogram_005fname"></span>
<span id="index-argv_005b0_005d"></span>
Call <code>kpathsea_set_program_name</code> with <code>argv[0]</code> as the second
argument; the third argument is a string or <code>NULL</code>.  The third
argument is used by Kpathsea as the program name for the
<code>.<var>program</var></code> feature of config files (see <a href="#Config-files">Config files</a>).
If the third argument is <code>NULL</code>, the value of the second argument
is used.  This function must be called before any other use of the
Kpathsea library.

<span id="index-kpse_002d_003einvocation_005fname"></span>
<span id="index-kpse_002d_003einvocation_005fshort_005fname"></span>
<span id="index-kpse_002d_003eprogram_005fname"></span>
<span id="index-error-message-macros"></span>
<p><code>kpathsea_set_program_name</code> always sets the variables
<code>kpse-&gt;invocation_name</code> and <code>kpse-&gt;invocation_short_name</code>.
These variables are used in the error message macros defined in
<samp>kpathsea/lib.h</samp>.  It sets the variable
<code>kpse-&gt;program_name</code> to the program name it uses.
</p>
<span id="index-KPATHSEA_005fDEBUG"></span>
<p>It also initializes debugging options based on the environment
variable <code>KPATHSEA_DEBUG</code> (if that is set).
</p>
<span id="index-SELFAUTOLOC"></span>
<span id="index-SELFAUTODIR"></span>
<span id="index-SELFAUTOPARENT"></span>
<span id="index-symlinks_002c-resolving"></span>
<span id="index-expanding-symlinks"></span>
<p>Finally, it sets the environment variables <code>SELFAUTOLOC</code>, <code>SELFAUTODIR</code>
and <code>SELFAUTOPARENT</code> to the location, parent and grandparent
directory of the executable, removing <samp>.</samp> and <samp>..</samp> path
elements and resolving symbolic links.  These are used in the default
configuration file to allow people to invoke TeX from anywhere.  You
can use &lsquo;<samp>kpsewhich --expand-var=\$SELFAUTOLOC</samp>&rsquo;, etc., to see the
values.
</p>
</li><li> <span id="index-kpse_002d_003edebug-variable"></span>
<span id="index-debugging-options_002c-in-Kpathsea_002dusing-program"></span>
Set debugging options. See <a href="#Debugging">Debugging</a>.  If your program doesn&rsquo;t have a
debugging option already, you can define one and set
<code>kpse-&gt;debug</code> to the number that the user supplies (as in Dviljk
and Web2c), or you can just omit this altogether (people can always set
<code>KPATHSEA_DEBUG</code>).  If you do have runtime debugging already, you
need to merge Kpathsea&rsquo;s options with yours (as in Dvipsk and Xdvik).

</li><li> <span id="index-client_005fpath-in-kpse_002d_003eformat_005finfo"></span>
<span id="index-kpse_002d_003eformat_005finfo"></span>
<span id="index-resident_002ec"></span>
<span id="index-config-files_002c-for-Kpathsea_002dusing-programs"></span>
If your program has its own configuration files that can define search
paths, you should assign those paths to the <code>client_path</code> member in
the appropriate element of the <code>kpse-&gt;format_info</code> array.  (This
array is indexed by file type; see <samp>tex-file.h</samp>.)  See
<samp>resident.c</samp> in Dvipsk for an example.

</li><li> <span id="index-kpathsea_005finit_005fprog-1"></span>
<span id="index-proginit_002eh"></span>
Call <code>kpathsea_init_prog</code> (see <samp>proginit.c</samp>). It&rsquo;s useful for the
DVI drivers, at least, but for other programs it may be simpler to
extract the parts of it that actually apply.  This does not initialize
any paths, it just looks for (and sets) certain environment variables
and other random information.  (A search path is always initialized at
the first call to find a file of that type; this eliminates much useless
work, e.g., initializing the BibTeX search paths in a DVI driver.)

</li><li> <span id="index-kpathsea_005ffind_005ffile-1"></span>
The routine to actually find a file of type <var>format</var> is
<samp>kpathsea_find_file</samp>.  You can call
<code>kpathsea_find_file</code> after doing only the first and second of the
initialization steps above&mdash;Kpathsea automatically reads the
<samp>texmf.cnf</samp> generic config files, looks for environment variables,
and does expansions at the first lookup.

</li><li> To find PK and/or GF bitmap fonts, the routine
is <code>kpathsea_find_glyph</code>, defined in
<samp>tex-glyph.h</samp>. This returns a structure in addition to the
resultant filename, because fonts can be found in so many ways. See the
documentation in the source.

</li><li> <span id="index-kpathsea_005fopen_005ffile"></span>
To actually open a file, not just return a filename, call
<code>kpathsea_open_file</code>.  This function takes the name to look up and a
Kpathsea file format as arguments, and returns the usual <code>FILE *</code>.
It always assumes the file must exist, and thus will search the disk if
necessary (unless the search path specified &lsquo;<samp>!!</samp>&rsquo;, etc.).  In other
words, if you are looking up a VF or some other file that need not
exist, don&rsquo;t use this.

</li><li> <span id="index-kpathsea_005fout_005fname_005fok"></span>
TeX can write output files, via the <code>\openout</code> primitive; this opens
a security hole vulnerable to Trojan horse attack: an unwitting user could
run a TeX program that overwrites, say, <samp>~/.rhosts</samp>.  Analogous
security holes exist for many other programs.  To alleviate this, there is a
configuration variable <code>openout_any</code>, which selects one of three levels
of security.  When it is set to &lsquo;<samp>a</samp>&rsquo; (for &ldquo;any&rdquo;), no restrictions are
imposed.  When it is set to &lsquo;<samp>r</samp>&rsquo; (for &ldquo;restricted&rdquo;), filenames
beginning with &lsquo;<samp>.</samp>&rsquo; are disallowed (except <samp>.tex</samp> because LaTeX
needs it).  When it is set to &lsquo;<samp>p</samp>&rsquo; (for &ldquo;paranoid&rdquo;) additional
restrictions are imposed: an absolute filename must refer to a file in (a
subdirectory) of <code>TEXMFOUTPUT</code>, and any attempt to go up a directory
level is forbidden (that is, paths may not contain a &lsquo;<samp>..</samp>&rsquo; component). 
The paranoid setting is the default.  (For backwards compatibility, &lsquo;<samp>y</samp>&rsquo;
and &lsquo;<samp>1</samp>&rsquo; are synonyms of &lsquo;<samp>a</samp>&rsquo;, while &lsquo;<samp>n</samp>&rsquo; and &lsquo;<samp>0</samp>&rsquo; are
synonyms for &lsquo;<samp>r</samp>&rsquo;.) The function <code>kpathsea_out_name_ok</code>, with a
filename as second argument, returns <code>true</code> if that filename is
acceptable to be opend for output or <code>false</code> otherwise.

</li><li> <span id="index-kpathsea_005fin_005fname_005fok"></span>
Similarly, the function <code>kpathsea_in_name_ok</code>, with a filename as
second argument, returns <code>true</code> if that filename is acceptable to be
opend for input or <code>false</code> otherwise, depending on the value of the
configuration variable <code>openin_any</code> (with &lsquo;<samp>a</samp>&rsquo; as default).

</li><li> <span id="index-kpathsea_005ffinish"></span>
To close the kpathsea library instance you are using, call
<code>kpathsea_finish</code>.  This function closes any open log files and
frees the memory used by the instance.

</li></ol>

<span id="index-hash-table-routines"></span>
<span id="index-memory-allocation-routines"></span>
<span id="index-string-routines"></span>
<span id="index-reading-arbitrary_002dlength-lines"></span>
<span id="index-input-lines_002c-reading"></span>
<span id="index-lines_002c-reading-arbitrary_002dlength"></span>
<p>Kpathsea also provides many utility routines. Some are generic: hash
tables, memory allocation, string concatenation and copying, string
lists, reading input lines of arbitrary length, etc. Others are
filename-related: default path, tilde, and variable expansion,
<code>stat</code> calls, etc. (Perhaps someday I&rsquo;ll move the former to a
separate library.)
</p>
<span id="index-c_002d_002a_002eh"></span>
<span id="index-autoconf_002c-recommended"></span>
<p>The <samp>c-*.h</samp> header files can also help your program adapt to many
different systems.  You will almost certainly want to use Autoconf and
probably Automake for configuring and building your software if you use
Kpathsea; I strongly recommend using Autoconf and Automake regardless.
They are available from <a href="https://gnu.org/software">https://gnu.org/software</a>.
</p>

<hr>
<span id="Program_002dspecific-files"></span><div class="header">
<p>
Next: <a href="#Programming-with-config-files" accesskey="n" rel="next">Programming with config files</a>, Previous: <a href="#Calling-sequence" accesskey="p" rel="prev">Calling sequence</a>, Up: <a href="#Programming" accesskey="u" rel="up">Programming</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Program_002dspecific-files-1"></span><h3 class="section">7.3 Program-specific files</h3>

<p>Many programs will need to find some configuration files.  Kpathsea
contains some support to make it easy to place them in their own
directories.  The Standard TeX directory structure (see <a href="tds.html#Top">Introduction</a> in <cite>A Directory Structure for TeX files</cite>), specifies
that such files should go into a subdirectory named after the program,
like &lsquo;<samp>texmf/ttf2pk</samp>&rsquo;.
</p>
<p>Two formats, &lsquo;<samp>kpse_program_text_format</samp>&rsquo; and
&lsquo;<samp>kpse_program_binary_format</samp>&rsquo;, use <code>.:$TEXMF/<var>program</var>//</code>
as their compiled-in search path.  To override this default, you can
use the variable <code><var>PROGRAM</var>INPUTS</code> in the environment and/or
&lsquo;<samp>texmf.cnf</samp>&rsquo;.  That is to say, the name of the variable is
constructed by converting the name of the program to upper case, and
appending <code>INPUTS</code>.
</p>
<p>The only difference between these two formats is whether
<code>kpathsea_open_file</code> will open the files it finds in text or binary
mode.
</p>

<hr>
<span id="Programming-with-config-files"></span><div class="header">
<p>
Previous: <a href="#Program_002dspecific-files" accesskey="p" rel="prev">Program-specific files</a>, Up: <a href="#Programming" accesskey="u" rel="up">Programming</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Programming-with-config-files-1"></span><h3 class="section">7.4 Programming with config files</h3>

<span id="index-programming-with-config-files"></span>
<span id="index-config-files_002c-programming-with"></span>

<p>You can (and probably should) use the same <code>texmf.cnf</code>
configuration file that Kpathsea uses for your program.  This helps
installers by keeping all configuration in one place.
</p>
<span id="index-kpathsea_005fvar_005fvalue"></span>
<span id="index-variable_002eh"></span>
<span id="index-shell_005fescape_002c-example-for-code"></span>
<p>To retrieve a value for a configuration variable <var>var</var>, the best
way is to call <code>kpathsea_var_value</code> on the string
<code><var>var</var></code>.  This will look first for an environment variable
<var>var</var>, then a config file value.  The result will be the value
found or &lsquo;<samp>NULL</samp>&rsquo;.  This function is declared in
<samp>kpathsea/variable.h</samp>.  For an example, see the
<code>shell_escape</code> code in <samp>web2c/lib/texmfmp.c</samp>.
</p>
<p>The routine to do full variable and tilde expansion of an arbitrary
string in the context of a search path (as opposed to simply
retrieving a value) is <code>kpathsea_var_expand</code>, also declared in
<samp>kpathsea/variable.h</samp>.  However, it&rsquo;s generally only necessary to
set the search path structure components as explained in the previous
section instead of using this directly.  Because of its usage with any
input string, undefined <code>$FOO</code> constructs in the argument to
<code>kpathsea_var_expand</code> are returned literally (<code>&quot;$FOO&quot;</code>),
while undefined <code>${FOO}</code> constructs are expanded to the empty
string.
</p>
<span id="index-kpathsea_005fcnf_005fget"></span>
<span id="index-cnf_002eh"></span>
<p>If for some reason you want to retrieve a value <em>only</em> from a
config file, not automatically looking for a corresponding environment
variable, call <code>kpathsea_cnf_get</code> (declared in <samp>kpathsea/cnf.h</samp>)
with the string <var>var</var>.
</p>
<p>No initialization calls are needed.
</p>

<hr>
<span id="Reporting-bugs"></span><div class="header">
<p>
Next: <a href="#Index" accesskey="n" rel="next">Index</a>, Previous: <a href="#Programming" accesskey="p" rel="prev">Programming</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Reporting-bugs-1"></span><h2 class="chapter">8 Reporting bugs</h2>

<span id="index-reporting-bugs"></span>
<span id="index-bugs_002c-reporting"></span>

<span id="index-tex_002dk_0040tug_002eorg-_0028bug-address_0029"></span>
<span id="index-bug-address"></span>
<p>If you have problems or suggestions, please report them to
<a href="mailto:tex-k@tug.org">tex-k@tug.org</a> using the bug checklist below.
</p>
<p>Please report bugs in the documentation; not only factual errors or
inconsistent behavior, but unclear or incomplete explanations, typos,
wrong fonts, &hellip;
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Bug-checklist" accesskey="1">Bug checklist</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">What to include in a good bug report.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Mailing-lists" accesskey="2">Mailing lists</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Joining the bugs or announcements mailing lists.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Debugging" accesskey="3">Debugging</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Analyzing runtime problems.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Logging" accesskey="4">Logging</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Recording searches.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Common-problems" accesskey="5">Common problems</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">When things go wrong.
</td></tr>
</table>


<hr>
<span id="Bug-checklist"></span><div class="header">
<p>
Next: <a href="#Mailing-lists" accesskey="n" rel="next">Mailing lists</a>, Up: <a href="#Reporting-bugs" accesskey="u" rel="up">Reporting bugs</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Bug-checklist-1"></span><h3 class="section">8.1 Bug checklist</h3>

<span id="index-checklist-for-bug-reports"></span>
<span id="index-bug-checklist"></span>

<p>Before reporting a bug, please check below to be sure it isn&rsquo;t already
known (see <a href="#Common-problems">Common problems</a>).
</p>
<p>Bug reports should be sent via electronic mail to
<a href="mailto:tex-k@tug.org">tex-k@tug.org</a>.
</p>
<p>The general principle is that a good bug report includes all the
information necessary for reproduction.  Therefore, to enable
investigation, your report should include the following:
</p>
<ul>
<li> <span id="index-version-numbers_002c-determining"></span>
The version number(s) of the program(s) involved, and of Kpathsea
itself.  You can get the former by giving a sole option &lsquo;<samp>--version</samp>&rsquo;
to the program, and the latter by running &lsquo;<samp>kpsewhich --version</samp>&rsquo;.
The <samp>NEWS</samp> and <samp>ChangeLog</samp> files also contain the version
number.

</li><li> <span id="index-uname"></span>
The hardware, operating system (including version), compiler, and
<code>make</code> program you are using (the output of <code>uname -a</code> is a
start on the first two, though incomplete).

</li><li> <span id="index-config_002elog"></span>
Any options you gave to <code>configure</code>.  This is recorded in the
<samp>config.status</samp> files.

<span id="index-configuration-bugs"></span>
<span id="index-config_002estatus"></span>
<p>If you are reporting a bug in &lsquo;<samp>configure</samp>&rsquo; itself, it&rsquo;s probably
system-dependent, and it will be unlikely the maintainers can do
anything useful if you merely report that thus-and-such is broken.
Therefore, you need to do some additional work: for some bugs, you can
look in the file <samp>config.log</samp> where the test that failed should
appear, along with the compiler invocation and source program in
question.  You can then compile it yourself by hand, and discover why
the test failed.  Other &lsquo;<samp>configure</samp>&rsquo; bugs do not involve the
compiler; in that case, the only recourse is to inspect the
<code>configure</code> shell script itself, or the Autoconf macros that
generated <code>configure</code>.
</p>
</li><li> The log of all debugging output, if the bug is in path searching.  You
can get this by setting the environment variable <code>KPATHSEA_DEBUG</code>
to &lsquo;<samp>-1</samp>&rsquo; before running the program.  Please look at the log
yourself to make sure the behavior is really a bug before reporting it;
perhaps &ldquo;old&rdquo; environment variable settings are causing files not to
be found, for example.

</li><li> The contents of any input files necessary to reproduce the bug.  For
bugs in DVI-reading programs, for example, this generally means a DVI
file (and any EPS or other files it uses)&mdash;TeX source files are
helpful, but the DVI file is required, because that&rsquo;s the actual
program input.

</li><li> <span id="index-context-diff"></span>
<span id="index-sending-patches"></span>
<span id="index-ChangeLog-entry"></span>
If you are sending a patch (do so if you can!), please do so in the form
of a context diff (&lsquo;<samp>diff -c</samp>&rsquo;) against the original distribution
source.  Any other form of diff is either not as complete or harder for
me to understand.  Please also include a <samp>ChangeLog</samp> entry.

</li><li> <span id="index-stack-trace"></span>
<span id="index-debugger"></span>
<span id="index-crashes_002c-reporting"></span>
<span id="index-core-dumps_002c-reporting"></span>
<span id="index-null-pointers_002c-dereferencing"></span>
<span id="index-gdb_002c-recommended"></span>
If the bug involved is an actual crash (i.e., core dump), it is easy
and useful to include a stack trace from a debugger (I recommend the
GNU debugger GDB (<a href="https://gnu.org/software/gdb">https://gnu.org/software/gdb</a>).  If the
cause is apparent (a <code>NULL</code> value being dereferenced, for
example), please send the details along.  If the program involved is
TeX or Metafont, and the crash is happening at apparently-sound
code, however, the bug may well be in the compiler, rather than in the
program or the library (see <a href="#TeX-or-Metafont-failing">TeX or
Metafont failing</a>).

</li><li> Any additional information that will be helpful in reproducing,
diagnosing, or fixing the bug.
</li></ul>


<hr>
<span id="Mailing-lists"></span><div class="header">
<p>
Next: <a href="#Debugging" accesskey="n" rel="next">Debugging</a>, Previous: <a href="#Bug-checklist" accesskey="p" rel="prev">Bug checklist</a>, Up: <a href="#Reporting-bugs" accesskey="u" rel="up">Reporting bugs</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Mailing-lists-1"></span><h3 class="section">8.2 Mailing lists</h3>

<span id="index-mailing-lists"></span>
<span id="index-bug-mailing-list"></span>
<span id="index-announcement-mailing-list"></span>

<span id="index-tex_002dk_0040tug_002eorg"></span>
<p>Web2c and Kpathsea in general are discussed on the mailing list
<a href="mailto:tex-k@tug.org">tex-k@tug.org</a>.  You can subscribe and peruse the archives on
the web <a href="https://lists.tug.org/tex-k">https://lists.tug.org/tex-k</a>.
</p>
<p>You do not need to join to submit a report, nor will it affect whether
you get a response.  Be aware that large data files are sometimes
included in bug reports.  If this is a problem for you, do not join
the list.
</p>
<p>If you are looking for general TeX help, such as how to install a
full TeX system or how to use LaTeX, please see
<a href="https://tug.org/begin.html">https://tug.org/begin.html</a>.
</p>

<hr>
<span id="Debugging"></span><div class="header">
<p>
Next: <a href="#Logging" accesskey="n" rel="next">Logging</a>, Previous: <a href="#Mailing-lists" accesskey="p" rel="prev">Mailing lists</a>, Up: <a href="#Reporting-bugs" accesskey="u" rel="up">Reporting bugs</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Debugging-1"></span><h3 class="section">8.3 Debugging</h3>

<span id="index-debugging"></span>
<span id="index-runtime-debugging"></span>
<span id="index-options-for-debugging"></span>

<span id="index-kpse_002d_003edebug"></span>
<span id="index-debug_002eh"></span>
<p>Kpathsea provides a number of runtime debugging options, detailed below
by their names and corresponding numeric values.  When the files you
expect aren&rsquo;t being found, the thing to do is enable these options and
examine the output.
</p>
<p>You can set these with some runtime argument (e.g., &lsquo;<samp>-d</samp>&rsquo;) to the
program; in that case, you should use the numeric values described in
the program&rsquo;s documentation (which, for Dvipsk and Xdvik, are different
than those below).  It&rsquo;s best to give the &lsquo;<samp>-d</samp>&rsquo; (or whatever) option
first, for maximal output.  Dvipsk and Xdvik have additional
program-specific debugging options as well.
</p>
<span id="index-KPATHSEA_005fDEBUG-1"></span>
<span id="index-kpse_002d_003edebug-1"></span>
<p>You can also set the environment variable <code>KPATHSEA_DEBUG</code>; in this
case, you should use the numbers below.  If you run the program under a
debugger and set the instance variable <code>kpse-&gt;debug</code>, also use the numbers
below.
</p>
<span id="index-_002d1-debugging-value"></span>
<p>In any case, by far the simplest value to use is &lsquo;<samp>-1</samp>&rsquo;, which will
turn on all debugging output.  This is usually better than guessing
which particular values will yield the output you need.
</p>
<span id="index-debugging-output"></span>
<span id="index-standard-error-and-debugging-output"></span>
<p>Debugging output always goes to standard error, so you can redirect it
easily.  For example, in Bourne-compatible shells:
</p><div class="example">
<pre class="example">dvips -d -1 &hellip; 2&gt;/tmp/debug
</pre></div>

<span id="index-Kpsewhich_002c-and-debugging"></span>
<p>It is sometimes helpful to run the standalone Kpsewhich utility
(see <a href="#Invoking-kpsewhich">Invoking kpsewhich</a>), instead of the original program.
</p>
<span id="index-numeric-debugging-values"></span>
<p>In any case, you cannot use the names below; you must always use
somebody&rsquo;s numbers.  (Sorry.)  To set more than one option, just sum
the corresponding numbers.
</p>
<dl compact="compact">
<dt><code>KPSE_DEBUG_STAT <span class="roman">(1)</span></code>
<span id="index-KPSE_005fDEBUG_005fSTAT-_00281_0029"></span>
</dt>
<dd><p>Report &lsquo;<samp>stat</samp>&rsquo;(2) calls. This is useful for verifying that your
directory structure is not forcing Kpathsea to do many additional file
tests (see <a href="#Slow-path-searching">Slow path searching</a>, and see <a href="#Subdirectory-expansion">Subdirectory expansion</a>). If you are using an up-to-date <samp>ls-R</samp> database
(see <a href="#Filename-database">Filename database</a>), this should produce no output unless a
nonexistent file that must exist is searched for.
</p>
</dd>
<dt><code>KPSE_DEBUG_HASH <span class="roman">(2)</span></code>
<span id="index-KPSE_005fDEBUG_005fHASH-_00282_0029"></span>
</dt>
<dd><p>Report lookups in all hash tables: <samp>ls-R</samp> and <samp>aliases</samp>
(see <a href="#Filename-database">Filename database</a>); font aliases (see <a href="#Fontmap">Fontmap</a>); and config
file values (see <a href="#Config-files">Config files</a>).  Useful when expected values are not
being found, e.g.., file searches are looking at the disk instead of
using <samp>ls-R</samp>.
</p>
</dd>
<dt><code>KPSE_DEBUG_FOPEN <span class="roman">(4)</span></code>
<span id="index-KPSE_005fDEBUG_005fFOPEN-_00284_0029"></span>
</dt>
<dd><span id="index-fopen_002c-redefined"></span>
<p>Report file openings and closings. Especially useful when your system&rsquo;s
file table is full, for seeing which files have been opened but never
closed. In case you want to set breakpoints in a debugger: this works by
redefining &lsquo;<samp>fopen</samp>&rsquo; (&lsquo;<samp>fclose</samp>&rsquo;) to be &lsquo;<samp>kpse_fopen_trace</samp>&rsquo;
(&lsquo;<samp>kpse_fclose_trace</samp>&rsquo;).
</p>
</dd>
<dt><code>KPSE_DEBUG_PATHS <span class="roman">(8)</span></code>
<span id="index-KPSE_005fDEBUG_005fPATHS-_00288_0029"></span>
</dt>
<dd><span id="index-kpse_005fformat_005finfo_005ftype"></span>
<p>Report general path information for each file type Kpathsea is asked to
search. This is useful when you are trying to track down how a
particular path got defined&mdash;from <samp>texmf.cnf</samp>, <samp>config.ps</samp>,
an environment variable, the compile-time default, etc.  This is the
contents of the <code>kpse_format_info_type</code> structure defined in
<samp>tex-file.h</samp>.
</p>
</dd>
<dt><code>KPSE_DEBUG_EXPAND <span class="roman">(16)</span></code>
<span id="index-KPSE_005fDEBUG_005fEXPAND-_002816_0029"></span>
</dt>
<dd><p>Report the directory list corresponding to each path element Kpathsea
searches. This is only relevant when Kpathsea searches the disk, since
<samp>ls-R</samp> searches don&rsquo;t look through directory lists in this way.
</p>
</dd>
<dt><code>KPSE_DEBUG_SEARCH <span class="roman">(32)</span></code>
<span id="index-KPSE_005fDEBUG_005fSEARCH-_002832_0029"></span>
</dt>
<dd><p>Report on each file search: the name of the file searched for, the path
searched in, whether or not the file must exist (when drivers search for
<samp>cmr10.vf</samp>, it need not exist), and whether or not we are
collecting all occurrences of the file in the path (as with, e.g.,
<samp>texmf.cnf</samp> and <samp>texfonts.map</samp>), or just the first (as with
most lookups).  This can help you correlate what Kpathsea is doing with
what is in your input file.
</p>
</dd>
<dt><code>KPSE_DEBUG_VARS <span class="roman">(64)</span></code>
<span id="index-KPSE_005fDEBUG_005fVARS-_002864_0029"></span>
</dt>
<dd><p>Report the value of each variable Kpathsea looks up.  This is useful for
verifying that variables do indeed obtain their correct values.
</p>
</dd>
<dt><code>GSFTOPK_DEBUG <span class="roman">(128)</span></code>
<span id="index-GSFTOPK_005fDEBUG-_0028128_0029"></span>
</dt>
<dd><p>Activates debugging printout specific to <code>gsftopk</code> program.
</p>
</dd>
<dt><code>MAKETEX_DEBUG <span class="roman">(512)</span></code>
<span id="index-MAKETEX_005fDEBUG-_0028512_0029"></span>
</dt>
<dd><p>If you use the optional <code>mktex</code> programs instead of the
traditional shell scripts, this will report the name of the site file
(<samp>mktex.cnf</samp> by default) which is read, directories created by
<code>mktexdir</code>, the full path of the <samp>ls-R</samp> database built by
<code>mktexlsr</code>, font map searches, <code>MT_FEATURES</code> in effect,
parameters from <code>mktexnam</code>, filenames added by
<code>mktexupd</code>, and some subsidiary commands run by the programs.
</p>
</dd>
<dt><code>MAKETEX_FINE_DEBUG <span class="roman">(1024)</span></code>
<span id="index-MAKETEX_005fFINE_005fDEBUG-_00281024_0029"></span>
</dt>
<dd><p>When the optional <code>mktex</code> programs are used, this will print
additional debugging info from functions internal to these programs.
</p></dd>
</dl>

<span id="index-kdebug_003a"></span>
<span id="index-hash_005fsummary_005fonly-variable-for-debugging"></span>
<span id="index-hash-table-buckets_002c-printing"></span>
<p>Debugging output from Kpathsea is always written to standard error, and
begins with the string &lsquo;<samp>kdebug:</samp>&rsquo;. (Except for hash table buckets,
which just start with the number, but you can only get that output
running under a debugger. See comments at the <code>hash_summary_only</code>
variable in <samp>kpathsea/db.c</samp>.)
</p>

<hr>
<span id="Logging"></span><div class="header">
<p>
Next: <a href="#Common-problems" accesskey="n" rel="next">Common problems</a>, Previous: <a href="#Debugging" accesskey="p" rel="prev">Debugging</a>, Up: <a href="#Reporting-bugs" accesskey="u" rel="up">Reporting bugs</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Logging-1"></span><h3 class="section">8.4 Logging</h3>

<span id="index-log-file"></span>

<span id="index-logging-successful-searches"></span>
<span id="index-recording-successful-searches"></span>
<span id="index-usage-patterns_002c-finding"></span>
<span id="index-disk-usage_002c-reducing"></span>
<p>Kpathsea can record the time and filename found for each successful
search.  This may be useful in finding good candidates for deletion when
your filesystem is full, or in discovering usage patterns
at your site.
</p>
<span id="index-TEXMFLOG"></span>
<p>To do this, define the environment or config file variable
<code>TEXMFLOG</code>.  The value is the name of the file to append the
information to.  The file is created if it doesn&rsquo;t exist, and appended
to if it does.
</p>
<span id="index-epoch_002c-seconds-since"></span>
<span id="index-time-system-call"></span>
<p>Each successful search turns into one line in the log file: two words
separated by a space.  The first word is the time of the search, as the
integer number of seconds since &ldquo;the epoch&rdquo;, i.e., UTC midnight 1
January 1970 (more precisely, the result of the <code>time</code> system
call).  The second word is the filename.
</p>
<p>For example, after <code>setenv TEXMFLOG /tmp/log</code>, running Dvips on
<samp>story.dvi</samp> appends the following lines:
</p>
<div class="example">
<pre class="example">774455887 /usr/local/share/texmf/dvips/config.ps
774455887 /usr/local/share/texmf/dvips/psfonts.map
774455888 /usr/local/share/texmf/dvips/texc.pro
774455888 /usr/local/share/texmf/fonts/pk/ljfour/public/cm/cmbx10.600pk
774455889 /usr/local/share/texmf/fonts/pk/ljfour/public/cm/cmsl10.600pk
774455889 /usr/local/share/texmf/fonts/pk/ljfour/public/cm/cmr10.600pk
774455889 /usr/local/share/texmf/dvips/texc.pro
</pre></div>

<span id="index-privacy_002c-semblance-of"></span>
<p>Only filenames that are absolute are recorded, to preserve
some semblance of privacy.
</p>
<p>In addition to this Kpathsea-specific logging, <code>pdftex</code>
provides an option <samp>-recorder</samp> to write the names of all files
accessed during a run to the file <samp><var>basefile</var>.fls</samp>.
</p>
<p>Finally, most systems provide a general tool to output each system
call, thus including opening and closing files.  It might be named
<code>strace</code>, <code>truss</code>, <code>struss</code>, or something
else.
</p>

<hr>
<span id="Common-problems"></span><div class="header">
<p>
Previous: <a href="#Logging" accesskey="p" rel="prev">Logging</a>, Up: <a href="#Reporting-bugs" accesskey="u" rel="up">Reporting bugs</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Common-problems-1"></span><h3 class="section">8.5 Common problems</h3>

<span id="index-common-problems"></span>
<span id="index-problems_002c-common"></span>
<span id="index-FAQ_002c-Kpathsea"></span>

<p>Here are some common problems with configuration, compilation, linking,
execution, &hellip;
</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">&bull; <a href="#Unable-to-find-files" accesskey="1">Unable to find files</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">If your program can&rsquo;t find fonts (or whatever).
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Slow-path-searching" accesskey="2">Slow path searching</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">If it takes forever to find anything.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#Unable-to-generate-fonts" accesskey="3">Unable to generate fonts</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">If mktexpk fails.
</td></tr>
<tr><td align="left" valign="top">&bull; <a href="#TeX-or-Metafont-failing" accesskey="4">TeX or Metafont failing</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">Likely compiler bugs.
</td></tr>
</table>

<hr>
<span id="Unable-to-find-files"></span><div class="header">
<p>
Next: <a href="#Slow-path-searching" accesskey="n" rel="next">Slow path searching</a>, Up: <a href="#Common-problems" accesskey="u" rel="up">Common problems</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Unable-to-find-files-1"></span><h4 class="subsection">8.5.1 Unable to find files</h4>

<span id="index-unable-to-find-files"></span>
<span id="index-files_002c-unable-to-find"></span>

<p>If a program complains it cannot find fonts (or other input files), any
of several things might be wrong.  In any case, you may find the
debugging options helpful.  See <a href="#Debugging">Debugging</a>.
</p>
<ul>
<li> Perhaps you simply haven&rsquo;t installed all the necessary files; the basic
fonts and input files are distributed separately from the programs.
See <a href="#unixtex_002eftp">unixtex.ftp</a>.

</li><li> <span id="index-_002fetc_002fprofile"></span>
<span id="index-environment-variables_002c-old"></span>
You have (perhaps unknowingly) told Kpathsea to use search paths that
don&rsquo;t reflect where the files actually are.  One common cause is having
environment variables set from a previous installation, thus overriding
what you carefully set in <samp>texmf.cnf</samp> (see <a href="#Supported-file-formats">Supported file formats</a>).  System <samp>/etc/profile</samp> or other files such may be the
culprit.

</li><li> <span id="index-symbolic-links-not-found"></span>
<span id="index-leaf-directories-wrongly-guessed"></span>
Your files reside in a directory that is only pointed to via a symbolic
link, in a leaf directory and is not listed in <samp>ls-R</samp>.

<p>Unfortunately, Kpathsea&rsquo;s subdirectory searching has an irremediable
deficiency: If a directory <var>d</var> being searched for subdirectories
contains plain files and symbolic links to other directories, but no
true subdirectories, <var>d</var> will be considered a leaf directory, i.e.,
the symbolic links will not be followed.  See <a href="#Subdirectory-expansion">Subdirectory expansion</a>.
</p>
<p>You can work around this problem by creating an empty dummy subdirectory
in <var>d</var>. Then <var>d</var> will no longer be a leaf, and the symlinks will
be followed.
</p>
<p>The directory immediately followed by the &lsquo;<samp>//</samp>&rsquo; in the path
specification, however, is always searched for subdirectories, even if
it is a leaf.  Presumably you would not have asked for the directory to
be searched for subdirectories if you didn&rsquo;t want it to be.
</p>
</li><li> If the fonts (or whatever) don&rsquo;t already exist, <code>mktexpk</code> (or
<code>mktexmf</code> or <code>mktextfm</code>) will try to create them.  If
these rather complicated shell scripts fail, you&rsquo;ll eventually get an
error message saying something like &lsquo;<samp>Can't find font
<var>fontname</var></samp>&rsquo;. The best solution is to fix (or at least report) the
bug in <code>mktexpk</code>; the workaround is to generate the necessary
fonts by hand with Metafont, or to grab them from a CTAN site
(see <a href="#unixtex_002eftp">unixtex.ftp</a>).

</li><li> There is a bug in the library. See <a href="#Reporting-bugs">Reporting bugs</a>.
</li></ul>


<hr>
<span id="Slow-path-searching"></span><div class="header">
<p>
Next: <a href="#Unable-to-generate-fonts" accesskey="n" rel="next">Unable to generate fonts</a>, Previous: <a href="#Unable-to-find-files" accesskey="p" rel="prev">Unable to find files</a>, Up: <a href="#Common-problems" accesskey="u" rel="up">Common problems</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Slow-path-searching-1"></span><h4 class="subsection">8.5.2 Slow path searching</h4>

<span id="index-excessive-startup-time"></span>
<span id="index-slow-startup-time"></span>
<span id="index-startup-time_002c-excessive"></span>

<p>If your program takes an excessively long time to find fonts or other
input files, but does eventually succeed, here are some possible culprits:
</p>
<ul>
<li> Most likely, you just have a lot of directories to search, and that
takes a noticeable time. The solution is to create and maintain a
separate <samp>ls-R</samp> file that lists all the files in your main TeX
hierarchy.  See <a href="#Filename-database">Filename database</a>.  Kpathsea always uses <samp>ls-R</samp>
if it&rsquo;s present; there&rsquo;s no need to recompile or reconfigure any of the
programs.

</li><li> Your recursively-searched directories (e.g.,
<samp>/usr/local/share/texmf/fonts//</samp>), contain a mixture of files and
directories. This prevents Kpathsea from using a useful optimization
(see <a href="#Subdirectory-expansion">Subdirectory expansion</a>).

<p>It is best to have only directories (and perhaps a <samp>README</samp>) in the
upper levels of the directory structure, and it&rsquo;s very important to have
<em>only</em> files, and no subdirectories, in the leaf directories where
the dozens of TFM, PK, or whatever files reside.
</p></li></ul>

<p>In any case, you may find the debugging options helpful in determining
precisely when the disk or network is being pounded.  See <a href="#Debugging">Debugging</a>.
</p>

<hr>
<span id="Unable-to-generate-fonts"></span><div class="header">
<p>
Next: <a href="#TeX-or-Metafont-failing" accesskey="n" rel="next">TeX or Metafont failing</a>, Previous: <a href="#Slow-path-searching" accesskey="p" rel="prev">Slow path searching</a>, Up: <a href="#Common-problems" accesskey="u" rel="up">Common problems</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Unable-to-generate-fonts-1"></span><h4 class="subsection">8.5.3 Unable to generate fonts</h4>

<span id="index-unable-to-generate-fonts"></span>
<span id="index-font-generation-failures"></span>

<p>Metafont outputs fonts in bitmap format, tuned for a particular
device at a particular resolution, in order to allow for the
highest-possible quality of output.  Some DVI-to-whatever programs,
such as Dvips, try to generate these on the fly when they are needed,
but this generation may fail in several cases.
</p>
<span id="index-mktexpk-can_0027t-guess-mode"></span>
<p>If <code>mktexpk</code> runs, but fails with this error:
</p><div class="example">
<pre class="example">mktexpk: Can't guess mode for <var>nnn</var> dpi devices.
mktexpk: Use a config file to specify the mode, or update me.
</pre></div>
<p>you need to ensure the resolution and mode match; just
specifying the resolution, as in <code>-D 360</code>, is not enough.
</p>
<p>You can specify the mode name with the <code>-mode</code> option on the
Dvips command line, or in a Dvips configuration file (see <a href="https://tug.org/texinfohtml/dvips.html#Config-files">Config
files</a> in <cite>Dvips</cite>), such as <samp>config.ps</samp> in your document
directory, <samp>~/.dvipsrc</samp> in your home directory, or in a system
directory (again named <samp>config.ps</samp>).  (Other drivers use other
files, naturally.)
</p>
<p>For example, if you need 360dpi fonts, you could include this in
a configuration file:
</p><div class="example">
<pre class="example">D 360
M lqmed
</pre></div>

<span id="index-Metafont-using-the-wrong-device"></span>
<span id="index-device_002c-wrong"></span>
<p>If Metafont runs, but generates fonts at the wrong resolution or for
the wrong device, most likely <code>mktexpk</code>&rsquo;s built-in guess for the
mode is wrong, and you should override it as above.
</p>
<p>See <a href="https://ctan.org/pkg/modes">https://ctan.org/pkg/modes</a> for a list of resolutions and mode
names for most devices (additional submissions are welcome).
</p>
<span id="index-_002e2602gf"></span>
<span id="index-2602gf"></span>
<span id="index-Metafont-making-too_002dlarge-fonts"></span>
<span id="index-proof-mode"></span>
<span id="index-online-Metafont-display_002c-spurious"></span>
<p>If Metafont runs but generates fonts at a resolution of 2602dpi
(and prints out the name of each character as well as just a character
number, and maybe tries to display the characters), then your Metafont
base file probably hasn&rsquo;t been made properly.  (It&rsquo;s using the default
<code>proof</code> mode, instead of an actual device mode.)  To make a proper
<samp>plain.base</samp>, assuming the local mode definitions are contained in
a file <samp>modes.mf</samp>, run the following command (assuming Unix):
</p>
<div class="example">
<pre class="example">inimf &quot;plain; input modes; dump&quot;
</pre></div>

<p><span id="index-plain_002ebase"></span>
Then copy the <samp>plain.base</samp> file from the current directory to where
the base files are stored on your system
(<samp>/usr/local/share/texmf/web2c</samp> by default), and make a link
(either hard or soft) from <samp>plain.base</samp> to <samp>mf.base</samp> in that
directory.
See <a href="https://tug.org/texinfohtml/web2c.html#inimf-invocation">inimf invocation</a> in <cite>Web2c</cite>.
</p>
<span id="index-Metafont-installation"></span>
<p>If <code>mf</code> is a command not found at all by <code>mktexpk</code>, then you
need to install Metafont (see <a href="#unixtex_002eftp">unixtex.ftp</a>).
</p>

<hr>
<span id="TeX-or-Metafont-failing"></span><div class="header">
<p>
Previous: <a href="#Unable-to-generate-fonts" accesskey="p" rel="prev">Unable to generate fonts</a>, Up: <a href="#Common-problems" accesskey="u" rel="up">Common problems</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="TeX-or-Metafont-failing-1"></span><h4 class="subsection">8.5.4 TeX or Metafont failing</h4>

<span id="index-TeX-failures"></span>
<span id="index-Metafont-failures"></span>
<span id="index-compiler-bugs"></span>
<p>If TeX or Metafont get a segmentation fault or otherwise fail while
running a normal input file, the problem is usually a compiler bug
(unlikely as that may sound).  Even if the trip and trap tests are
passed, problems may lurk.  Optimization occasionally causes trouble in
programs other than TeX and Metafont themselves, too.
</p>
<span id="index-optimization-caveat"></span>
<p>For a workaround, if you enabled any optimization flags, it&rsquo;s best to
omit optimization entirely.  In any case, the way to find the facts is
to run the program under the debugger and see where it&rsquo;s failing.
</p>
<span id="index-GNU-C-compiler-bugs"></span>
<span id="index-system-C-compiler-bugs"></span>
<p>Also, if you have trouble with a system C compiler, I advise trying the
GNU C compiler. And vice versa, unfortunately; but in that case I also
recommend reporting a bug to the GCC mailing list; see <a href="https://gcc.gnu.org/onlinedocs/gcc/Bugs.html#Bugs">Bugs</a> in <cite>Using and Porting GNU CC</cite>.
</p>
<span id="index-compiler-bugs_002c-finding"></span>
<p>To report compiler bugs effectively requires perseverance and
perspicacity: you must find the miscompiled line, and that usually
involves delving backwards in time from the point of error, checking
through TeX&rsquo;s (or whatever program&rsquo;s) data structures.  Good luck.
</p>

<hr>
<span id="Index"></span><div class="header">
<p>
Previous: <a href="#Reporting-bugs" accesskey="p" rel="prev">Reporting bugs</a>, Up: <a href="#Top" accesskey="u" rel="up">Top</a> &nbsp; [<a href="#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="#Index" title="Index" rel="index">Index</a>]</p>
</div>
<span id="Index-1"></span><h2 class="unnumbered">Index</h2>

<table><tr><th valign="top">Jump to: &nbsp; </th><td><a class="summary-letter" href="#Index_cp_symbol-1"><b>!</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-2"><b>$</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-3"><b>-</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-4"><b>.</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-5"><b>/</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-6"><b>2</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-7"><b>8</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-8"><b>:</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-9"><b>;</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-10"><b>=</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-11"><b>\</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-12"><b>{</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-13"><b>~</b></a>
 &nbsp; 
<br>
<a class="summary-letter" href="#Index_cp_letter-A"><b>A</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-B"><b>B</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-C"><b>C</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-D"><b>D</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-E"><b>E</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-F"><b>F</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-G"><b>G</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-H"><b>H</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-I"><b>I</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-K"><b>K</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-L"><b>L</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-M"><b>M</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-N"><b>N</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-O"><b>O</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-P"><b>P</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-Q"><b>Q</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-R"><b>R</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-S"><b>S</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-T"><b>T</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-U"><b>U</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-V"><b>V</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-W"><b>W</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-X"><b>X</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-Z"><b>Z</b></a>
 &nbsp; 
</td></tr></table>
<table class="index-cp" border="0">
<tr><td></td><th align="left">Index Entry</th><td>&nbsp;</td><th align="left"> Section</th></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-1">!</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_0021_0021-and-casefolding"><code>!! <span class="roman">and casefolding</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_0021_0021-in-path-specifications"><code>!! <span class="roman">in path specifications</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_0021_0021-in-TEXMFDBS"><code>!! <span class="roman">in <code>TEXMFDBS</code></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-2">$</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_0024-expansion"><code>$ <span class="roman">expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-3">-</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dall"><code>--all</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dcasefold_002dsearch"><code>--casefold-search</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dcnf_002dline"><code>--cnf-line</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dcnf_002dline_002c-source-for-path"><code>&lsquo;<samp>--cnf-line</samp>&rsquo;, source for path</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dcolor_003dtty"><code>--color=tty</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002ddebug_003dnum"><code>--debug=<var>num</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002ddpi_003dnum"><code>--dpi=<var>num</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dengine_003dname"><code>--engine=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dexpand_002dbraces_003dstring"><code>--expand-braces=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dexpand_002dpath_003dstring"><code>--expand-path=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dexpand_002dvar_003dstring"><code>--expand-var=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dformat_003dname"><code>--format=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dhelp"><code>--help</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Standard-options">Standard options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dhelp_002dformats"><code>--help-formats</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dinteractive"><code>--interactive</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dmktex_003dfiletype"><code>--mktex=<var>filetype</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dmode_003dstring"><code>--mode=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dmust_002dexist"><code>--must-exist</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dno_002dcasefold_002dsearch"><code>--no-casefold-search</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dno_002dmktex_003dfiletype"><code>--no-mktex=<var>filetype</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dpath_003dstring"><code>--path=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dprogname_003dname"><code>--progname=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dsafe_002din_002dname_003dname"><code>--safe-in-name=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dsafe_002dout_002dname_003dname"><code>--safe-out-name=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dshow_002dpath_003dname"><code>--show-path=<var>name</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dsubdir_003dstring"><code>--subdir=<var>string</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dvar_002dbrace_002dvalue_003dvariable"><code>--var-brace-value=<var>variable</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dvar_002dvalue_003dvariable"><code>--var-value=<var>variable</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dversion"><code>--version</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Standard-options">Standard options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwith_002dmktextex_002ddefault"><code>--with-mktextex-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktexfmt_002ddefault"><code>--without-mktexfmt-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktexmf_002ddefault"><code>--without-mktexmf-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktexocp_002ddefault"><code>--without-mktexocp-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktexofm_002ddefault"><code>--without-mktexofm-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktexpk_002ddefault"><code>--without-mktexpk-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d_002dwithout_002dmktextfm_002ddefault"><code>--without-mktextfm-default</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002d1-debugging-value"><code>-1 <span class="roman">debugging value</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002dA-option-to-ls"><code>-A <span class="roman">option to <code>ls</code></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002dD-num"><code>-D <var>num</var></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002diname_002c-find-predicate"><code>-iname<span class="roman">, find predicate</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002dL-option-to-ls"><code>-L <span class="roman">option to <code>ls</code></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-4">.</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002e-directories_002c-ignored"><code>. <span class="roman">directories, ignored</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002e-files"><code>. <span class="roman">files</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002e2602gf"><code>.2602gf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eafm"><code>.afm</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ebase"><code>.base</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ebib"><code>.bib</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ebltxml"><code>.bltxml</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ebst"><code>.bst</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ecid"><code>.cid</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ecmap"><code>.cmap</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ecnf"><code>.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002edll"><code>.dll</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eenc"><code>.enc</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eeps"><code>.eps</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eepsi"><code>.epsi</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002efea"><code>.fea</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002efmt"><code>.fmt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eist"><code>.ist</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002elig"><code>.lig</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emap"><code>.map</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emem"><code>.mem</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emf"><code>.mf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emft"><code>.mft</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emlbib"><code>.mlbib</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emlbst"><code>.mlbst</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002emp"><code>.mp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eocp"><code>.ocp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eofm"><code>.ofm</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eopl"><code>.opl</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eotp"><code>.otp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eovf"><code>.ovf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eovp"><code>.ovp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epfa"><code>.pfa</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epfb"><code>.pfb</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epk"><code>.pk</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epool"><code>.pool</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epool-1"><code>.pool</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epool-2"><code>.pool</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002epro"><code>.pro</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eprogname-qualifier-in-texmf_002ecnf"><code>.<var>progname</var> <span class="roman">qualifier in <samp>texmf.cnf</samp></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002erhosts_002c-writable-by-TeX"><code>.rhosts<span class="roman">, writable by TeX</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eris"><code>.ris</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002esfd"><code>.sfd</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eso"><code>.so</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002etex"><code>.tex</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002etex-file_002c-included-in-ls_002dR"><code>.tex <span class="roman">file, included in <samp>ls-R</samp></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002etfm"><code>.tfm</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ettc"><code>.ttc</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ettf"><code>.ttf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002evf"><code>.vf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002ew"><code>.w</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eweb"><code>.web</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eweb-1"><code>.web</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-5">/</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002f-may-not-be-_002f"><code>/ <span class="roman">may not be /</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002f_002c-trailing-in-home-directory"><code>/<span class="roman">, trailing in home directory</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002f_002f"><code>//</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002fetc_002fprofile"><code>/etc/profile</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002fetc_002fprofile-and-aliases"><code>/etc/profile <span class="roman">and aliases</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002fvar_002ftmp_002ftexfonts"><code>/var/tmp/texfonts</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-6">2</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-2602gf"><code>2602gf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-7">8</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-8_002e3-filenames_002c-using">8.3 filenames, using</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-8">:</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_003a-may-not-be-_003a"><code>: <span class="roman">may not be :</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_003a_003a-expansion"><code>:: <span class="roman">expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-9">;</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_003b-translated-to-_003a-in-texmf_002ecnf"><code>; <span class="roman">translated to &lsquo;<samp>:</samp>&rsquo; in <samp>texmf.cnf</samp></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-10">=</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_003d-omitted-in-texmf_002ecnf-and-misparsing"><code>= <span class="roman">omitted in <samp>texmf.cnf</samp> and misparsing</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-11">\</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_005c_002c-line-continuation-in-texmf_002ecnf"><code>\<span class="roman">, line continuation in <samp>texmf.cnf</samp></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_005copenin"><code>\openin</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_005cspecial_002c-suppressing-warnings-about"><code>\special<span class="roman">, suppressing warnings about</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-12">{</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_007b-expansion"><code>{ <span class="roman">expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Brace-expansion">Brace expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_symbol-13">~</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_007e-expansion"><code>~ <span class="roman">expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-A">A</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-absolute-filenames">absolute filenames</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-access-system-call"><code>access <span class="roman">system call</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-access-warnings">access warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-AFMFONTS"><code>AFMFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-aliases-for-fonts">aliases for fonts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-aliases_002c-for-filenames">aliases, for filenames</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Filename-aliases">Filename aliases</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-all"><code>all</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-all-matches_002c-finding">all matches, finding</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-alphabetical-order_002c-not">alphabetical order, not</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-announcement-mailing-list">announcement mailing list</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Mailing-lists">Mailing lists</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-API_002c-re_002dentrant">API, re-entrant</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-append_002donly-directories-and-mktexpk">append-only directories and <code>mktexpk</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-appendonlydir"><code>appendonlydir</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Apple-filesystem_002c-case_002dinsensitive">Apple filesystem, case-insensitive</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-arguments-to-mktex">arguments to <samp>mktex</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-arguments">mktex script arguments</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-argv_005b0_005d"><code>argv[0]</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-autoconf_002c-recommended"><code>autoconf<span class="roman">, recommended</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-automounter_002c-and-ls_002dR">automounter, and <samp>ls-R</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-auxiliary-tasks">auxiliary tasks</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Auxiliary-tasks">Auxiliary tasks</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-B">B</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-Bach_002c-Johann-Sebastian">Bach, Johann Sebastian</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-backslash_002dnewline">backslash-newline</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-basic-glyph-lookup">basic glyph lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Basic-glyph-lookup">Basic glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Berry_002c-Karl">Berry, Karl</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-BIBINPUTS"><code>BIBINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-BIBINPUTS-1"><code>BIBINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-blank-lines_002c-in-texmf_002ecnf">blank lines, in <samp>texmf.cnf</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-BLTXMLINPUTS"><code>BLTXMLINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-brace-expansion">brace expansion</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Brace-expansion">Brace expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Breitenlohner_002c-Peter">Breitenlohner, Peter</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-BSTINPUTS"><code>BSTINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-BSTINPUTS-1"><code>BSTINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-bug-address">bug address</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Reporting-bugs">Reporting bugs</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-bug-checklist">bug checklist</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-bug-mailing-list">bug mailing list</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Mailing-lists">Mailing lists</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-bugs_002c-reporting">bugs, reporting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Reporting-bugs">Reporting bugs</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-C">C</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-c_002d_002a_002eh"><code>c-*.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-c_002dauto_002eh"><code>c-auto.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-cache-of-fonts_002c-local">cache of fonts, local</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-calling-sequence">calling sequence</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-casefolding-examples">casefolding examples</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-casefolding-fallback-rationale">casefolding fallback rationale</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-casefolding-search">casefolding search</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-search">Casefolding search</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ChangeLog-entry"><code>ChangeLog <span class="roman">entry</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-checklist-for-bug-reports">checklist for bug reports</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-checksum"><code>checksum</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-circle-fonts">circle fonts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-client_005fpath-in-kpse_002d_003eformat_005finfo"><code>client_path <span class="roman">in <code>kpse-&gt;format_info</code></span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-CLUAINPUTS"><code>CLUAINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-CMAPFONTS"><code>CMAPFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-cmr10_002c-as-fallback-font"><code>cmr10<span class="roman">, as fallback font</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-cmr10_002evf"><code>cmr10.vf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-cnf_002ec"><code>cnf.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-cnf_002eh"><code>cnf.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-comments_002c-in-fontmap-files">comments, in fontmap files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-comments_002c-in-texmf_002ecnf">comments, in <samp>texmf.cnf</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-comments_002c-making">comments, making</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-common-features-in-glyph-lookup">common features in glyph lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Basic-glyph-lookup">Basic glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-common-problems">common problems</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Common-problems">Common problems</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-compilation-value_002c-source-for-path">compilation value, source for path</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-compiler-bugs">compiler bugs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-compiler-bugs_002c-finding">compiler bugs, finding</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-conditions-for-use">conditions for use</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config-files">config files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config-files_002c-for-Kpathsea_002dusing-programs">config files, for Kpathsea-using programs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config-files_002c-programming-with">config files, programming with</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config_002eh"><code>config.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config_002elog"><code>config.log</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config_002eps"><code>config.ps</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config_002eps_002c-search-path-for"><code>config.ps<span class="roman">, search path for</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-config_002estatus"><code>config.status</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-configuration-bugs">configuration bugs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-configuration-file_002c-source-for-path">configuration file, source for path</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-configuration-files-as-shell-scripts_002e">configuration files as shell scripts.</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-configuration-of-mktex-scripts">configuration of <samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-configure-options-for-mktex-scripts"><code>configure</code> options for <samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-context-diff">context diff</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-continuation-character">continuation character</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-core-dumps_002c-reporting">core dumps, reporting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-crashes_002c-reporting">crashes, reporting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-CWEBINPUTS"><code>CWEBINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-D">D</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-database-search">database search</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-database_002c-for-filenames">database, for filenames</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Filename-database">Filename database</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-database_002c-format-of">database, format of</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Database-format">Database format</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-debug_002eh"><code>debug.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-debugger">debugger</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-debugging">debugging</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-debugging-options_002c-in-Kpathsea_002dusing-program">debugging options, in Kpathsea-using program</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-debugging-output">debugging output</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-default-expansion">default expansion</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-default_005ftexsizes"><code>default_texsizes</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-device_002c-wrong">device, wrong</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-directories_002c-making-append_002donly">directories, making append-only</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-directory-permissions">directory permissions</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-directory-structure_002c-for-TeX-files">directory structure, for TeX files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-directory-structure">TeX directory structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-disabling-mktex-scripts">disabling <samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-disk-search">disk search</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-disk-searching_002c-avoiding">disk searching, avoiding</a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-disk-usage_002c-reducing">disk usage, reducing</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-doc-files"><code>doc files</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DOS-compatible-names">DOS compatible names</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-dosnames"><code>dosnames</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-dot-files">dot files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-doubled-colons">doubled colons</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-dpinnn-directories"><code>dpi<var>nnn</var> directories</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVILJMAKEPK"><code>DVILJMAKEPK</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVILJSIZES"><code>DVILJSIZES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-dvipdfmx_002ecfg"><code>dvipdfmx.cfg</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVIPSFONTS"><code>DVIPSFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVIPSHEADERS"><code>DVIPSHEADERS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVIPSMAKEPK"><code>DVIPSMAKEPK</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-DVIPSSIZES"><code>DVIPSSIZES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-dynamic-creation-of-files">dynamic creation of files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-E">E</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-EC-fonts_002c-and-dynamic-source-creation">EC fonts, and dynamic source creation</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-elt_002ddirs_002ec"><code>elt-dirs.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-elt_002ddirs_002ec-1"><code>elt-dirs.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-enabling-mktex-scripts">enabling <samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ENCFONTS"><code>ENCFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-engine-name">engine name</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-environment-variable_002c-source-for-path">environment variable, source for path</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-environment-variables-for-TeX">environment variables for TeX</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-environment-variables-in-paths">environment variables in paths</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-environment-variables_002c-old">environment variables, old</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-epoch_002c-seconds-since">epoch, seconds since</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-error-message-macros">error message macros</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-examples_002c-of-casefolding-searches">examples, of casefolding searches</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-excessive-startup-time">excessive startup time</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Slow-path-searching">Slow path searching</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expand_002ec"><code>expand.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Brace-expansion">Brace expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expanding-symlinks">expanding symlinks</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-default">expansion, default</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-path-element">expansion, path element</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-search-path">expansion, search path</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-expansion">Path expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-subdirectory">expansion, subdirectory</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-tilde">expansion, tilde</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-expansion_002c-variable">expansion, variable</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-explicitly-relative-filenames">explicitly relative filenames</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-extensions_002c-filename">extensions, filename</a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-externally_002dbuilt-filename-database">externally-built filename database</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Filename-database">Filename database</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-extra-colons">extra colons</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-F">F</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-failed-mktex_2026-script-invocation">failed <code>mktex&hellip;</code> script invocation</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fallback-font">fallback font</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fallback-resolutions">fallback resolutions</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-FAQ_002c-Kpathsea">FAQ, Kpathsea</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Common-problems">Common problems</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Farwell_002c-Matthew">Farwell, Matthew</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-file-formats_002c-supported">file formats, supported</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-file-lookup">file lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-file-permissions">file permissions</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-file-types_002c-registering-new">file types, registering new</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-filename-aliases">filename aliases</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Filename-aliases">Filename aliases</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-filename-database">filename database</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Filename-database">Filename database</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-filenames_002c-absolute-or-explicitly-relative">filenames, absolute or explicitly relative</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-files_002c-unable-to-find">files, unable to find</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-filesystem-search">filesystem search</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-filesystem_002c-case_002d_0028in_0029sensitive">filesystem, case-(in)sensitive</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Findutils_002c-GNU-package">Findutils, GNU package</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-examples">Casefolding examples</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-floating-directories">floating directories</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fmtutil"><code>fmtutil</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fmtutil_002ecnf"><code>fmtutil.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fmtutils_002ecnf"><code>fmtutils.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-font-alias-files">font alias files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-font-generation-failures">font generation failures</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-font-of-last-resort">font of last resort</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-font-set_002c-infinite">font set, infinite</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-FONTCIDMAPS"><code>FONTCIDMAPS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-FONTFEATURES"><code>FONTFEATURES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fontmap-files">fontmap files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fontmaps-1"><code>fontmaps</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fontmaps">fontmaps</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fontname">fontname</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fontnames_002c-arbitrary-length">fontnames, arbitrary length</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-FOOINPUTS"><code>FOOINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-FOOINPUTS-1"><code>FOOINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fopen_002c-redefined"><code>fopen<span class="roman">, redefined</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-format-of-external-database">format of external database</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Database-format">Database format</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ftp_002ecs_002estanford_002eedu"><code>ftp.cs.stanford.edu</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ftp_002etug_002eorg"><code>ftp.tug.org</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-fundamental-purpose-of-Kpathsea">fundamental purpose of Kpathsea</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-G">G</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-gdb_002c-recommended"><code>gdb<span class="roman">, recommended</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-gf"><code>gf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GFFONTS"><code>GFFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-globally-writable-directories">globally writable directories</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-glyph-lookup">glyph lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Glyph-lookup">Glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-glyph-lookup-bitmap-tolerance">glyph lookup bitmap tolerance</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Basic-glyph-lookup">Basic glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GLYPHFONTS"><code>GLYPHFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GLYPHFONTS-1"><code>GLYPHFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-glyphlist_002etxt"><code>glyphlist.txt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GNU-C-compiler-bugs">GNU C compiler bugs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GNU-General-Public-License">GNU General Public License</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-group_002dwritable-directories">group-writable directories</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-GSFTOPK_005fDEBUG-_0028128_0029"><code>GSFTOPK_DEBUG <span class="roman">(128)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-H">H</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-hash-table-buckets_002c-printing">hash table buckets, printing</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-hash-table-routines">hash table routines</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-hash_005fsummary_005fonly-variable-for-debugging"><code>hash_summary_only <span class="roman">variable for debugging</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-history-of-Kpathsea">history of Kpathsea</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Hoekwater_002c-Taco">Hoekwater, Taco</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-home-directories-in-paths">home directories in paths</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-HOME_002c-as-_007e-expansion"><code>HOME<span class="roman">, as ~ expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-I">I</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-identifiers_002c-characters-valid-in">identifiers, characters valid in</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-include-fontmap-directive"><code>include <span class="roman">fontmap directive</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-INDEXSTYLE"><code>INDEXSTYLE</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-input-lines_002c-reading">input lines, reading</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-interactive-query">interactive query</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-interface_002c-not-frozen">interface, not frozen</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-introduction">introduction</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-K">K</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-kdebug_003a">&lsquo;<samp>kdebug:</samp>&rsquo;</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kdefault_002ec"><code>kdefault.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Knuth_002c-Donald-E_002e">Knuth, Donald E.</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Knuth_002c-Donald-E_002e_002c-archive-of-programs-by">Knuth, Donald E., archive of programs by</a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Kpathsea-config-file_002c-source-for-path">Kpathsea config file, source for path</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_002eh"><code>kpathsea.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fcnf_005fget"><code>kpathsea_cnf_get</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPATHSEA_005fDEBUG"><code>KPATHSEA_DEBUG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPATHSEA_005fDEBUG-1"><code>KPATHSEA_DEBUG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005ffind_005ffile"><code>kpathsea_find_file</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005ffind_005ffile-1"><code>kpathsea_find_file</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005ffind_005fglyph"><code>kpathsea_find_glyph</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Glyph-lookup">Glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005ffinish"><code>kpathsea_finish</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005finit_005fprog"><code>kpathsea_init_prog</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005finit_005fprog-1"><code>kpathsea_init_prog</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fin_005fname_005fok"><code>kpathsea_in_name_ok</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fnew"><code>kpathsea_new</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fopen_005ffile"><code>kpathsea_open_file</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fout_005fname_005fok"><code>kpathsea_out_name_ok</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fset_005fprogram_005fname"><code>kpathsea_set_program_name</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpathsea_005fvar_005fvalue"><code>kpathsea_var_value</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPATHSEA_005fWARNING"><code>KPATHSEA_WARNING</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003edebug"><code>kpse-&gt;debug</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003edebug-1"><code>kpse-&gt;debug</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003edebug-variable"><code>kpse-&gt;debug <span class="roman">variable</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003eformat_005finfo"><code>kpse-&gt;format_info</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003einvocation_005fname"><code>kpse-&gt;invocation_name</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003einvocation_005fshort_005fname"><code>kpse-&gt;invocation_short_name</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_002d_003eprogram_005fname"><code>kpse-&gt;program_name</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpsewhich"><code>kpsewhich</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Invoking-kpsewhich">Invoking kpsewhich</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Kpsewhich_002c-and-debugging">Kpsewhich, and debugging</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fBITMAP_005fTOLERANCE"><code>KPSE_BITMAP_TOLERANCE</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Basic-glyph-lookup">Basic glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fEXPAND-_002816_0029"><code>KPSE_DEBUG_EXPAND <span class="roman">(16)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fFOPEN-_00284_0029"><code>KPSE_DEBUG_FOPEN <span class="roman">(4)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fHASH-_00282_0029"><code>KPSE_DEBUG_HASH <span class="roman">(2)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fPATHS-_00288_0029"><code>KPSE_DEBUG_PATHS <span class="roman">(8)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fSEARCH-_002832_0029"><code>KPSE_DEBUG_SEARCH <span class="roman">(32)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fSTAT-_00281_0029"><code>KPSE_DEBUG_STAT <span class="roman">(1)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDEBUG_005fVARS-_002864_0029"><code>KPSE_DEBUG_VARS <span class="roman">(64)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-KPSE_005fDOT-expansion"><code>KPSE_DOT <span class="roman">expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#KPSE_005fDOT-expansion">KPSE_DOT expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-kpse_005fformat_005finfo_005ftype"><code>kpse_format_info_type</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-L">L</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-last_002dresort-font">last-resort font</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-lcircle10"><code>lcircle10</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-leading-colons">leading colons</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-leaf-directories-wrongly-guessed">leaf directories wrongly guessed</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-leaf-directory-trick">leaf directory trick</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-license-for-using-the-library">license for using the library</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-LIGFONTS"><code>LIGFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-lines_002c-reading-arbitrary_002dlength">lines, reading arbitrary-length</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Linux-File-System-Standard">Linux File System Standard</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-local-cache-of-fonts">local cache of fonts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-log-file">log file</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-logging-successful-searches">logging successful searches</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-lost_002bfound-directory"><code>lost+found <span class="roman">directory</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-lostchar"><code>lostchar</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ls_002dR"><code>ls-R</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ls_002dR-database-file"><code>ls-R <span class="roman">database file</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ls_002dR_002c-simplest-build"><code>ls-R<span class="roman">, simplest build</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-M">M</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-Mac-filesystem_002c-case_002dinsensitive">Mac filesystem, case-insensitive</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MacKenzie_002c-David">MacKenzie, David</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MacKenzie_002c-David-1">MacKenzie, David</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-magic-characters">magic characters</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mailing-lists">mailing lists</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Mailing-lists">Mailing lists</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MAKETEX_005fDEBUG-_0028512_0029"><code>MAKETEX_DEBUG <span class="roman">(512)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MAKETEX_005fFINE_005fDEBUG-_00281024_0029"><code>MAKETEX_FINE_DEBUG <span class="roman">(1024)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-memory-allocation-routines">memory allocation routines</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-metafont-driver-files">metafont driver files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Metafont-failures">Metafont failures</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Metafont-installation">Metafont installation</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Metafont-making-too_002dlarge-fonts">Metafont making too-large fonts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Metafont-using-the-wrong-device">Metafont using the wrong device</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MFBASES"><code>MFBASES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MFINPUTS"><code>MFINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MFPOOL"><code>MFPOOL</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MFTINPUTS"><code>MFTINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MISCFONTS"><code>MISCFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mismatched-checksum-warnings">mismatched checksum warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-missfont_002elog"><code>missfont.log</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MISSFONT_005fLOG"><code>MISSFONT_LOG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-missing-character-warnings">missing character warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mkocp"><code>mkocp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mkofm"><code>mkofm</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex-script-configuration"><samp>mktex</samp> script configuration</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex-script-names"><samp>mktex</samp> script names</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex-scripts"><samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex_002ecnf"><code>mktex.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex_002ecnf-1"><code>mktex.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex_002eopt"><code>mktex.opt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktex_002eopt-1"><code>mktex.opt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktexdir"><code>mktexdir</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktexfmt"><code>mktexfmt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktexmf"><code>mktexmf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktexpk"><code>mktexpk</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktexpk-can_0027t-guess-mode"><code>mktexpk</code> can&rsquo;t guess mode</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktextex"><code>mktextex</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mktextfm"><code>mktextfm</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MLBIBINPUTS"><code>MLBIBINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MLBSTINPUTS"><code>MLBSTINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-mode-directory_002c-omitting">mode directory, omitting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Morgan_002c-Tim">Morgan, Tim</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MPINPUTS"><code>MPINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MPMEMS"><code>MPMEMS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MPPOOL"><code>MPPOOL</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MPSUPPORT"><code>MPSUPPORT</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-MT_005fFEATURES"><code>MT_FEATURES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-multiple-TeX-hierarchies">multiple TeX hierarchies</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Brace-expansion">Brace expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-must-exist">must exist</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-N">N</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-names-for-mktex-scripts">names for <samp>mktex</samp> scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Neumann_002c-Gustaf">Neumann, Gustaf</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-NFS-and-ls_002dR">NFS and <samp>ls-R</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-nomfdrivers"><code>nomfdrivers</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-nomode"><code>nomode</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-none"><code>none</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-null-pointers_002c-dereferencing">null pointers, dereferencing</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-numeric-debugging-values">numeric debugging values</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-O">O</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-obtaining-TeX">obtaining TeX</a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OCPINPUTS"><code>OCPINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OFMFONTS"><code>OFMFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-online-Metafont-display_002c-spurious">online Metafont display, spurious</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OPENTYPEFONTS"><code>OPENTYPEFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-optimization-caveat">optimization caveat</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-options-for-debugging">options for debugging</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OTPINPUTS"><code>OTPINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-overview-of-path-searching">overview of path searching</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-overview-of-programming-with-Kpathsea">overview of programming with Kpathsea</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OVFFONTS"><code>OVFFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-OVPFONTS"><code>OVPFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-P">P</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-expansion">path expansion</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-expansion">Path expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-searching">path searching</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching">Path searching</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-searching-options">path searching options</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-searching_002c-overview">path searching, overview</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-searching_002c-standalone">path searching, standalone</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Invoking-kpsewhich">Invoking kpsewhich</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-path-sources">path sources</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pathsearch_002eh"><code>pathsearch.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pc-Pascal-compiler"><code>pc <span class="roman">Pascal compiler</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pdfglyphlist_002etxt"><code>pdfglyphlist.txt</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pdftex_002ecfg"><code>pdftex.cfg</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-PDFTEXCONFIG"><code>PDFTEXCONFIG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pdftexconfig_002etex"><code>pdftexconfig.tex</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-permission-denied">permission denied</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-permissions_002c-directory">permissions, directory</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-permissions_002c-file">permissions, file</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-PKFONTS"><code>PKFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-plain_002ebase"><code>plain.base</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-privacy_002c-semblance-of">privacy, semblance of</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-problems_002c-common">problems, common</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Common-problems">Common problems</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-proginit_002eh"><code>proginit.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-program_002dvarying-paths">program-varying paths</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-programming-overview">programming overview</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-programming-with-config-files">programming with config files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-programming-with-Kpathsea">programming with Kpathsea</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-programs-using-the-library">programs using the library</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-proof-mode">proof mode</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-PSHEADERS"><code>PSHEADERS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-pxp-Pascal-preprocessor"><code>pxp <span class="roman">Pascal preprocessor</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-Q">Q</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-quoting-variable-values">quoting variable values</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-R">R</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-rationale-for-casefolding-fallback">rationale for casefolding fallback</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-re_002dentrant-API">re-entrant API</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-readable"><code>readable</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-reading-arbitrary_002dlength-lines">reading arbitrary-length lines</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-recording-successful-searches">recording successful searches</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-relative-filenames">relative filenames</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-reporting-bugs">reporting bugs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Reporting-bugs">Reporting bugs</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-resident_002ec"><code>resident.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-resolution_002c-setting">resolution, setting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching-options">Path searching options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-resolutions_002c-last_002dresort">resolutions, last-resort</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-retrieving-TeX">retrieving TeX</a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-right_002dhand-side-of-variable-assignments">right-hand side of variable assignments</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-RISINPUTS"><code>RISINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Rokicki_002c-Tom">Rokicki, Tom</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-root-user"><tt>root</tt> user</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-runtime-configuration-files">runtime configuration files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-runtime-debugging">runtime debugging</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-S">S</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-Sauter-fonts_002c-and-dynamic-source-creation">Sauter fonts, and dynamic source creation</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-scripts-for-file-creation">scripts for file creation</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-scripts">mktex scripts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-search-path_002c-defined">search path, defined</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-search_002c-case_002dinsensitive">search, case-insensitive</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-search">Casefolding search</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-searching-for-files">searching for files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-searching-for-glyphs">searching for glyphs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Glyph-lookup">Glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-searching-overview">searching overview</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-searching-the-database">searching the database</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-searching-the-disk">searching the disk</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-security-considerations">security considerations</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-SELFAUTODIR">SELFAUTODIR</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-SELFAUTOLOC">SELFAUTOLOC</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-SELFAUTOPARENT">SELFAUTOPARENT</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-sending-patches">sending patches</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-setgid-scripts">setgid scripts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-SFDFONTS"><code>SFDFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-shell-scripts-as-configuration-files">shell scripts as configuration files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-shell-variables">shell variables</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-shell_005fescape_002c-example-for-code"><code>shell_escape<span class="roman">, example for code</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-site-overrides-for-mktex_2026">site overrides for <code>mktex&hellip;</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-skeleton-TeX-directory">skeleton TeX directory</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-directory-structure">TeX directory structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-slow-startup-time">slow startup time</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Slow-path-searching">Slow path searching</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-source-files"><code>source files</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-sources-for-search-paths">sources for search paths</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-special"><code>special</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-stack-trace">stack trace</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-standalone-path-searching">standalone path searching</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Invoking-kpsewhich">Invoking kpsewhich</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-standard-error-and-debugging-output">standard error and debugging output</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Debugging">Debugging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-standard-options">standard options</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Standard-options">Standard options</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-startup-time_002c-excessive">startup time, excessive</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Slow-path-searching">Slow path searching</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-string-routines">string routines</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-strip"><code>strip</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-stripsupplier"><code>stripsupplier</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-striptypeface"><code>striptypeface</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-st_005fnlink"><code>st_nlink</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-ST_005fNLINK_005fTRICK"><code>ST_NLINK_TRICK</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-subdirectory-searching">subdirectory searching</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-suffixes_002c-filename">suffixes, filename</a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-suggestions_002c-making">suggestions, making</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Sun-2">Sun 2</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-supplier-directory_002c-omitting">supplier directory, omitting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-supplier-directory_002c-omitting-1">supplier directory, omitting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-supported-file-formats">supported file formats</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-suppressing-warnings">suppressing warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-symbolic-links-not-found">symbolic links not found</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-symbolic-links_002c-and-ls_002dR">symbolic links, and <samp>ls-R</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-symlinks_002c-resolving">symlinks, resolving</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Calling-sequence">Calling sequence</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-system-C-compiler-bugs">system C compiler bugs</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-system_002ddependent-casefolding-behavior">system-dependent casefolding behavior</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-T">T</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-T1FONTS"><code>T1FONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-T1INPUTS"><code>T1INPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-T42FONTS"><code>T42FONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tcfmgr_002emap"><code>tcfmgr.map</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TDS">TDS</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-directory-structure">TeX directory structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-directory-structure">TeX directory structure</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-directory-structure">TeX directory structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-environment-variables">TeX environment variables</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-failures">TeX failures</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-or-Metafont-failing">TeX or Metafont failing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-file-lookup">TeX file lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-glyph-lookup">TeX glyph lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Glyph-lookup">Glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-support">TeX support</a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-support">TeX support</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TeX-Users-Group">TeX Users Group</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Introduction">Introduction</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dfile_002ec"><code>tex-file.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dfile_002eh"><code>tex-file.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dglyph_002ec"><code>tex-glyph.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Glyph-lookup">Glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dglyph_002eh"><code>tex-glyph.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-overview">Programming overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dk_0040tug_002eorg"><code>tex-k@tug.org</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Mailing-lists">Mailing lists</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002dk_0040tug_002eorg-_0028bug-address_0029"><code>tex-k@tug.org <span class="roman">(bug address)</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Reporting-bugs">Reporting bugs</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tex_002eweb"><code>tex.web</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXBIB"><code>TEXBIB</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXBIB-1"><code>TEXBIB</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXCONFIG"><code>TEXCONFIG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXDOCS"><code>TEXDOCS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFONTMAPS"><code>TEXFONTMAPS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFONTS"><code>TEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFONTS-1"><code>TEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFONTS-2"><code>TEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFONTS-3"><code>TEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texfonts_002emap"><code>texfonts.map</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXFORMATS"><code>TEXFORMATS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXINDEXSTYLE"><code>TEXINDEXSTYLE</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXINPUTS"><code>TEXINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXINPUTS-1"><code>TEXINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMF"><code>TEXMF</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#TeX-directory-structure">TeX directory structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_002ecnf"><code>texmf.cnf</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_002ecnf-missing_002c-warning-about"><samp>texmf.cnf</samp> missing, warning about</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_002ecnf_002c-and-variable-expansion"><code>texmf.cnf<span class="roman">, and variable expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_002ecnf_002c-definition-for"><code>texmf.cnf<span class="roman">, definition for</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_002ecnf_002c-source-for-path"><code>texmf.cnf<span class="roman">, source for path</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-sources">Path sources</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFCNF"><code>TEXMFCNF</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFCNF-1"><code>TEXMFCNF</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFDBS"><code>TEXMFDBS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFDBS-1"><code>TEXMFDBS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFINI"><code>TEXMFINI</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFINI-1"><code>TEXMFINI</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFINI-2"><code>TEXMFINI</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFLOG"><code>TEXMFLOG</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFOUTPUT"><code>TEXMFOUTPUT</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFSCRIPTS"><code>TEXMFSCRIPTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmfvar"><code>texmfvar</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXMFVAR"><code>TEXMFVAR</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-texmf_005fcasefold_005fsearch"><code>texmf_casefold_search</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-search">Casefolding search</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXPICTS"><code>TEXPICTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXPKS"><code>TEXPKS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXPOOL"><code>TEXPOOL</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXPSHEADERS"><code>TEXPSHEADERS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXPSHEADERS-1"><code>TEXPSHEADERS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXSIZES"><code>TEXSIZES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEXSOURCES"><code>TEXSOURCES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEX_005fHUSH"><code>TEX_HUSH</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TEX_005fHUSH-1"><code>TEX_HUSH</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TFMFONTS"><code>TFMFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tilde-expansion">tilde expansion</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tilde_002ec"><code>tilde.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-time-system-call"><code>time <span class="roman">system call</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tolerance-for-glyph-lookup">tolerance for glyph lookup</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Basic-glyph-lookup">Basic glyph lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-trailing-_002f-in-home-directory">trailing &lsquo;<samp>/</samp>&rsquo; in home directory</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-trailing-colons">trailing colons</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Default-expansion">Default expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-translations_002c-of-path-searching-description">translations, of path searching description</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Path-searching">Path searching</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TRFONTS"><code>TRFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-trick-for-detecting-leaf-directories">trick for detecting leaf directories</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Subdirectory-expansion">Subdirectory expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-trojan-horse-attack">trojan horse attack</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Security">Security</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-try_005fstd_005fextension_005ffirst"><code>try_std_extension_first</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#File-lookup">File lookup</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-TTFONTS"><code>TTFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-tug_002eorg"><code>tug.org</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-typeface-directory_002c-omitting">typeface directory, omitting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-typeface-directory_002c-omitting-1">typeface directory, omitting</a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-U">U</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-unable-to-find-files">unable to find files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-find-files">Unable to find files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unable-to-generate-fonts">unable to generate fonts</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Unable-to-generate-fonts">Unable to generate fonts</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-uname"><code>uname</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unixtex_002eftp"><code>unixtex.ftp</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unknown-special-warnings">unknown special warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unreadable-file-warnings">unreadable file warnings</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unreadable-files">unreadable files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-unusable-ls_002dR-warning">unusable <samp>ls-R</samp> warning</a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-usage-patterns_002c-finding">usage patterns, finding</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Logging">Logging</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-USERPROFILE_002c-as-_007e-expansion"><code>USERPROFILE<span class="roman">, as ~ expansion</span></code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Tilde-expansion">Tilde expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-USE_005fTEXMFVAR"><code>USE_TEXMFVAR</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-USE_005fVARTEXFONTS"><code>USE_VARTEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-V">V</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-varfonts"><code>varfonts</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-variable-expansion">variable expansion</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-variable_002ec"><code>variable.c</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Variable-expansion">Variable expansion</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-variable_002eh"><code>variable.h</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Programming-with-config-files">Programming with config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-VARTEXFONTS"><code>VARTEXFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-configuration">mktex configuration</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-VAX-11_002f750">VAX 11/750</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-version-numbers_002c-determining">version numbers, determining</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Bug-checklist">Bug checklist</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-VF-files_002c-not-found">VF files, not found</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-VFFONTS"><code>VFFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Vojta_002c-Paul">Vojta, Paul</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-W">W</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-Walsh_002c-Norman">Walsh, Norman</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-warning-about-unusable-ls_002dR">warning about unusable <samp>ls-R</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#ls_002dR">ls-R</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-warning_002c-about-missing-texmf_002ecnf">warning, about missing <samp>texmf.cnf</samp></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-warnings_002c-file-access">warnings, file access</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Searching-overview">Searching overview</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-warnings_002c-suppressing">warnings, suppressing</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Suppressing-warnings">Suppressing warnings</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-WEB2C"><code>WEB2C</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Weber_002c-Olaf">Weber, Olaf</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-WEBINPUTS"><code>WEBINPUTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-whitespace_002c-in-fontmap-files">whitespace, in fontmap files</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fontmap">Fontmap</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-whitespace_002c-not-ignored-on-continuation-lines">whitespace, not ignored on continuation lines</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Config-files">Config files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-Windows-and-casefolding">Windows and casefolding</a>:</td><td>&nbsp;</td><td valign="top"><a href="#Casefolding-rationale">Casefolding rationale</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-www_002etug_002eorg"><code>www.tug.org</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#unixtex_002eftp">unixtex.ftp</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-X">X</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-XDvi"><code>XDvi</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Specially_002drecognized-files">Specially-recognized files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-XDVIFONTS"><code>XDVIFONTS</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Supported-file-formats">Supported file formats</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-XDVIMAKEPK"><code>XDVIMAKEPK</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#mktex-script-names">mktex script names</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-XDVISIZES"><code>XDVISIZES</code></a>:</td><td>&nbsp;</td><td valign="top"><a href="#Fallback-font">Fallback font</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
<tr><th id="Index_cp_letter-Z">Z</th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-zuhn_002c-david">zuhn, david</a>:</td><td>&nbsp;</td><td valign="top"><a href="#History">History</a></td></tr>
<tr><td colspan="4"> <hr></td></tr>
</table>
<table><tr><th valign="top">Jump to: &nbsp; </th><td><a class="summary-letter" href="#Index_cp_symbol-1"><b>!</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-2"><b>$</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-3"><b>-</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-4"><b>.</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-5"><b>/</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-6"><b>2</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-7"><b>8</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-8"><b>:</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-9"><b>;</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-10"><b>=</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-11"><b>\</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-12"><b>{</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_symbol-13"><b>~</b></a>
 &nbsp; 
<br>
<a class="summary-letter" href="#Index_cp_letter-A"><b>A</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-B"><b>B</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-C"><b>C</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-D"><b>D</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-E"><b>E</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-F"><b>F</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-G"><b>G</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-H"><b>H</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-I"><b>I</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-K"><b>K</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-L"><b>L</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-M"><b>M</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-N"><b>N</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-O"><b>O</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-P"><b>P</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-Q"><b>Q</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-R"><b>R</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-S"><b>S</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-T"><b>T</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-U"><b>U</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-V"><b>V</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-W"><b>W</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-X"><b>X</b></a>
 &nbsp; 
<a class="summary-letter" href="#Index_cp_letter-Z"><b>Z</b></a>
 &nbsp; 
</td></tr></table>

<hr>



</body>
</html>