summaryrefslogtreecommitdiff
path: root/Build/source/texk/cjkutils/cjkutils-4.8.2-PATCHES/patch-03-kpathsea
blob: 23a25bd8696905943949b758bfedb01638059ca9 (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
diff -ur cjkutils-4.8.2.orig/hbf2gf/hbf2gf.w cjkutils-4.8.2/hbf2gf/hbf2gf.w
--- cjkutils-4.8.2.orig/hbf2gf/hbf2gf.w	2009-10-01 00:04:37.000000000 +0200
+++ cjkutils-4.8.2/hbf2gf/hbf2gf.w	2010-12-17 21:38:32.783541781 +0100
@@ -71,8 +71,6 @@
 @s HBF_BBOX int
 
 @s __inline__ int
-@s DllImport int
-@s KPSEDLL int
 
 
 @* Introduction.
@@ -408,6 +406,9 @@
 
 @
 @<Include files@>=
+#ifdef HAVE_CONFIG_H
+#include <c-auto.h>
+#endif
 #include <ctype.h>
 #include <stdio.h>
 #include <stdlib.h>
@@ -2461,21 +2462,13 @@
 
 We support three searching engines: emtexdir, kpathsea, and MiKTeX (which is
 a Win32 port of kpathsea). For emtexdir, define |HAVE_EMTEXDIR| while
-compiling. For kpathsea, define |HAVE_LIBKPATHSEA|. If you have a version of
-kpathsea older than~3.2, define |OLD_KPATHSEA| additionally. For kpathsea
-older than~3.0, |VERY_OLD_KPATHSEA| must be also set. For MikTeX, define
+compiling. For kpathsea, define |HAVE_LIBKPATHSEA|. For MikTeX, define
 |HAVE_MIKTEX|. If none of these macros is defined, a simple |fopen()| will
 be used instead.
 
 @<Include files@>=
 #if defined(HAVE_LIBKPATHSEA)
-#ifdef VERY_OLD_KPATHSEA
-#include "kpathsea/proginit.h"
-#include "kpathsea/progname.h"
-#include "kpathsea/tex-glyph.h"
-#else
 #include "kpathsea/kpathsea.h"
-#endif@#
 
 #elif defined(HAVE_EMTEXDIR)
 #include "emtexdir.h"
@@ -2486,14 +2479,7 @@
 
 @
 @<Global variables@>=
-#if defined(HAVE_LIBKPATHSEA)
-#ifdef KPSEDLL
-/* this is kpathsea 3.3 and newer */
-extern KPSEDLL char *kpathsea_version_string;
-#else
-extern DllImport char *kpathsea_version_string;
-#endif
-#elif defined(HAVE_EMTEXDIR)
+#if defined(HAVE_EMTEXDIR)
 char emtex_version_string[] = "emTeXdir";
 #elif !defined(HAVE_MIKTEX)
 char no_version_string[] = "no search library";
@@ -2599,17 +2585,8 @@
 
 @<Initialize \TeX\ file searching@>=
 #if defined(HAVE_LIBKPATHSEA)
-#ifdef OLD_KPATHSEA
-    kpse_set_progname(argv[0]);
-#else
     kpse_set_program_name(argv[0], "hbf2gf");
-#endif@#
-
-#ifdef VERY_OLD_KPATHSEA
-    kpse_init_prog("HBF2GF", 300, "cx", true, "cmr10");
-#else
     kpse_init_prog("HBF2GF", 300, "cx", "cmr10");@#
-#endif@#
 
 #elif defined(HAVE_EMTEXDIR)
     if(!dir_setup(&cfg_path, "HBFCFG", NULL, EDS_BANG))
@@ -2643,25 +2620,13 @@
 #if defined(HAVE_LIBKPATHSEA)
 char *TeX_search_cfg_file(char *name)
    {
-#ifdef OLD_KPATHSEA
-    return kpse_find_file(name, kpse_dvips_config_format, TRUE);
-#else
     return kpse_find_file(name, kpse_program_text_format, TRUE);
-#endif
    }@#
 
 
 char *TeX_search_hbf_file(char *name)
    {
-#ifdef VERY_OLD_KPATHSEA
-    return kpse_find_file(name, kpse_dvips_header_format, TRUE);
-#else
-#ifndef KPSEDLL
-    return kpse_find_file(name, kpse_type1_format, TRUE);
-#else
     return kpse_find_file(name, kpse_miscfonts_format, TRUE);
-#endif
-#endif
    }@#