summaryrefslogtreecommitdiffstats
path: root/meta-openembedded/meta-oe/recipes-extended/t1lib/t1lib-5.1.2/configure.patch
blob: 976e0380e4efddfc4dd00a216269926d6d0ca089 (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
From 81c1ba940415595584a837ab1078c64855072f0c Mon Sep 17 00:00:00 2001
From: Koen Kooi <koen@dominion.thruhere.net>
Date: Mon, 21 Nov 2011 12:00:54 +0100
Subject: [PATCH] t1lib: add 5.1.2

#
# Patch managed by http://www.holgerschurig.de/patcher.html
#

---
 configure.in | 95 ++++++++++++++++++++++++------------------------------------
 1 file changed, 38 insertions(+), 57 deletions(-)

diff --git a/configure.in b/configure.in
index eade4c0..e649ea9 100644
--- a/configure.in
+++ b/configure.in
@@ -74,9 +74,9 @@ T1LIB_PATCHLEVEL=builtin(eval, MACRO_T1LIB_LT_REVISION)
 T1LIB_VERSIONSTRING=\"MACRO_T1LIB_IDENTIFIER\"
 
 
-dnl We use this file by Andreas Zeller to check for libXaw
-builtin(include, ac-tools/ice_find_athena.m4)
-builtin(include, ac-tools/aclocal.m4)
+#dnl We use this file by Andreas Zeller to check for libXaw
+#builtin(include, ac-tools/ice_find_athena.m4)
+#builtin(include, ac-tools/aclocal.m4)
 
 dnl We want these before the checks, so the checks can modify their values.
 test -z "$LDLIBS" && LDLIBS=-lm   AC_SUBST(LDLIBS)
@@ -162,6 +162,7 @@ fi
 
 dnl **** Check for underscore on external symbols ****
 
+AH_TEMPLATE([NEED_UNDERSCORE_PREFIX], [Define if external symbols need an underscore prefix])
 AC_CACHE_CHECK("whether external symbols need an underscore prefix",
                ac_cv_c_extern_prefix,
 [saved_libs=$LIBS
@@ -179,68 +180,48 @@ then
   AC_DEFINE(NEED_UNDERSCORE_PREFIX)
 fi
 
-dnl **** Check which ANSI integer type is 16 bit 
-
-AC_CACHE_CHECK( "which ANSI integer type is 16 bit", ac_16bit_type,
-		AC_TRY_RUN([
-int main(void) {
-  if (sizeof(short)==2)
-    return(0);
-  else if (sizeof(int)==2)
-    return(1);
-  else
-    return(2);
-}], ac_16bit_type="short", ac_16bit_type="int", ac_16bit_type=))
-if test "$ac_16bit_type" = "short"
-then
-  T1_AA_TYPE16="-DT1_AA_TYPE16=short"
-  T1_INT16="short"
-else
-  T1_AA_TYPE16="-DT1_AA_TYPE16=int"
-  T1_INT16="int"
+dnl **** Check which ANSI integer type is 16 bit
+T1_AA_TYPE16=""
+for type in short int; do
+	if test x"`eval echo \\$ac_cv_sizeof_$type`" = "x2"; then
+		T1_AA_TYPE16="-DT1_AA_TYPE16=$type"
+		T1_INT16="$type"
+		break
+	fi
+done
+
+if test x"$T1_AA_TYPE16" = "x"; then
+	AC_MSG_ERROR("Unable to determine which integer type is 16 bit.")
 fi
 
-
 dnl **** Check which ANSI integer type is 32 bit 
-
-AC_CACHE_CHECK( "which ANSI integer type is 32 bit", ac_32bit_type,
-		AC_TRY_RUN([
-int main(void) {
-  if (sizeof(int)==4)
-    return(0);
-  else if (sizeof(long)==4)
-    return(1);
-  else
-    return(2);
-}], ac_32bit_type="int", ac_32bit_type="long", ac_32bit_type=))
-if test "$ac_32bit_type" = "int"
-then
-  T1_AA_TYPE32="-DT1_AA_TYPE32=int"
-  T1_INT32="int"
-else
-  T1_AA_TYPE32="-DT1_AA_TYPE32=long"
-  T1_INT32="long"
+T1_AA_TYPE32=""
+for type in int long; do
+	if test x"`eval echo \\$ac_cv_sizeof_$type`" = "x4"; then
+		T1_AA_TYPE32="-DT1_AA_TYPE32=$type"
+		T1_INT32="$type"
+		break
+	fi
+done
+
+if test x"$T1_AA_TYPE32" = "x"; then
+	AC_MSG_ERROR("Unable to determine which integer type is 32 bit.")
 fi
 
-
 dnl **** Check which ANSI integer type is 64 bit 
-
-AC_CACHE_CHECK( "which ANSI integer type is 64 bit", ac_64bit_type,
-		AC_TRY_RUN([
-int main(void) {
-  if (sizeof(long)==8)
-    return(0);
-  else
-    return(1);
-}], ac_64bit_type="long", ac_64bit_type="<none>"))
-if test "$ac_64bit_type" = "long"
-then
-  T1_AA_TYPE64="-DT1_AA_TYPE64=long"
-else
-  T1_AA_TYPE64=
+T1_AA_TYPE64=""
+for type in long long_long; do
+	if test x"`eval echo \\$ac_cv_sizeof_$type`" = "x8"; then
+		AC_MSG_WARN("$type is 64 bit")
+		T1_AA_TYPE64="-DT1_AA_TYPE64=\"`echo $type|tr '_' ' '`\""
+		break
+	fi
+done
+
+if test x"$T1_AA_TYPE64" = "x"; then
+	AC_MSG_ERROR("Unable to determine which integer type is 64 bit.")
 fi
 
-
 CFLAGS="${CFLAGS} -DT1LIB_IDENT=\"\\\"${T1LIB_IDENTIFIER}\\\"\" -DGLOBAL_CONFIG_DIR=\"\\\"${T1LIB_DATA_DIR}\\\"\""
 
 dnl **** Check for functions and header files ****
OpenPOWER on IntegriCloud