@@ -40,7 +40,7 @@ index 6f20c5e..684f369 100644
40
40
or die "Cannot exec $cpp";
41
41
}
42
42
diff --git a/hints/linux.sh b/hints/linux.sh
43
- index ac264c3..fb5a46e 100644
43
+ index ac264c3..3f38ea0 100644
44
44
--- a/hints/linux.sh
45
45
+++ b/hints/linux.sh
46
46
@@ -13,11 +13,14 @@
@@ -123,10 +123,37 @@ index ac264c3..fb5a46e 100644
123
123
ppc*)
124
124
# on ppc, it seems that gcc (at least gcc 3.3.2) isn't happy
125
125
# with -O2 ; so downgrade to -O1.
126
- @@ -143,6 +150,77 @@ case "$optimize" in
126
+ @@ -143,93 +150,78 @@ case "$optimize" in
127
127
;;
128
128
esac
129
129
130
+ - # Are we using ELF? Thanks to Kenneth Albanowski <[email protected] >
131
+ - # for this test.
132
+ - cat >try.c <<'EOM'
133
+ - /* Test for whether ELF binaries are produced */
134
+ - #include <fcntl.h>
135
+ - #include <stdlib.h>
136
+ - #include <unistd.h>
137
+ - main() {
138
+ - char buffer[4];
139
+ - int i=open("a.out",O_RDONLY);
140
+ - if(i==-1)
141
+ - exit(1); /* fail */
142
+ - if(read(i,&buffer[0],4)<4)
143
+ - exit(1); /* fail */
144
+ - if(buffer[0] != 127 || buffer[1] != 'E' ||
145
+ - buffer[2] != 'L' || buffer[3] != 'F')
146
+ - exit(1); /* fail */
147
+ - exit(0); /* succeed (yes, it's ELF) */
148
+ - }
149
+ - EOM
150
+ - if ${cc:-gcc} try.c >/dev/null 2>&1 && $run ./a.out; then
151
+ - cat <<'EOM' >&4
152
+ -
153
+ - You appear to have ELF support. I'll try to use it for dynamic loading.
154
+ - If dynamic loading doesn't work, read hints/linux.sh for further information.
155
+ - EOM
156
+ -
130
157
+ # Ubuntu 11.04 (and later, presumably) doesn't keep most libraries
131
158
+ # (such as -lm) in /lib or /usr/lib. So we have to ask gcc to tell us
132
159
+ # where to look. We don't want gcc's own libraries, however, so we
@@ -142,10 +169,16 @@ index ac264c3..fb5a46e 100644
142
169
+ # plibpth to bypass this check.
143
170
+ if [ -x /usr/bin/gcc ] ; then
144
171
+ gcc=/usr/bin/gcc
145
- + else
172
+ else
173
+ - cat <<'EOM' >&4
146
174
+ gcc=gcc
147
175
+ fi
148
- +
176
+
177
+ - You don't have an ELF gcc. I will use dld if possible. If you are
178
+ - using a version of DLD earlier than 3.2.6, or don't have it at all, you
179
+ - should probably upgrade. If you are forced to use 3.2.4, you should
180
+ - uncomment a couple of lines in hints/linux.sh and restart Configure so
181
+ - that shared libraries will be disallowed.
149
182
+ case "$plibpth" in
150
183
+ '') plibpth=`LANG=C LC_ALL=C $gcc $ccflags $ldflags -print-search-dirs | grep libraries |
151
184
+ cut -f2- -d= | tr ':' $trnl | grep -v 'gcc' | sed -e 's:/$::'`
@@ -154,7 +187,54 @@ index ac264c3..fb5a46e 100644
154
187
+ plibpth="$*"
155
188
+ ;;
156
189
+ esac
157
- +
190
+
191
+ - EOM
192
+ - lddlflags="-r $lddlflags"
193
+ - # These empty values are so that Configure doesn't put in the
194
+ - # Linux ELF values.
195
+ - ccdlflags=' '
196
+ - cccdlflags=' '
197
+ - ccflags="-DOVR_DBL_DIG=14 $ccflags"
198
+ - so='sa'
199
+ - dlext='o'
200
+ - nm_so_opt=' '
201
+ - ## If you are using DLD 3.2.4 which does not support shared libs,
202
+ - ## uncomment the next two lines:
203
+ - #ldflags="-static"
204
+ - #so='none'
205
+ -
206
+ - # In addition, on some systems there is a problem with perl and NDBM
207
+ - # which causes AnyDBM and NDBM_File to lock up. This is evidenced
208
+ - # in the tests as AnyDBM just freezing. Apparently, this only
209
+ - # happens on a.out systems, so we disable NDBM for all a.out linux
210
+ - # systems. If someone can suggest a more robust test
211
+ - # that would be appreciated.
212
+ - #
213
+ - # More info:
214
+ - # Date: Wed, 7 Feb 1996 03:21:04 +0900
215
+ - # From: Jeffrey Friedl <[email protected] >
216
+ - #
217
+ - # I tried compiling with DBM support and sure enough things locked up
218
+ - # just as advertised. Checking into it, I found that the lockup was
219
+ - # during the call to dbm_open. Not *in* dbm_open -- but between the call
220
+ - # to and the jump into.
221
+ - #
222
+ - # To make a long story short, making sure that the *.a and *.sa pairs of
223
+ - # /usr/lib/lib{m,db,gdbm}.{a,sa}
224
+ - # were perfectly in sync took care of it.
225
+ - #
226
+ - # This will generate a harmless Whoa There! message
227
+ - case "$d_dbm_open" in
228
+ - '') cat <<'EOM' >&4
229
+ -
230
+ - Disabling ndbm. This will generate a Whoa There message in Configure.
231
+ - Read hints/linux.sh for further information.
232
+ - EOM
233
+ - # You can override this with Configure -Dd_dbm_open
234
+ - d_dbm_open=undef
235
+ - ;;
236
+ - esac
237
+ - fi
158
238
+ # libquadmath is sometimes installed as gcc internal library,
159
239
+ # so contrary to our usual policy of *not* looking at gcc internal
160
240
+ # directories we now *do* look at them, in case they contain
@@ -171,7 +251,8 @@ index ac264c3..fb5a46e 100644
171
251
+ done
172
252
+ ;;
173
253
+ esac
174
- +
254
+
255
+ - rm -f try.c a.out
175
256
+ case "$libc" in
176
257
+ '')
177
258
+ # If you have glibc, then report the version for ./myconfig bug reporting.
@@ -197,29 +278,13 @@ index ac264c3..fb5a46e 100644
197
278
+ done
198
279
+ ;;
199
280
+ esac
200
- +
201
- # Are we using ELF? Thanks to Kenneth Albanowski <
[email protected] >
202
- # for this test.
203
- cat >try.c <<'EOM'
204
- @@ -163,7 +241,7 @@ main() {
205
- exit(0); /* succeed (yes, it's ELF) */
206
- }
207
- EOM
208
- - if ${cc:-gcc} try.c >/dev/null 2>&1 && $run ./a.out; then
209
- + if ${cc:-gcc} $ccflags $ldflags try.c >/dev/null 2>&1 && $run ./a.out; then
210
- cat <<'EOM' >&4
211
-
212
- You appear to have ELF support. I'll try to use it for dynamic loading.
213
- @@ -229,7 +307,7 @@ fi
214
-
215
- rm -f try.c a.out
216
281
217
282
- if /bin/sh -c exit; then
218
283
+ if ${sh:-/bin/sh} -c exit; then
219
284
echo ''
220
285
echo 'You appear to have a working bash. Good.'
221
286
else
222
- @@ -296,7 +374 ,7 @@ fi
287
+ @@ -296,7 +288 ,7 @@ fi
223
288
#'osfmach3ppc') ccdlflags='-Wl,-E' ;;
224
289
#esac
225
290
@@ -228,7 +293,7 @@ index ac264c3..fb5a46e 100644
228
293
sparc*)
229
294
case "$cccdlflags" in
230
295
*-fpic*) cccdlflags="`echo $cccdlflags|sed 's/-fpic/-fPIC/'`" ;;
231
- @@ -311,24 +389 ,62 @@ esac
296
+ @@ -311,24 +303 ,62 @@ esac
232
297
# version of -lgdbm which is a bad idea. So if we have 'nm'
233
298
# make sure it can read the file
234
299
# NI-S 2003/08/07
@@ -302,7 +367,7 @@ index ac264c3..fb5a46e 100644
302
367
if echo $libswanted | grep -v pthread >/dev/null
303
368
then
304
369
set `echo X "$libswanted "| sed -e 's/ c / pthread c /'`
305
- @@ -375,16 +491 ,6 @@ $define|true|[yY]*)
370
+ @@ -375,16 +405 ,6 @@ $define|true|[yY]*)
306
371
;;
307
372
esac
308
373
@@ -319,7 +384,7 @@ index ac264c3..fb5a46e 100644
319
384
# If using g++, the Configure scan for dlopen() and (especially)
320
385
# dlerror() might fail, easier just to forcibly hint them in.
321
386
case "$cc" in
322
- @@ -408,7 +514 ,7 @@ then
387
+ @@ -408,7 +428 ,7 @@ then
323
388
DBLIB="$DBDIR/libdb.so"
324
389
if [ -f $DBLIB ]
325
390
then
@@ -387,18 +452,6 @@ index 030db74..0d15a40 100644
387
452
}
388
453
}
389
454
390
- diff --git a/patchlevel.h b/patchlevel.h
391
- index 82f11ed..2254fd1 100644
392
- --- a/patchlevel.h
393
- +++ b/patchlevel.h
394
- @@ -121,6 +121,7 @@ hunk.
395
- #if !defined(PERL_PATCHLEVEL_H_IMPLICIT) && !defined(LOCAL_PATCH_COUNT)
396
- static const char *local_patches[] = {
397
- NULL
398
- + ,"Devel::PatchPerl 1.38"
399
- ,NULL
400
- };
401
-
402
455
diff --git a/perl.c b/perl.c
403
456
index 82e5538..b9e02fe 100644
404
457
--- a/perl.c
0 commit comments