It addresses a number of problems that were present in earlier
versions.
The calls to the "init" and "fini" functions of shared libraries
have been reordered, so that they are called in a strictly nested
fashion, as is required for C++ constructors and destructors. In
addition, the "init" functions are called in better order relative
to each other. That makes the system more tolerant of C++ programs
which depend on a library's being initialized before its clients.
The dynamic linker is now more tolerant of shared libraries in
which dependencies on other shared libraries are incompletely
recorded.
Cleanup in the event of errors has been improved throughout the
dynamic linker. A number of memory leaks were eliminated.
The warning message for a shared library whose minor version number
is too old has been clarified.
The code dealing with the "ld.so.hints" file has been cleaned up.
A bug that caused the hints file to be unmapped incompletely has
been fixed. A different bug that could potentially cause the hints
file to be mapped on top of a loaded object has been fixed.
The code that searches for shared libraries has been cleaned up.
The searching is now more compatible with that done by SunOS and
SVR4. Also, some unnecessary and useless searches of both the
hints file and library directories have been eliminated.
Reviewed by: nate@freebsd.org
last time. I should have pulled these in last time as it allows easier
comparison of "where we are at" relative to the current version from
cyclic.com. Since this is in a 4.4BSD style tree layout, the changelogs
dont exactly match the file layout, but it's close enough.
-mprofiler-epilogue to support it and documented the option.
cc.1:
Listed all the machine-dependent options, even the temporary
debugging ones.
invoke.texi:
Fixed the sense of -mno-ieee-fp.
Sorted the machine-dependent options.
Two uninitialised variables were causing a phkmalloc warning (another notch
in phkmalloc's belt) and caused the full rcstemplate to not be constructed
for commits on freefall.
(Note that you need to have either done a 'make world' or explicitly
run a 'make distrib-dirs' (in src/etc) to get some needed directories in
/usr/share/examples/cvs to be built.)
plus a couple of minor changes..
Some highlights of the new stuff that was not in the old version:
- remote access support.. full checkout/commit/log/etc..
- much improved dead file support..
- speed improvements
- better $CVSROOT handling
- $Name$ support
- support for a "cvsadmin" group to cut down rampant use of "cvs admin -o"
- safer setuid/setgid support
- many bugs fixed.. :-)
- probably some new ones.. :-(
- more that I cannot remember offhand..
plus a couple of minor changes..
Some highlights of the new stuff that was not in the old version:
- remote access support.. full checkout/commit/log/etc..
- much improved dead file support..
- speed improvements
- better $CVSROOT handling
- $Name$ support
- support for a "cvsadmin" group to cut down rampant use of "cvs admin -o"
- safer setuid/setgid support
- many bugs fixed.. :-)
- probably some new ones.. :-(
- more that I cannot remember offhand..
plus a couple of minor changes..
Some highlights of the new stuff that was not in the old version:
- remote access support.. full checkout/commit/log/etc..
- much improved dead file support..
- speed improvements
- better $CVSROOT handling
- $Name$ support
- support for a "cvsadmin" group to cut down rampant use of "cvs admin -o"
- safer setuid/setgid support
- many bugs fixed.. :-)
- probably some new ones.. :-(
- more that I cannot remember offhand..
vector. Now it is called the "symbol caching" vector. This was made
possible and unconfusing by other changes that allowed me to localize
everything having to do with the caching vector in the function
reloc_map().
Switched to alloca() for allocating the caching vector, and eliminated
the special mmap-based allocation routines. Although this was motivated
by performance reasons, it led to significant simplification of the
code, and made it possible to confine the symbol caching code to the
single function reloc_map().
Got rid of the unnecessary and inefficient division loop at the
beginning of rtld().
Reduced the number of calls to getenv("LD_LIBRARY_PATH") to just 1, on
suggestion from <davidg@root.com>.
Added breaks out of the relocation loops when the relocation address is
found to be 0. A relocation address of 0 is caused by an unused
relocation entry. Unused relocation entries are caused by linking a
shared object with the "-Bsymbolic" switch. The runtime linker itself
is linked that way, and the last 40% of its relocation entries are
unused. Thus, breaking out of the loop on the first such entry is a
performance win when ld.so relocates itself. As a side benefit, it
permits removing a test from md_relocate_simple() in
../i386/md-static-funcs.c.
Unused relocation entries in other shared objects (linked with
"-Bsymbolic") caused even bigger problems in previous versions of the
runtime linker. The runtime linker interpreted the unused entries as if
they were valid. That caused it to perform repeated relocations of the
first byte of the shared object. In order to do that, it had to remap
the text segment writable. Breaking out of the loop on the first unused
relocation entry solves that.
Submitted by: John Polstra <jdp@polstra.com>
them. Good greif! This was causing an unimaginable amount of brain-damage!
The mere fact that I griped about $ Log $ in a previous commit (misspelled
deliberately here) meant that the blasted thing was being expanded from the
middle of the log entry as well as the beginning, and using " * All these"
as the comment leader.. AARGH!!!! We *really* need to prevent these from
being expanded! (or remove the magic identifier from the source).
All those $Log$ entries, combined with the whitespace changes are a real
pain.
I'm committing this now, before it's completely finished to get it compiling
and working again ASAP. Some of the FreeBSD specific features are not working
in this commit yet (mainly rlog stuff and $FreeBSD$ support)
This is going to be pretty messy.... Although the vendor import was correct,
both the vendor and release tags are the same "gnu"... :-/
Getting cvs to choose the correct one might be rather interesting...
Note, this is going to be messy.. 2.3 was vendor-branch imported, while
2.6 was done as a delta. Sigh. I'm importing this on a vendor branch so
that it will be easier to deal with next time..
(cvs-1.6 wants rcs-5.7, and rcs-5.7 suggests diffutils-2.7)
Implemented symbol memorizing to reduce the number of calls to lookup(),
making relocation go faster. While relocating a given shared object,
the dynamic linker maintains a memorizing vector that is directly
indexed by the symbol number in the relocation entry. The first time a
given symbol is looked up, the memorizing vector is filled in with a
pointer to the symbol table entry, and a pointer to the so_map of the
shared object in which the symbol was defined. On subsequent uses of
the same symbol, that information is retrieved directly from the
memorizing vector, without calling lookup() again.
A symbol that is referenced in a relocation entry is typically
referenced in many relocation entries, so this memorizing reduces the
number of calls to lookup() dramatically. The overall improvement in
the speed of dynamic linking is also dramatic -- as much as a factor of
three for programs that use many shared libaries.
Submitted by: jdp@polstra.com "John Polstra"
bsd.man.mk when I change the latter to use `::' instead of `:'
dependencies. (bsd.man.mk is included because NOMAN isn't defined.
The maninstall target is supposed to be private to bsd.man.mk so
bsd.man.mk doesn't bother testing if it is already defined. The
test for redefinition in Makefile.dev was too early to do anything.)
Change install target to a beforeinstall target (perhaps there should
be an `extrainstall' target so that Makefiles don't have to abuse
one of beforeinstall, install, realinstall or afterinstall). Don't
bother testing for the install target already being defined. Rewrite
the shell loop as a make loop (this reduces the time for installing
groff from 78s to 65s here).
include this in the old makefiles.
I intended to fix only the private maninstall rule but found a lot of
other bogons and bugs:
- strong resistance to installing the program anywhere other than
${DESTDIR}/usr/bin (first, ../../Makefile.inc was not included.
../Makefile/inc was redundantly included instead. Second, /usr/bin
was hard coded).
- the owner, group and permissions were hard coded.
- the man page was installed twice.
- MANDEPEND wasn't necessary.
- calculations to determine the obj directory weren't necessary.
- there were unnecessary private rules for depend, rcsfreeze and tags.
We don't support the rcsfreeze target.
- there was an extra, bogus, rule for `all'.
The final version uses suffix rules to eliminate the remaining verboseness
involving directories (${.CURDIR}) and to potentially allow multiple
shell programs in one directory.
I got tired of see ``UNIX System Managers Manual''
NOTE: There still a couple of UNIXs left in here. There deal with the
documents. We may want to change there also, even though VERY little of there
even pertain to FreeBSD.
instead of the uninitialized one $(DEVICE).
I hoped these changes would fix some of the large runtime macro processing
bugs, but they seem to only fix some small build-time macro substitution
bugs. E.g., `man ms' now tells you to invoke groff with the flags `-ms'
instead of the bogus flags `-m'; `man groff now tells you that the default
device is `ps' instead of the bogus device `'.
shared library. Formerly, the message looked like this:
ld.so: run: libjdp1.so.1.0: Undefined error: 0
The new message looks like this:
ld.so: run: Can't find shared library "libjdp1.so.1.0"
(Where "run" is the name of the program being executed.)
Submitted by: jdp@polstra.com (John Polstra)
symbols.
An easy example to see this is to develop an X program which links
against Xt, but doesn't add -lX11 to the link line. It will link fine,
but cause run-time errors by ld.so because of missing symbols used by Xt
defined in X11. This patch makes the errors more readable.
Submitted by: jdp@polstra.com (John Polstra)
in the diff. This makes it so that diffs containing files in different
subdirectories that have the same name not patch the same file. For example
a diff with patches to Makefile, des/Makefile, usr.bin/Makefile would attempt
to patch Makefile three times.
"update -jHEAD" when a file has been added on the specified tag.
It doesn't actually make cvs 'handle' it, it just stops it from dying
and leaving stray locks and other wreckage.
This was suggested by the CVS maintainers, and is in cvs-1.5.1-950901.
1: It stops invalid files being created in the cvs tree
2: It stops the import from aborting without mailing a commit message..
The first is simple, it opens the file for reading before touching the
repository, and the second catches the pieces when it hits an unreadable
file rather than just aborting mid-way through, leaving the repository in
a bit mess.
Reviewed by: rgrimes
LINK_SPEC. This solves a problem with the f77 frontend where
aproviding the -r8 option (use REAL*8) caused `cc' to ``forget'' to
pass the entry point to the linker.
Closes PR #gnu/644: f77 -r8
Reviewed by: watanabe@komadori.earth.s.kobe-u.ac.jp (Takeshi WATANABE)
texinfo-3.6 distribution to enable the use of the cursor keys.
Since there is an open problem report (gnu/289) for this it might be
of interest for (some of) you.
I (Joerg) have also added a minor hack that makes info recognizing a
window size change while it has been suspended.
Submitted by: thomas@ghpc8.ihf.rwth-aachen.de (Thomas Gellekum)
bootparam_prot.x was changed for nfsv3 but bootparamd and callbootd
kept using the old version which fortunately failed at build time.
Copying hasn't been necessary since path handling was fixed in
rpcgen/rpc_main.c some time ago.
on dlclose. Also correctly call constructors and destructors for libraries
linked with /usr/lib/c++rt0.o.
Change interpretation of dlopen manpage to call _init() rather than init()
for dlopened objects.
Change c++rt0.o to avoid using atexit to call destructors, allowing dlclose to
call destructors when an object is unloaded.
Change interface between crt0 and ld.so to allow crt0 to call a function on
exit to call destructors for shared libraries explicitly.
These changes are backwards compatible. Old binaries will work with the new
ld.so and new binaries will work with the old ld.so. A version number has
been introduced in the crt0-ld.so interface to allow for future changes.
Reviewed by: GAWollman, Craig Struble <cstruble@singularity.bevc.blacksburg.va.us>
cpio/copyout.c:
Don't output a file if the major, minor or totality of its rdev would be
truncated. Print a message about the skipped files to stderr but don't
report the error in the exit status. cpio's abysmal error handling doesn't
allow continuing after an error, and the rdev checks had to be misplaced
to avoid the problem of returning an error code from routines that return
void.
pax/pax.h:
Use the system macros for major(), minor() and makedev().
pax already checks _all_ output conversions for overflow. This has the
undesirable effect that failure to convert relatively useless fields
such as st_dev for regular files causes files not to be output. pax
doesn't report exactly which fields couldn't be converted.
tar/create.c:
Don't output a file if the major or minor its rdev would be truncated.
Print a message about the skipped files to stderr and report the error
in the exit status.
tar/tar.c:
For not immediately fatal errors, exit with status 1, not the error count
(mod 256).
All:
Minor numbers are limited to 21 bits in pax's ustar format and to 18
bits in archives created by gnu tar (gnu tar wastes 3 bits for padding).
pax's and cpio's ustar format is incompatible with gnu tar's ustar
format for other reasons (see cpio/README).
now safely add a line like
ldconfig -m ${PREFIX}/lib
in ports' Makefiles and packing lists without throwing away some
directories the user may have added.
Submitted by: Mostly by Paul Kranenburg <pk@cs.few.eur.nl>
>Number: 364
>Category: bin
>Synopsis: Interrupting man results in half-baked man page
>Description:
Interrupting man while it is waiting for the page to be formatted
results in a zero length file or a half-baked file.
>How-To-Repeat:
Inetrrupt man while it is formatting a page.
>Fix:
Pay more attention to the return value from the system command.
Submitted by: John Capo <jc@irbs.com>
like "3DBorder" and "[". (NB, the "3DBorder" problem has actually
been intention, it allowed for weird section names like "3xyzzy". We
don't have them, either.)
(Partially) Submitted by: taob@gate.sinica.edu.tw (Brian Tao)
file specifications when they've been extracted (enabling you to get a file
fast if it occurs somewhere close to the front).
Submitted by: Marc van Kempen <wmbfmk@urc.tue.nl>
> * the gdb-4.13 of current (compiled and used under 2.0R) can not attach to my
> own processes (it works only then i'm root - else i get open failed - for my
> own processes)
how embarassing ! This turns out to be a bug in infptrace.c. Below
is a patch. Could some kind soul apply it ?
Submitted by: "Gary J." <garyj@rks32.pcs.dec.com>
of the linker to enforce linking of modules in command line order it is
not possible to link gdb shared with -lcompat.
*HACK ALERT*
Removed -lcompat from LDADD and bring in the necessary functions out of
libcompat as a source module until the linker can be fixed.