diff options
author | Andy Dougherty <doughera@lafcol.lafayette.edu> | 1995-04-14 22:32:18 +0000 |
---|---|---|
committer | Andy Dougherty <doughera@lafcol.lafayette.edu> | 1995-04-14 22:32:18 +0000 |
commit | 5d94fbed3754780f11eb4db2d2379544cacb60e1 (patch) | |
tree | 9d1c81cc2141769c76b61c272f84155723edb002 /hints | |
parent | 232e078e289220085e912e3d740ae77767611478 (diff) | |
download | perl-5d94fbed3754780f11eb4db2d2379544cacb60e1.tar.gz |
perl5.001 patch.1d
This is my patch patch.1d for perl5.001. A complete description is
given below, but here are the basic changes.
1. Linux: more tweaks so dynamic loading works under ELF
or (maybe) under dld. There are so many different dld versions
and so many different tool sets, it's hard to be more specific.
2. perl -e '$v=1e19+0' no longer dumps core on Intel x86
processors.
3. pod stuff:
a. Wrapped pod2* translators in a 'SH' wrapper so that they
have the proper path to perl at the top.
b. Fixed pod/ Makefile to call the pod2html translator
correctly. (Why do pod2man and pod2html work differently?)
c. Include latest (Feb 2, 1995) version of pod2html, fresh from
ftp.metronet.com.
4. MakeMaker 4.093.
5. GIMME and installperl patches from Tim Bunce.
6. Miscellaneous hint file updates.
Configure
Allow ' ' to mean 'none' in a few more places. This provides
a way for hint files to set something to an empty value and to
ensure that the empty value will be maintained when config.sh is
reused.
Fix silly ld typo that prevented hint file from actually setting
$ld.
MANIFEST
Now has pod/pod2*.SH.
Makefile.SH
Remove old libperl.a instead of blindly adding to it. Failure to
do this causes a problem if you originally used perl's malloc but
later changed your mind. The old malloc.o would still be in
libperl.a
ext/DynaLoader/dl_dlopen.xs
Use strerror(errno) instead of dlerror for NetBSD.
handy.h
Clarify & rework HAS_BOOL comments and code. No functionality is
changed, but I hope this is easier to follow.
hints/freebsd.sh
hints/isc.sh
hints/linux.sh
hints/netbsd.sh
hints/next_3_0.sh
hints/next_3_2.sh
hints/sco_3.sh
Miscellaneous updates. See the individual comments in the patches.
installperl
Run ranlib on installed .a libraries.
unlink() old versions of files before installing new ones, in
case the old ones are are write-protected.
lib/ExtUtils/MakeMaker.pm
Updated to 4.092 by Andreas Koenig. This features better
selection of shared library versions and shorter command lines for
static linking of new extensions. It is also more robust against
broken csh on Linux. (There's still a glob in the library
selection loop, however.)
I further updated it to 4.093 because I didn't like the
distclean target :-). It's just a sloppy quick fix, but that's
all I have time for now. I've also worked on the library version
selection stuff and the $(CC) command stuff a little more.
lib/TieHash.pm
Overdue removal of ambiguous ${pack} construction.
perl.h
New U_V macro to cast to the UV type (usually unsigned long).
pod/Makefile
Updated.
pod/pod2html.SH
Updated.
Converted to 'SH' wrapper so correct #!/path/to/perl gets used.
pod/pod2latex.SH
pod/pod2man.SH
Converted to 'SH' wrapper so correct #!/path/to/perl gets used.
pp_hot.c
GIMME patch from Tim Bunce.
pp_sys.c
Allow use of F_FREESP fcntl() directive to truncate files.
If HAS_MKDIR is not defined, the stat() call to check the result
of the system "mkdir" call was failing because the filename
pointer no longer pointed to the right location.
sv.c
Protect some (UV) casts by the new U_V() macro.
util.c
New cast_uv() function to support the U_V() macro, if needed.
cast_iv() and cast_uv() no longer assume 32-bit longs.
The various cast_() functions have also been simplified.
Diffstat (limited to 'hints')
-rw-r--r-- | hints/cxux.sh | 2 | ||||
-rw-r--r-- | hints/freebsd.sh | 32 | ||||
-rw-r--r-- | hints/isc.sh | 18 | ||||
-rw-r--r-- | hints/linux.sh | 17 | ||||
-rw-r--r-- | hints/netbsd.sh | 2 | ||||
-rw-r--r-- | hints/next_3_0.sh | 5 | ||||
-rw-r--r-- | hints/next_3_2.sh | 5 | ||||
-rw-r--r-- | hints/powerunix.sh | 2 | ||||
-rw-r--r-- | hints/sco_3.sh | 11 |
9 files changed, 77 insertions, 17 deletions
diff --git a/hints/cxux.sh b/hints/cxux.sh index a4f397c20e..b4125ae6d2 100644 --- a/hints/cxux.sh +++ b/hints/cxux.sh @@ -72,7 +72,7 @@ glibpth="/usr/sde/elf/usr/lib $glibpth" cc='/bin/cc -Xa' cccdlflags='-Zelf -Zpic' ccdlflags='-Zelf -Zlink=dynamic -Wl,-Bexport -u sigaction' -lddlflags='-G' +lddlflags='-Zlink=so' # Configure imagines that stdio.h is "standard", but it really isn't. # Things like the -T and -B file test operators (on file handles) fail when diff --git a/hints/freebsd.sh b/hints/freebsd.sh index 4efca6a043..f0c5433cca 100644 --- a/hints/freebsd.sh +++ b/hints/freebsd.sh @@ -1,4 +1,4 @@ -# Oringal based on info from +# Original based on info from # Carl M. Fongheiser <cmf@ins.infonet.net> # Date: Thu, 28 Jul 1994 19:17:05 -0500 (CDT) # @@ -6,21 +6,45 @@ # Ollivier Robert <Ollivier.Robert@keltia.frmug.fr.net> # Date: Wed, 28 Sep 1994 00:37:46 +0100 (MET) # +# Additional 2.* defines from +# Ollivier Robert <Ollivier.Robert@keltia.frmug.fr.net> +# Date: Sat, 8 Apr 1995 20:53:41 +0200 (MET DST) +# +# FreeBSD has the dynamic loading dl*() functions in /usr/lib/crt0.o, +# so Configure doesn't find them (unless you abandon the nm scan). +# +# The two flags "-fpic -DPIC" are used to indicate a +# will-be-shared object. Configure will guess the -fpic, (and the +# -DPIC is not used by perl proper) but the full define is included to +# be consistent with the FreeBSD general shared libs building process. +# +# setreuid and friends are inherently broken in all versions of FreeBSD. +# + case "$osvers" in 0.*|1.0*) usedl="$undef" ;; -*) d_dlopen="$define" +1.1*) d_dlopen="$define" cccdlflags='-DPIC -fpic' - lddlflags='-Bshareable' + lddlflags='-Bshareable $lddlflags' malloctype='void *' groupstype='int' d_setregid='undef' d_setreuid='undef' d_setrgid='undef' d_setruid='undef' - i_unistd='undef' + ;; +*) + d_dlopen="$define" + cccdlflags='-DPIC -fpic' + lddlflags='-Bshareable $lddlflags' + d_setregid='undef' + d_setreuid='undef' + d_setrgid='undef' + d_setruid='undef' ;; esac # Avoid telldir prototype conflict in pp_sys.c (FreeBSD uses const DIR *) +# Configure should test for this. Volunteers? pp_sys_cflags='ccflags="$ccflags -DHAS_TELLDIR_PROTOTYPE"' diff --git a/hints/isc.sh b/hints/isc.sh index 7c18380f54..0ecdb7ddc9 100644 --- a/hints/isc.sh +++ b/hints/isc.sh @@ -6,9 +6,19 @@ # # Use Configure -Dcc=gcc to use gcc # -set `echo X "$libswanted "| sed -e 's/ c / /'` + +# We don't want to explicitly mention -lc (since we're using POSIX mode.) +# We also don't want -lx (the Xenix compatability libraries.) The only +# thing that it seems to pick up is chsize(), which has been reported to +# not work. chsize() can also be implemented via fcntl() in perl (if you +# define -D_SYSV3). We'll leave in -lPW since it's harmless. Some +# extension might eventually need it for alloca, though perl doesn't use +# it. + +set `echo X "$libswanted "| sed -e 's/ c / /' -e 's/ x / /'` shift libswanted="$*" + case "$cc" in *gcc*) ccflags="$ccflags -posix" ldflags="$ldflags -posix" @@ -17,5 +27,11 @@ case "$cc" in ldflags="$ldflags -Xp" ;; esac + +# You can also include -D_SYSV3 to pick up "traditionally visible" +# symbols hidden by name-space pollution rules. This raises some +# compilation "redefinition" warnings, but they appear harmless. +# ccflags="$ccflags -D_SYSV3" + # Pick up dbm.h in <rpcsvc/dbm.h> ccflags="$ccflags -I/usr/include/rpcsvc" diff --git a/hints/linux.sh b/hints/linux.sh index 71afccd1f9..46059e0731 100644 --- a/hints/linux.sh +++ b/hints/linux.sh @@ -24,9 +24,10 @@ case "$prefix" in esac # Perl expects BSD style signal handling. -ccflags="-D__USE_BSD_SIGNAL $ccflags" +# gcc defines _G_HAVE_BOOL to 1, but doesn't actually supply bool. +ccflags="-D__USE_BSD_SIGNAL -Dbool=char -DHAS_BOOL $ccflags" -# The following functions are gcc built-ins, but the Configure test +# The following functions are gcc built-ins, but the Configure tests # may fail because it doesn't supply a proper prototype. d_memcmp=define d_memcpy=define @@ -68,17 +69,15 @@ if gcc try.c >/dev/null 2>&1 && ./a.out; then You appear to have ELF support. I'll try to use it for dynamic loading. EOM - # Be careful not to overwrite lddlflags, since the user might - # have specified some -L/path options on the Configure command line. - lddlflags="-shared $lddlflags" - ccdlflags='-rdynamic' - so='so' - dlext='so' - ld=gcc + # Configure now handles these automatically. else echo "You don't have an ELF gcc, using dld if available." # We might possibly have a version of DLD around. lddlflags="-r $lddlflags" + # These empty values are so that Configure doesn't put in the + # Linux ELF values. + ccdlflags=' ' + cccdlflags=' ' so='sa' dlext='o' ## If you are using DLD 3.2.4 which does not support shared libs, diff --git a/hints/netbsd.sh b/hints/netbsd.sh index 33a7bf1c00..67cd95c2ad 100644 --- a/hints/netbsd.sh +++ b/hints/netbsd.sh @@ -1,5 +1,5 @@ # hints/netbsd.sh -# netbsd keeps dynamic loading dl*() functions in /lib/crt0.o, +# netbsd keeps dynamic loading dl*() functions in /usr/lib/crt0.o, # so Configure doesn't find them (unless you abandon the nm scan). case "$osvers" in 0.9*|0.8*) diff --git a/hints/next_3_0.sh b/hints/next_3_0.sh index a34d621449..3a50247e9c 100644 --- a/hints/next_3_0.sh +++ b/hints/next_3_0.sh @@ -21,7 +21,12 @@ POSIX_cflags='ccflags="-posix $ccflags"' useposix='undef' ldflags='-u libsys_s' libswanted='dbm gdbm db' +# lddlflags='-r' +# Give cccdlflags an empty value since Configure will detect we are +# using GNU cc and try to specify -fpic for cccdlflags. +cccdlflags=' ' +# i_utime='undef' groupstype='int' direntrytype='struct direct' diff --git a/hints/next_3_2.sh b/hints/next_3_2.sh index aba25b9ed5..887082e2f3 100644 --- a/hints/next_3_2.sh +++ b/hints/next_3_2.sh @@ -5,7 +5,12 @@ ccflags='-DUSE_NEXT_CTYPE' POSIX_cflags='ccflags="-posix $ccflags"' ldflags='-u libsys_s' libswanted='dbm gdbm db' + lddlflags='-r' +# Give cccdlflags an empty value since Configure will detect we are +# using GNU cc and try to specify -fpic for cccdlflags. +cccdlflags=' ' + i_utime='undef' groupstype='int' direntrytype='struct direct' diff --git a/hints/powerunix.sh b/hints/powerunix.sh index f21e6ae8b8..9ce2462315 100644 --- a/hints/powerunix.sh +++ b/hints/powerunix.sh @@ -49,7 +49,7 @@ d_csh='undef' cc='/bin/cc' cccdlflags='-Zpic' ccdlflags='-Zlink=dynamic -Wl,-Bexport' -lddlflags='-G' +lddlflags='-Zlink=so' # Configure imagines that stdio.h is "standard", but it really isn't. # Things like the -T and -B file test operators (on file handles) fail when diff --git a/hints/sco_3.sh b/hints/sco_3.sh index a89ffbec6a..11682e1968 100644 --- a/hints/sco_3.sh +++ b/hints/sco_3.sh @@ -22,9 +22,20 @@ gcc) ccflags="$ccflags -U M_XENIX" optimize="$optimize -O2" ;; +scocc) ;; + *) ccflags="$ccflags -W0 -U M_XENIX" ;; esac i_varargs=undef + +# I have received one report that nm extraction doesn't work if you're +# using the scocc compiler. This system had the following 'myconfig' +# uname='xxx xxx 3.2 2 i386 ' +# cc='scocc', optimize='-O' +usenm='false' + +# If you want to use nm, you'll probably have to use nm -p. The +# following does that for you: nm_opt='-p' |