1
#! /bin/sh /usr/share/dpatch/dpatch-run
2
## 99_configure.dpatch by <glandium@debian.org>
4
## All lines beginning with `## DP:' are a description of the patch.
9
Index: nspr/mozilla/nsprpub/configure
10
===================================================================
11
--- nspr.orig/mozilla/nsprpub/configure 2011-08-12 11:50:08.000000000 +0200
12
+++ nspr/mozilla/nsprpub/configure 2011-08-12 11:52:04.588587080 +0200
13
@@ -1807,6 +1807,57 @@
17
+for ac_declaration in \
19
+ '#include <stdlib.h>' \
20
+ 'extern "C" void std::exit (int) throw (); using std::exit;' \
21
+ 'extern "C" void std::exit (int); using std::exit;' \
22
+ 'extern "C" void exit (int) throw ();' \
23
+ 'extern "C" void exit (int);' \
26
+ cat > conftest.$ac_ext <<EOF
27
+#line 1821 "configure"
28
+#include "confdefs.h"
35
+if { (eval echo configure:1829: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
38
+ echo "configure: failed program was:" >&5
39
+ cat conftest.$ac_ext >&5
44
+ cat > conftest.$ac_ext <<EOF
45
+#line 1839 "configure"
46
+#include "confdefs.h"
52
+if { (eval echo configure:1846: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
56
+ echo "configure: failed program was:" >&5
57
+ cat conftest.$ac_ext >&5
61
+if test -n "$ac_declaration"; then
62
+ echo '#ifdef __cplusplus' >>confdefs.h
63
+ echo $ac_declaration >>confdefs.h
64
+ echo '#endif' >>confdefs.h
70
case "$build:$target" in
72
# Extract the first word of "$ac_prog", so it can be a program name with args.
73
set dummy $ac_prog; ac_word=$2
74
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
75
-echo "configure:1825: checking for $ac_word" >&5
76
+echo "configure:1876: checking for $ac_word" >&5
77
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
78
echo $ac_n "(cached) $ac_c" 1>&6
81
# Extract the first word of "$ac_prog", so it can be a program name with args.
82
set dummy $ac_prog; ac_word=$2
83
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
84
-echo "configure:1860: checking for $ac_word" >&5
85
+echo "configure:1911: checking for $ac_word" >&5
86
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
87
echo $ac_n "(cached) $ac_c" 1>&6
90
# Extract the first word of "$ac_prog", so it can be a program name with args.
91
set dummy $ac_prog; ac_word=$2
92
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
93
-echo "configure:1895: checking for $ac_word" >&5
94
+echo "configure:1946: checking for $ac_word" >&5
95
if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
96
echo $ac_n "(cached) $ac_c" 1>&6
99
# Extract the first word of "$ac_prog", so it can be a program name with args.
100
set dummy $ac_prog; ac_word=$2
101
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
102
-echo "configure:1930: checking for $ac_word" >&5
103
+echo "configure:1981: checking for $ac_word" >&5
104
if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
105
echo $ac_n "(cached) $ac_c" 1>&6
107
@@ -1961,7 +2012,7 @@
108
# Extract the first word of "$ac_prog", so it can be a program name with args.
109
set dummy $ac_prog; ac_word=$2
110
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
111
-echo "configure:1965: checking for $ac_word" >&5
112
+echo "configure:2016: checking for $ac_word" >&5
113
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
114
echo $ac_n "(cached) $ac_c" 1>&6
116
@@ -1996,7 +2047,7 @@
117
# Extract the first word of "$ac_prog", so it can be a program name with args.
118
set dummy $ac_prog; ac_word=$2
119
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
120
-echo "configure:2000: checking for $ac_word" >&5
121
+echo "configure:2051: checking for $ac_word" >&5
122
if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
123
echo $ac_n "(cached) $ac_c" 1>&6
125
@@ -2031,7 +2082,7 @@
126
# Extract the first word of "gcc", so it can be a program name with args.
127
set dummy gcc; ac_word=$2
128
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
129
-echo "configure:2035: checking for $ac_word" >&5
130
+echo "configure:2086: checking for $ac_word" >&5
131
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
132
echo $ac_n "(cached) $ac_c" 1>&6
134
@@ -2061,7 +2112,7 @@
135
# Extract the first word of "cc", so it can be a program name with args.
136
set dummy cc; ac_word=$2
137
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
138
-echo "configure:2065: checking for $ac_word" >&5
139
+echo "configure:2116: checking for $ac_word" >&5
140
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
141
echo $ac_n "(cached) $ac_c" 1>&6
143
@@ -2112,7 +2163,7 @@
144
# Extract the first word of "cl", so it can be a program name with args.
145
set dummy cl; ac_word=$2
146
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
147
-echo "configure:2116: checking for $ac_word" >&5
148
+echo "configure:2167: checking for $ac_word" >&5
149
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
150
echo $ac_n "(cached) $ac_c" 1>&6
152
@@ -2144,7 +2195,7 @@
155
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
156
-echo "configure:2148: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
157
+echo "configure:2199: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
160
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
161
@@ -2155,12 +2206,12 @@
163
cat > conftest.$ac_ext << EOF
165
-#line 2159 "configure"
166
+#line 2210 "configure"
167
#include "confdefs.h"
171
-if { (eval echo configure:2164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
172
+if { (eval echo configure:2215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
173
ac_cv_prog_cc_works=yes
174
# If we can't run a trivial program, we are probably using a cross compiler.
175
if (./conftest; exit) 2>/dev/null; then
176
@@ -2186,12 +2237,12 @@
177
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
179
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
180
-echo "configure:2190: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
181
+echo "configure:2241: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
182
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
183
cross_compiling=$ac_cv_prog_cc_cross
185
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
186
-echo "configure:2195: checking whether we are using GNU C" >&5
187
+echo "configure:2246: checking whether we are using GNU C" >&5
188
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
189
echo $ac_n "(cached) $ac_c" 1>&6
191
@@ -2200,7 +2251,7 @@
195
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2204: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
196
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2255: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
200
@@ -2219,7 +2270,7 @@
201
ac_save_CFLAGS="$CFLAGS"
203
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
204
-echo "configure:2223: checking whether ${CC-cc} accepts -g" >&5
205
+echo "configure:2274: checking whether ${CC-cc} accepts -g" >&5
206
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
207
echo $ac_n "(cached) $ac_c" 1>&6
209
@@ -2259,7 +2310,7 @@
210
# Extract the first word of "$ac_prog", so it can be a program name with args.
211
set dummy $ac_prog; ac_word=$2
212
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
213
-echo "configure:2263: checking for $ac_word" >&5
214
+echo "configure:2314: checking for $ac_word" >&5
215
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
216
echo $ac_n "(cached) $ac_c" 1>&6
218
@@ -2291,7 +2342,7 @@
221
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
222
-echo "configure:2295: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
223
+echo "configure:2346: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
226
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
227
@@ -2302,12 +2353,12 @@
229
cat > conftest.$ac_ext << EOF
231
-#line 2306 "configure"
232
+#line 2357 "configure"
233
#include "confdefs.h"
235
int main(){return(0);}
237
-if { (eval echo configure:2311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
238
+if { (eval echo configure:2362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
239
ac_cv_prog_cxx_works=yes
240
# If we can't run a trivial program, we are probably using a cross compiler.
241
if (./conftest; exit) 2>/dev/null; then
242
@@ -2333,12 +2384,12 @@
243
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
245
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
246
-echo "configure:2337: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
247
+echo "configure:2388: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
248
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
249
cross_compiling=$ac_cv_prog_cxx_cross
251
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
252
-echo "configure:2342: checking whether we are using GNU C++" >&5
253
+echo "configure:2393: checking whether we are using GNU C++" >&5
254
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
255
echo $ac_n "(cached) $ac_c" 1>&6
257
@@ -2347,7 +2398,7 @@
261
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2351: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
262
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:2402: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
266
@@ -2366,7 +2417,7 @@
267
ac_save_CXXFLAGS="$CXXFLAGS"
269
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
270
-echo "configure:2370: checking whether ${CXX-g++} accepts -g" >&5
271
+echo "configure:2421: checking whether ${CXX-g++} accepts -g" >&5
272
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
273
echo $ac_n "(cached) $ac_c" 1>&6
275
@@ -2397,10 +2448,61 @@
279
+for ac_declaration in \
281
+ '#include <stdlib.h>' \
282
+ 'extern "C" void std::exit (int) throw (); using std::exit;' \
283
+ 'extern "C" void std::exit (int); using std::exit;' \
284
+ 'extern "C" void exit (int) throw ();' \
285
+ 'extern "C" void exit (int);' \
288
+ cat > conftest.$ac_ext <<EOF
289
+#line 2462 "configure"
290
+#include "confdefs.h"
297
+if { (eval echo configure:2470: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
300
+ echo "configure: failed program was:" >&5
301
+ cat conftest.$ac_ext >&5
306
+ cat > conftest.$ac_ext <<EOF
307
+#line 2480 "configure"
308
+#include "confdefs.h"
314
+if { (eval echo configure:2487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
318
+ echo "configure: failed program was:" >&5
319
+ cat conftest.$ac_ext >&5
323
+if test -n "$ac_declaration"; then
324
+ echo '#ifdef __cplusplus' >>confdefs.h
325
+ echo $ac_declaration >>confdefs.h
326
+ echo '#endif' >>confdefs.h
332
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
333
-echo "configure:2404: checking how to run the C preprocessor" >&5
334
+echo "configure:2506: checking how to run the C preprocessor" >&5
335
# On Suns, sometimes $CPP names a directory.
336
if test -n "$CPP" && test -d "$CPP"; then
338
@@ -2415,13 +2517,13 @@
339
# On the NeXT, cc -E runs the code through the compiler's parser,
340
# not just through cpp.
341
cat > conftest.$ac_ext <<EOF
342
-#line 2419 "configure"
343
+#line 2521 "configure"
344
#include "confdefs.h"
348
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
349
-{ (eval echo configure:2425: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
350
+{ (eval echo configure:2527: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
351
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
352
if test -z "$ac_err"; then
354
@@ -2432,13 +2534,13 @@
356
CPP="${CC-cc} -E -traditional-cpp"
357
cat > conftest.$ac_ext <<EOF
358
-#line 2436 "configure"
359
+#line 2538 "configure"
360
#include "confdefs.h"
364
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
365
-{ (eval echo configure:2442: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
366
+{ (eval echo configure:2544: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
367
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
368
if test -z "$ac_err"; then
370
@@ -2449,13 +2551,13 @@
372
CPP="${CC-cc} -nologo -E"
373
cat > conftest.$ac_ext <<EOF
374
-#line 2453 "configure"
375
+#line 2555 "configure"
376
#include "confdefs.h"
380
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
381
-{ (eval echo configure:2459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
382
+{ (eval echo configure:2561: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
383
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
384
if test -z "$ac_err"; then
386
@@ -2482,7 +2584,7 @@
387
# Extract the first word of "ranlib", so it can be a program name with args.
388
set dummy ranlib; ac_word=$2
389
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
390
-echo "configure:2486: checking for $ac_word" >&5
391
+echo "configure:2588: checking for $ac_word" >&5
392
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
393
echo $ac_n "(cached) $ac_c" 1>&6
395
@@ -2514,7 +2616,7 @@
396
# Extract the first word of "$ac_prog", so it can be a program name with args.
397
set dummy $ac_prog; ac_word=$2
398
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
399
-echo "configure:2518: checking for $ac_word" >&5
400
+echo "configure:2620: checking for $ac_word" >&5
401
if eval "test \"`echo '$''{'ac_cv_path_AS'+set}'`\" = set"; then
402
echo $ac_n "(cached) $ac_c" 1>&6
404
@@ -2555,7 +2657,7 @@
405
# Extract the first word of "$ac_prog", so it can be a program name with args.
406
set dummy $ac_prog; ac_word=$2
407
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
408
-echo "configure:2559: checking for $ac_word" >&5
409
+echo "configure:2661: checking for $ac_word" >&5
410
if eval "test \"`echo '$''{'ac_cv_path_AR'+set}'`\" = set"; then
411
echo $ac_n "(cached) $ac_c" 1>&6
413
@@ -2596,7 +2698,7 @@
414
# Extract the first word of "$ac_prog", so it can be a program name with args.
415
set dummy $ac_prog; ac_word=$2
416
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
417
-echo "configure:2600: checking for $ac_word" >&5
418
+echo "configure:2702: checking for $ac_word" >&5
419
if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
420
echo $ac_n "(cached) $ac_c" 1>&6
422
@@ -2637,7 +2739,7 @@
423
# Extract the first word of "$ac_prog", so it can be a program name with args.
424
set dummy $ac_prog; ac_word=$2
425
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
426
-echo "configure:2641: checking for $ac_word" >&5
427
+echo "configure:2743: checking for $ac_word" >&5
428
if eval "test \"`echo '$''{'ac_cv_path_STRIP'+set}'`\" = set"; then
429
echo $ac_n "(cached) $ac_c" 1>&6
431
@@ -2678,7 +2780,7 @@
432
# Extract the first word of "$ac_prog", so it can be a program name with args.
433
set dummy $ac_prog; ac_word=$2
434
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
435
-echo "configure:2682: checking for $ac_word" >&5
436
+echo "configure:2784: checking for $ac_word" >&5
437
if eval "test \"`echo '$''{'ac_cv_path_WINDRES'+set}'`\" = set"; then
438
echo $ac_n "(cached) $ac_c" 1>&6
440
@@ -2746,7 +2848,7 @@
443
echo $ac_n "checking for gcc -pipe support""... $ac_c" 1>&6
444
-echo "configure:2750: checking for gcc -pipe support" >&5
445
+echo "configure:2852: checking for gcc -pipe support" >&5
446
if test -n "$GNU_CC" && test -n "$GNU_CXX" && test -n "$GNU_AS"; then
447
echo '#include <stdio.h>' > dummy-hello.c
448
echo 'int main() { printf("Hello World\n"); return 0; }' >> dummy-hello.c
449
@@ -2761,14 +2863,14 @@
451
CFLAGS="$CFLAGS -pipe"
452
cat > conftest.$ac_ext <<EOF
453
-#line 2765 "configure"
454
+#line 2867 "configure"
455
#include "confdefs.h"
458
printf("Hello World\n");
461
-if { (eval echo configure:2772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
462
+if { (eval echo configure:2874: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
466
@@ -2798,16 +2900,16 @@
467
CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction"
469
echo $ac_n "checking whether C compiler supports -fprofile-generate""... $ac_c" 1>&6
470
-echo "configure:2802: checking whether C compiler supports -fprofile-generate" >&5
471
+echo "configure:2904: checking whether C compiler supports -fprofile-generate" >&5
472
cat > conftest.$ac_ext <<EOF
473
-#line 2804 "configure"
474
+#line 2906 "configure"
475
#include "confdefs.h"
481
-if { (eval echo configure:2811: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
482
+if { (eval echo configure:2913: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
484
PROFILE_GEN_CFLAGS="-fprofile-generate"
486
@@ -2830,7 +2932,7 @@
488
if test "$GNU_CC"; then
489
echo $ac_n "checking for visibility(hidden) attribute""... $ac_c" 1>&6
490
-echo "configure:2834: checking for visibility(hidden) attribute" >&5
491
+echo "configure:2936: checking for visibility(hidden) attribute" >&5
492
if eval "test \"`echo '$''{'ac_cv_visibility_hidden'+set}'`\" = set"; then
493
echo $ac_n "(cached) $ac_c" 1>&6
495
@@ -2854,7 +2956,7 @@
498
echo $ac_n "checking for visibility pragma support""... $ac_c" 1>&6
499
-echo "configure:2858: checking for visibility pragma support" >&5
500
+echo "configure:2960: checking for visibility pragma support" >&5
501
if eval "test \"`echo '$''{'ac_cv_visibility_pragma'+set}'`\" = set"; then
502
echo $ac_n "(cached) $ac_c" 1>&6
504
@@ -2907,7 +3009,7 @@
505
# Extract the first word of "$ac_prog", so it can be a program name with args.
506
set dummy $ac_prog; ac_word=$2
507
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
508
-echo "configure:2911: checking for $ac_word" >&5
509
+echo "configure:3013: checking for $ac_word" >&5
510
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
511
echo $ac_n "(cached) $ac_c" 1>&6
513
@@ -3228,14 +3330,14 @@
514
_SAVE_CFLAGS="$CFLAGS"
516
cat > conftest.$ac_ext <<EOF
517
-#line 3232 "configure"
518
+#line 3334 "configure"
519
#include "confdefs.h"
522
return sizeof(__thumb2__);
525
-if { (eval echo configure:3239: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
526
+if { (eval echo configure:3341: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
530
@@ -3297,16 +3399,16 @@
531
_SAVE_CFLAGS="$CFLAGS"
533
echo $ac_n "checking whether the chosen combination of compiler flags ($all_flags) works""... $ac_c" 1>&6
534
-echo "configure:3301: checking whether the chosen combination of compiler flags ($all_flags) works" >&5
535
+echo "configure:3403: checking whether the chosen combination of compiler flags ($all_flags) works" >&5
536
cat > conftest.$ac_ext <<EOF
537
-#line 3303 "configure"
538
+#line 3405 "configure"
539
#include "confdefs.h"
545
-if { (eval echo configure:3310: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
546
+if { (eval echo configure:3412: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
548
echo "$ac_t""yes" 1>&6
550
@@ -3363,17 +3465,17 @@
551
DSO_LDOPTS='-brtl -bnortllib -bM:SRE -bnoentry -bexpall -blibpath:/usr/lib:/lib'
552
ac_safe=`echo "sys/atomic_op.h" | sed 'y%./+-%__p_%'`
553
echo $ac_n "checking for sys/atomic_op.h""... $ac_c" 1>&6
554
-echo "configure:3367: checking for sys/atomic_op.h" >&5
555
+echo "configure:3469: checking for sys/atomic_op.h" >&5
556
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
557
echo $ac_n "(cached) $ac_c" 1>&6
559
cat > conftest.$ac_ext <<EOF
560
-#line 3372 "configure"
561
+#line 3474 "configure"
562
#include "confdefs.h"
563
#include <sys/atomic_op.h>
565
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
566
-{ (eval echo configure:3377: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
567
+{ (eval echo configure:3479: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
568
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
569
if test -z "$ac_err"; then
571
@@ -3529,7 +3631,7 @@
573
MKSHLIB='$(CC) $(DSO_LDOPTS) $(WRAP_MALLOC_LIB) -o $@'
575
- DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
576
+ DSO_LDOPTS='-shared -Wl,-soname -Wl,$(SONAME)'
578
_DEBUG_FLAGS="-g -fno-inline" # most people on linux use gcc/gdb, and that
579
# combo is not yet good at debugging inlined
580
@@ -3569,7 +3671,7 @@
581
_DEBUG_FLAGS='-gdwarf-2 -O0'
582
MKSHLIB='$(CCC) $(DSO_LDOPTS) -o $@'
583
echo $ac_n "checking for gethostbyaddr in -lbind""... $ac_c" 1>&6
584
-echo "configure:3573: checking for gethostbyaddr in -lbind" >&5
585
+echo "configure:3675: checking for gethostbyaddr in -lbind" >&5
586
ac_lib_var=`echo bind'_'gethostbyaddr | sed 'y%./+-%__p_%'`
587
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
588
echo $ac_n "(cached) $ac_c" 1>&6
589
@@ -3577,7 +3679,7 @@
592
cat > conftest.$ac_ext <<EOF
593
-#line 3581 "configure"
594
+#line 3683 "configure"
595
#include "confdefs.h"
596
/* Override any gcc2 internal prototype to avoid an error. */
597
/* We use char because int might match the return type of a gcc2
598
@@ -3588,7 +3690,7 @@
602
-if { (eval echo configure:3592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
603
+if { (eval echo configure:3694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
605
eval "ac_cv_lib_$ac_lib_var=yes"
607
@@ -3714,7 +3816,7 @@
609
MKSHLIB='$(CC) -o $@ $(DSO_LDOPTS)'
611
- DSO_LDOPTS='-shared -Wl,-soname,$(@:$(OBJDIR)/%.so=%.so)'
612
+ DSO_LDOPTS='-shared -Wl,-soname,$(SONAME)'
615
bsdi4.2* | bsdi4.3* | bsdi5.*)
616
@@ -3944,7 +4046,7 @@
618
MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
620
- DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
621
+ DSO_LDOPTS='-shared -Wl,-soname -Wl,$(SONAME)'
622
MDCPUCFG_H=_freebsd.cfg
623
PR_MD_CSRCS=freebsd.c
625
@@ -3974,7 +4076,7 @@
626
#define _USE_BIG_FDS 1
629
- DSO_LDOPTS='-b +h $(notdir $@)'
630
+ DSO_LDOPTS='-b +h $(SONAME)'
632
if test "$OS_TEST" = "ia64"; then
634
@@ -4329,7 +4431,7 @@
636
MKSHLIB='$(CC) $(DSO_LDOPTS) $(WRAP_MALLOC_LIB) -o $@'
638
- DSO_LDOPTS='-shared -Wl,-soname -Wl,$(notdir $@)'
639
+ DSO_LDOPTS='-shared -Wl,-soname -Wl,$(SONAME)'
641
_DEBUG_FLAGS="-g -fno-inline" # most people on linux use gcc/gdb, and that
642
# combo is not yet good at debugging inlined
643
@@ -4777,7 +4879,7 @@
647
- DSO_LDOPTS='-shared -Wl,-soname,$(notdir $@)'
648
+ DSO_LDOPTS='-shared -Wl,-soname,$(SONAME)'
652
@@ -4868,7 +4970,7 @@
656
- MKSHLIB='$(CC) $(DSO_LDOPTS) -Wl,-soname -Wl,$(notdir $@) -o $@'
657
+ MKSHLIB='$(CC) $(DSO_LDOPTS) -Wl,-soname -Wl,$(SONAME) -o $@'
660
OS_LIBS="$OS_LIBS -lsocket"
661
@@ -4942,17 +5044,17 @@
662
_OPTIMIZE_FLAGS="$_OPTIMIZE_FLAGS -Olimit 4000"
663
ac_safe=`echo "machine/builtins.h" | sed 'y%./+-%__p_%'`
664
echo $ac_n "checking for machine/builtins.h""... $ac_c" 1>&6
665
-echo "configure:4946: checking for machine/builtins.h" >&5
666
+echo "configure:5048: checking for machine/builtins.h" >&5
667
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
668
echo $ac_n "(cached) $ac_c" 1>&6
670
cat > conftest.$ac_ext <<EOF
671
-#line 4951 "configure"
672
+#line 5053 "configure"
673
#include "confdefs.h"
674
#include <machine/builtins.h>
676
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
677
-{ (eval echo configure:4956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
678
+{ (eval echo configure:5058: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
679
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
680
if test -z "$ac_err"; then
682
@@ -5002,7 +5104,7 @@
686
- DSO_LDOPTS='-shared -all -expect_unresolved "*" -soname $(notdir $@)'
687
+ DSO_LDOPTS='-shared -all -expect_unresolved "*" -soname $(SONAME)'
691
@@ -5126,7 +5228,7 @@
692
_OPTIMIZE_FLAGS='-O -F Olimit,4000'
695
- DSO_LDOPTS='-G -z defs -h $(@:$(OBJDIR)/%.so=%.so)'
696
+ DSO_LDOPTS='-G -z defs -h $(SONAME)'
698
if test "$OS_RELEASE" = "5.43"; then
699
cat >> confdefs.h <<\EOF
700
@@ -5221,13 +5323,13 @@
701
if `$CC -print-prog-name=ld` -v 2>&1 | grep -c GNU >/dev/null; then
704
- DSO_LDOPTS='-shared -Wl,-h,$(notdir $@),-z,combreloc,-z,defs,-z,ignore'
705
+ DSO_LDOPTS='-shared -Wl,-h,$(SONAME),-z,combreloc,-z,defs,-z,ignore'
706
if test -n "$USE_B_DIRECT"; then
707
DSO_LDOPTS="$DSO_LDOPTS,-Bdirect"
711
- DSO_LDOPTS='-G -h $(notdir $@) -z combreloc -z defs -z ignore'
712
+ DSO_LDOPTS='-G -h $(SONAME) -z combreloc -z defs -z ignore'
713
if test -n "$USE_B_DIRECT"; then
714
DSO_LDOPTS="$DSO_LDOPTS -Bdirect"
716
@@ -5601,7 +5703,7 @@
719
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
720
-echo "configure:5605: checking for dlopen in -ldl" >&5
721
+echo "configure:5707: checking for dlopen in -ldl" >&5
722
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
723
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
724
echo $ac_n "(cached) $ac_c" 1>&6
725
@@ -5609,7 +5711,7 @@
728
cat > conftest.$ac_ext <<EOF
729
-#line 5613 "configure"
730
+#line 5715 "configure"
731
#include "confdefs.h"
732
/* Override any gcc2 internal prototype to avoid an error. */
733
/* We use char because int might match the return type of a gcc2
734
@@ -5620,7 +5722,7 @@
738
-if { (eval echo configure:5624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
739
+if { (eval echo configure:5726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
741
eval "ac_cv_lib_$ac_lib_var=yes"
743
@@ -5637,17 +5739,17 @@
744
echo "$ac_t""yes" 1>&6
745
ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
746
echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
747
-echo "configure:5641: checking for dlfcn.h" >&5
748
+echo "configure:5743: checking for dlfcn.h" >&5
749
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
750
echo $ac_n "(cached) $ac_c" 1>&6
752
cat > conftest.$ac_ext <<EOF
753
-#line 5646 "configure"
754
+#line 5748 "configure"
755
#include "confdefs.h"
758
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
759
-{ (eval echo configure:5651: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
760
+{ (eval echo configure:5753: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
761
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
762
if test -z "$ac_err"; then
764
@@ -5680,13 +5782,13 @@
766
if test $ac_cv_prog_gcc = yes; then
767
echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
768
-echo "configure:5684: checking whether ${CC-cc} needs -traditional" >&5
769
+echo "configure:5786: checking whether ${CC-cc} needs -traditional" >&5
770
if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
771
echo $ac_n "(cached) $ac_c" 1>&6
773
ac_pattern="Autoconf.*'x'"
774
cat > conftest.$ac_ext <<EOF
775
-#line 5690 "configure"
776
+#line 5792 "configure"
777
#include "confdefs.h"
780
@@ -5704,7 +5806,7 @@
782
if test $ac_cv_prog_gcc_traditional = no; then
783
cat > conftest.$ac_ext <<EOF
784
-#line 5708 "configure"
785
+#line 5810 "configure"
786
#include "confdefs.h"
789
@@ -5728,12 +5830,12 @@
790
for ac_func in lchown strerror
792
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
793
-echo "configure:5732: checking for $ac_func" >&5
794
+echo "configure:5834: checking for $ac_func" >&5
795
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
796
echo $ac_n "(cached) $ac_c" 1>&6
798
cat > conftest.$ac_ext <<EOF
799
-#line 5737 "configure"
800
+#line 5839 "configure"
801
#include "confdefs.h"
802
/* System header to define __stub macros and hopefully few prototypes,
803
which can conflict with char $ac_func(); below. */
804
@@ -5756,7 +5858,7 @@
808
-if { (eval echo configure:5760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
809
+if { (eval echo configure:5862: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
811
eval "ac_cv_func_$ac_func=yes"
813
@@ -5807,7 +5909,7 @@
814
# Extract the first word of "$ac_prog", so it can be a program name with args.
815
set dummy $ac_prog; ac_word=$2
816
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
817
-echo "configure:5811: checking for $ac_word" >&5
818
+echo "configure:5913: checking for $ac_word" >&5
819
if eval "test \"`echo '$''{'ac_cv_path_CCACHE'+set}'`\" = set"; then
820
echo $ac_n "(cached) $ac_c" 1>&6
822
@@ -5866,7 +5968,7 @@
823
if test -z "$GNU_CC"; then
825
echo $ac_n "checking for +Olit support""... $ac_c" 1>&6
826
-echo "configure:5870: checking for +Olit support" >&5
827
+echo "configure:5972: checking for +Olit support" >&5
828
if eval "test \"`echo '$''{'ac_cv_hpux_usable_olit_option'+set}'`\" = set"; then
829
echo $ac_n "(cached) $ac_c" 1>&6
831
@@ -5908,7 +6010,7 @@
834
echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6
835
-echo "configure:5912: checking for pthread_create in -lpthreads" >&5
836
+echo "configure:6014: checking for pthread_create in -lpthreads" >&5
839
void *foo(void *v) { return v; }
840
@@ -5930,7 +6032,7 @@
841
echo "$ac_t""no" 1>&6
843
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
844
-echo "configure:5934: checking for pthread_create in -lpthread" >&5
845
+echo "configure:6036: checking for pthread_create in -lpthread" >&5
848
void *foo(void *v) { return v; }
849
@@ -5952,7 +6054,7 @@
850
echo "$ac_t""no" 1>&6
852
echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6
853
-echo "configure:5956: checking for pthread_create in -lc_r" >&5
854
+echo "configure:6058: checking for pthread_create in -lc_r" >&5
857
void *foo(void *v) { return v; }
858
@@ -5974,7 +6076,7 @@
859
echo "$ac_t""no" 1>&6
861
echo $ac_n "checking for pthread_create in -lc""... $ac_c" 1>&6
862
-echo "configure:5978: checking for pthread_create in -lc" >&5
863
+echo "configure:6080: checking for pthread_create in -lc" >&5
866
void *foo(void *v) { return v; }
867
@@ -6092,7 +6194,7 @@
869
ac_cv_have_dash_pthread=no
870
echo $ac_n "checking whether ${CC-cc} accepts -pthread""... $ac_c" 1>&6
871
-echo "configure:6096: checking whether ${CC-cc} accepts -pthread" >&5
872
+echo "configure:6198: checking whether ${CC-cc} accepts -pthread" >&5
873
echo 'int main() { return 0; }' | cat > conftest.c
874
${CC-cc} -pthread -o conftest conftest.c > conftest.out 2>&1
875
if test $? -eq 0; then
876
@@ -6115,7 +6217,7 @@
877
ac_cv_have_dash_pthreads=no
878
if test "$ac_cv_have_dash_pthread" = "no"; then
879
echo $ac_n "checking whether ${CC-cc} accepts -pthreads""... $ac_c" 1>&6
880
-echo "configure:6119: checking whether ${CC-cc} accepts -pthreads" >&5
881
+echo "configure:6221: checking whether ${CC-cc} accepts -pthreads" >&5
882
echo 'int main() { return 0; }' | cat > conftest.c
883
${CC-cc} -pthreads -o conftest conftest.c > conftest.out 2>&1
884
if test $? -eq 0; then
885
@@ -6565,6 +6667,7 @@
893
@@ -6675,15 +6778,34 @@
894
# Transform confdefs.h into DEFS.
895
# Protect against shell expansion while executing Makefile rules.
896
# Protect against Makefile macro expansion.
897
-cat > conftest.defs <<\EOF
898
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
899
-s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
904
-DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' ' | tr '\015' ' '` # Manually modified for MKS support.
907
+# If the first sed substitution is executed (which looks for macros that
908
+# take arguments), then we branch to the quote section. Otherwise,
909
+# look for a macro that doesn't take arguments.
910
+cat >confdef2opt.sed <<\_ACEOF
913
+s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\),-D\1=\2,g
915
+s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\),-D\1=\2,g
919
+s,[ `~#$^&*(){}\\|;'"<>?],\\&,g
925
+# We use echo to avoid assuming a particular line-breaking character.
926
+# The extra dot is to prevent the shell from consuming trailing
927
+# line-breaks from the sub-command output. A line-break within
928
+# single-quotes doesn't work because, if this script is created in a
929
+# platform that uses two characters for line-breaks (e.g., DOS), tr
931
+ac_LF_and_DOT=`echo; echo .`
932
+DEFS=`sed -n -f confdef2opt.sed confdefs.h | tr "$ac_LF_and_DOT" ' .'`
933
+rm -f confdef2opt.sed
936
# Without the "./", some shells look in PATH for config.status.