3 ?RCS: Copyright (c) 1999 Jarkko Hietaniemi
5 ?RCS: You may distribute under the terms of either the GNU General Public
6 ?RCS: License or the Artistic License, as specified in the README file.
8 ?MAKE:d_PRIfldbl sPRIfldbl d_PRIgldbl d_PRIFUldbl sPRIGUldbl d_PRIEUldbl \
9 sPRIgldbl d_PRIeldbl sPRIeldbl sPRIFUldbl d_PRIGUldbl sPRIEUldbl \
12 d_longdbl longdblsize doublesize test cat rm_try \
14 ?MAKE: -pick add $@ %<
16 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
17 ?S: indicates that stdio has a symbol to print long doubles.
20 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
21 ?S: indicates that stdio has a symbol to print long doubles.
24 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
25 ?S: indicates that stdio has a symbol to print long doubles.
28 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
29 ?S: indicates that stdio has a symbol to print long doubles.
30 ?S: The 'U' in the name is to separate this from d_PRIfldbl so that even
31 ?S: case-blind systems can see the difference.
34 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
35 ?S: indicates that stdio has a symbol to print long doubles.
36 ?S: The 'U' in the name is to separate this from d_PRIgldbl so that even
37 ?S: case-blind systems can see the difference.
40 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
41 ?S: indicates that stdio has a symbol to print long doubles.
42 ?S: The 'U' in the name is to separate this from d_PRIeldbl so that even
43 ?S: case-blind systems can see the difference.
46 ?S: This variable conditionally defines the PERL_PRIfldbl symbol, which
47 ?S: indicates that stdio has a symbol to scan long doubles.
50 ?S: This variable, if defined, contains the string used by stdio to
51 ?S: format long doubles (format 'f') for output.
54 ?S: This variable, if defined, contains the string used by stdio to
55 ?S: format long doubles (format 'g') for output.
58 ?S: This variable, if defined, contains the string used by stdio to
59 ?S: format long doubles (format 'e') for output.
62 ?S: This variable, if defined, contains the string used by stdio to
63 ?S: format long doubles (format 'F') for output.
64 ?S: The 'U' in the name is to separate this from sPRIfldbl so that even
65 ?S: case-blind systems can see the difference.
68 ?S: This variable, if defined, contains the string used by stdio to
69 ?S: format long doubles (format 'G') for output.
70 ?S: The 'U' in the name is to separate this from sPRIgldbl so that even
71 ?S: case-blind systems can see the difference.
74 ?S: This variable, if defined, contains the string used by stdio to
75 ?S: format long doubles (format 'E') for output.
76 ?S: The 'U' in the name is to separate this from sPRIeldbl so that even
77 ?S: case-blind systems can see the difference.
80 ?S: This variable, if defined, contains the string used by stdio to
81 ?S: format long doubles (format 'f') for input.
84 ?C: This symbol, if defined, contains the string used by stdio to
85 ?C: format long doubles (format 'f') for output.
88 ?C: This symbol, if defined, contains the string used by stdio to
89 ?C: format long doubles (format 'g') for output.
92 ?C: This symbol, if defined, contains the string used by stdio to
93 ?C: format long doubles (format 'e') for output.
96 ?C: This symbol, if defined, contains the string used by stdio to
97 ?C: format long doubles (format 'f') for output.
100 ?C: This symbol, if defined, contains the string used by stdio to
101 ?C: format long doubles (format 'g') for output.
104 ?C: This symbol, if defined, contains the string used by stdio to
105 ?C: format long doubles (format 'e') for output.
108 ?C: This symbol, if defined, contains the string used by stdio to
109 ?C: format long doubles (format 'f') for input.
111 ?H:#$d_PRIfldbl PERL_PRIfldbl $sPRIfldbl /**/
112 ?H:#$d_PRIgldbl PERL_PRIgldbl $sPRIgldbl /**/
113 ?H:#$d_PRIeldbl PERL_PRIeldbl $sPRIeldbl /**/
114 ?H:#$d_PRIFUldbl PERL_PRIFldbl $sPRIFUldbl /**/
115 ?H:#$d_PRIGUldbl PERL_PRIGldbl $sPRIGUldbl /**/
116 ?H:#$d_PRIEUldbl PERL_PRIEldbl $sPRIEUldbl /**/
117 ?H:#$d_SCNfldbl PERL_SCNfldbl $sSCNfldbl /**/
121 : Check print/scan long double stuff
124 if $test X"$d_longdbl" = X"$define"; then
126 echo "Checking how to print long doubles..." >&4
128 if $test X"$sPRIfldbl" = X -a X"$doublesize" = X"$longdblsize"; then
130 #include <sys/types.h>
138 if eval $compile; then
142 sPRIfldbl='"f"'; sPRIgldbl='"g"'; sPRIeldbl='"e"';
143 sPRIFUldbl='"F"'; sPRIGUldbl='"G"'; sPRIEUldbl='"E"';
144 echo "We will use %f."
150 if $test X"$sPRIfldbl" = X; then
152 #include <sys/types.h>
155 long double d = 123.456;
156 printf("%.3Lf\n", d);
160 if eval $compile; then
164 sPRIfldbl='"Lf"'; sPRIgldbl='"Lg"'; sPRIeldbl='"Le"';
165 sPRIFUldbl='"LF"'; sPRIGUldbl='"LG"'; sPRIEUldbl='"LE"';
166 echo "We will use %Lf."
172 if $test X"$sPRIfldbl" = X; then
174 #include <sys/types.h>
177 long double d = 123.456;
178 printf("%.3llf\n", d);
182 if eval $compile; then
186 sPRIfldbl='"llf"'; sPRIgldbl='"llg"'; sPRIeldbl='"lle"';
187 sPRIFUldbl='"llF"'; sPRIGUldbl='"llG"'; sPRIEUldbl='"llE"';
188 echo "We will use %llf."
194 if $test X"$sPRIfldbl" = X; then
196 #include <sys/types.h>
199 long double d = 123.456;
200 printf("%.3lf\n", d);
204 if eval $compile; then
208 sPRIfldbl='"lf"'; sPRIgldbl='"lg"'; sPRIeldbl='"le"';
209 sPRIFUldbl='"lF"'; sPRIGUldbl='"lG"'; sPRIEUldbl='"lE"';
210 echo "We will use %lf."
216 if $test X"$sPRIfldbl" = X; then
217 echo "Cannot figure out how to print long doubles." >&4
219 sSCNfldbl=$sPRIfldbl # expect consistency
227 '') d_PRIfldbl="$undef"; d_PRIgldbl="$undef"; d_PRIeldbl="$undef";
228 d_PRIFUldbl="$undef"; d_PRIGUldbl="$undef"; d_PRIEUldbl="$undef";
231 *) d_PRIfldbl="$define"; d_PRIgldbl="$define"; d_PRIeldbl="$define";
232 d_PRIFUldbl="$define"; d_PRIGUldbl="$define"; d_PRIEUldbl="$define";
233 d_SCNfldbl="$define";