Commit Graph

559 Commits

Author SHA1 Message Date
Dag-Erling Smørgrav
e6fa0d4308 Set the user context correctly so that cd ~ does the right thing.
PR:		bin/7943 bin/8293
Submitted by:	Bill Fenner <fenner@parc.xerox.com>
Approved by:	jkh
1998-10-13 20:42:01 +00:00
John Polstra
1280c211e2 Fix a bug in dlclose that broke the apache13 port. The list of
loaded objects wasn't being maintained properly.
1998-10-13 03:31:59 +00:00
Jordan K. Hubbard
3a2d923136 This thing has its own puts function, so use it.
Submitted by:	Matthew Jacob <mjacob@nas.nasa.gov>
1998-10-08 23:14:02 +00:00
Kenneth D. Merry
b994e5358d Fix a memory leak in rpc.rstatd that shows up when it's run in standalone
mode.  (i.e., not from inetd)

PR:		bin/8212
1998-10-08 19:59:40 +00:00
Alexander Langer
29a199dbc5 Added double quotes around CHMOD description to prevent garbled output.
PR:		8094
Submitted by:	Christoph Weber-Fahr <wefa@callcenter.systemhaus.net>
1998-09-29 22:02:06 +00:00
John Polstra
b19042b569 Make LD_PRELOAD work for ELF. 1998-09-22 02:09:56 +00:00
David E. O'Brien
be0cde6f10 Remove useless `BINOWN=root' now that it is the default. 1998-09-19 22:42:06 +00:00
Doug Rabson
8223b746c9 Work around an alpha compiler bug.
Reviewed by: Kenneth D. Merry <ken@plutotech.com>
1998-09-16 21:33:14 +00:00
John Polstra
29218d94d3 Fix a bug that showed up when debugging dynamically linked programs.
References from GDB to "printf" and various other functions would
find the versions in the dynamic linker itself, rather than the
versions in the program's libc.  This fix moves the GDB link map
entry for the dynamic linker to the end of the search list, where
its symbols will be found only if they are not found anywhere else.
It was suggested by Doug Rabson, though I implemented it a little
differently.

I personally would prefer to leave the dynamic linker's entry out
of the GDB search list altogether.  But Doug argues that it is
handy there for such things as setting breakpoints on dlopen().
So it stays for now, at least.

Note, if we ever integrate the dynamic linker with libc (which has
several important benefits to recommend it), this whole problem
goes away.
1998-09-16 02:54:08 +00:00
John Polstra
4e25d42aee Make the pathname pointed to by the Obj_Entry structure for the
dynamic linker itself dynamically allocated.  All of them are
supposed to be dynamically allocated, but we cheated before.  It
made gdb unhappy under some circumstances.
1998-09-15 21:07:52 +00:00
Justin T. Gibbs
b2dfb1f906 Update system to new device statistics code.
Submitted by:	"Kenneth D. Merry" <ken@plutotech.com>
		mike@smith.net.au (Mike Smith)
1998-09-15 08:15:30 +00:00
Doug Rabson
75fd258d75 Update to the binutils-2.9.1 PLT format. 1998-09-11 18:31:55 +00:00
Doug Rabson
732b5469fe Add the r_addend of the relocation when processing GLOB_DAT relocations. 1998-09-11 18:30:55 +00:00
Doug Rabson
5e618ef5c8 Fix a cut&paste error which prevented LD_BIND_NOW from working. 1998-09-08 09:47:35 +00:00
John Polstra
a3bd401942 Don't recognize a file as an a.out shared library unless it has at
least 2 version numbers.  This fixes the bug where the dynamic
linker would try to load an ELF shared library if it found one.

Note, this change also fixes the same thing in "ld", because the
code is shared.

For "ld" there is still a problem with ".a" libraries, which cannot
be distinguished by name.  I haven't decided what, if anything, to
do about that.
1998-09-05 20:28:48 +00:00
John Birrell
c2c37821c4 Chaneg MACHINE to MACHINE_ARCH to support MACHINE=pc98.
Remove a couple of unsupported machines.
1998-09-05 08:33:10 +00:00
John Birrell
b576a5aeae Chaneg MACHINE to MACHINE_ARCH to support MACHINE=pc98. 1998-09-05 08:31:10 +00:00
John Polstra
a565ca5920 Implement ldconfig functionality for ELF. The hints are stored in
a different file than the a.out hints, namely, "/var/run/ld-elf.so.hints".
These hints consist only of the directory search path.  There is
no hash table as in the a.out hints, because ELF doesn't have to
search for the file with the highest minor version number.  (It
doesn't have minor version numbers at all.)

A single run of ldconfig updates either the a.out hints or the ELF
hints, but not both.  The set of hints to process is selected in
the usual way, via /etc/objformat, or ${OBJFORMAT}, or the "-aout"
or "-elf" command line option.  The rationale is that you probably
want to search different directories for ELF than for a.out.

"ldconfig -r" is faked up to produce output like we are used to,
except that for ELF there are no minor version numbers.  This should
enable "ldconfig -r" to be used for checking LIB_DEPENDS in ports
even for ELF.

I implemented the ELF functionality in a new source file, with an
eye toward eliminating the a.out code entirely at some point in
the future.
1998-09-05 03:31:00 +00:00
John Birrell
e00072f9f4 Add -lcrypt when building kerberos. 1998-09-05 00:32:27 +00:00
John Birrell
2a356d7348 Enable rtld-elf for build on alpha too. We now have support for shared
libraries on alpha!
1998-09-04 22:55:17 +00:00
Doug Rabson
13575fc46f Add alpha support.
Submitted by: John Birrell <jb@cimlogic.com.au> (with extra hacks by me)
Obtained from: Probably NetBSD
1998-09-04 19:03:57 +00:00
John Polstra
63fac2b9ef Suppress duplicate entries in ldd output. 1998-09-02 02:51:12 +00:00
John Polstra
93df8d681b Style fixes. If it seems like a lot of lines of changes, it's
because I moved some functions.  Mr. Tidy likes them to be in
alphabetical order.
1998-09-02 02:00:20 +00:00
John Polstra
cefbc49679 Handle dlsym(NULL, ...) properly, by searching in the caller's
shared object.  Note, this searches _only_ that object, and not its
needed objects, in accordance with the documentation.

Also fix dlopen(NULL, ...) so that the executable's needed objects
are searched as well as the executable itself.
1998-09-02 01:09:34 +00:00
Wolfram Schneider
acd8019083 Sort cross references. 1998-08-31 16:41:09 +00:00
John Birrell
8deb7ff0b0 BINFORMAT -> OBJFORMAT ready for E-day. 1998-08-30 01:57:55 +00:00
Stephen McKay
166f84746d Pass me the pointy hat with the extra sequins. Just a moment, while I get
it to sit right...

The __error() hack gave out the wrong address.  It returned the address of
errno in ld.so instead of the address of errno in the main program.  Oops.

The hack is now correct, just in time to be obsoleted by elf.
1998-08-22 15:51:41 +00:00
John Birrell
1eab1be09e Update this header to use the revamped elf headers which select Elf32
or Elf64 based on the inclusion of the machine dependent header.

I've left the addition of the extra fields to handle the relocation
structures with addend for a separate commit after jdp has had a chance
to review what I've done. The current change is needed to compile
csu/alpha/crt1.c
1998-08-21 03:29:40 +00:00
John Polstra
9d5aee94a0 Add "-C" to INSTALLFLAGS to install atomically. An elf->elf
installworld dies at this point otherwise, leaving the system
without a dynamic linker.
1998-08-17 04:59:15 +00:00
Mark Murray
448bbb5805 Fix LIBDIR (for aout/ELF). 1998-08-06 21:41:13 +00:00
Peter Wemm
4add781b40 Build mail.local and smrsh (when building sendmail) 1998-08-04 15:32:43 +00:00
Peter Wemm
31655e8ab7 Build sendmail-8.9.1 smrsh 1998-08-04 15:31:31 +00:00
Peter Wemm
9b842df695 Use sendmail-8.9.1 mail.local (with our changes). It has LMTP support. 1998-08-04 15:30:17 +00:00
Bruce Evans
bb6ae0a4a9 Fixed printf format errors. 1998-08-02 16:44:18 +00:00
Poul-Henning Kamp
ee98a93f47 Getty is missing the speed table entry for 230400 baud.
PR:		7280
Reviewed by:	phk
Submitted by:	Craig Leres <leres@ee.lbl.gov>
1998-07-22 05:57:22 +00:00
Steve Price
ef0ccf3dc0 Remove no longer needed FreeBSD specific code.
PR:		5497
Submitted by:	Jacob Bohn Lorensen <jacob@jblhome.ping.mk>
Obtained from:	OpenBSD (indirectly it seems so just to be safe)
1998-07-20 04:52:26 +00:00
Joseph Koshy
d59b62e37b Document the use of lines beginning with a '#' as comment lines.
PR: 5676
1998-07-09 11:38:21 +00:00
Joseph Koshy
d1428a91eb Clean up grammar. Provide proper pathnames for spool directories.
Document dependency on current load average for starting new batch jobs.

PR: 7109
1998-07-01 05:47:58 +00:00
Bruce Evans
1a463b86e9 Fixed printf format errors. 1998-06-30 15:19:51 +00:00
Bruce Evans
375557fcad Don't assume that time_t is long. 1998-06-29 17:06:00 +00:00
Bruce Evans
74b5e3ebd1 Don't assume that time_t is long. Fixed printf format errors. 1998-06-29 16:47:08 +00:00
Stephen McKay
1188f66af7 Since I got no objections to this patch, and no one has offered any
alternative, I present .. ta! da! .. the __error() hack.

This patch to the a.out dynamic loader provides old a.out binaries
with __error() if they are linked with an older libc that lacks it,
but are also linked against a library that needs it.

There is a smaller, tricker hack that takes advantage of the fact
that ld.so has __error() too, courtesy of the new libc, but this
hack is the straightforward version.
1998-06-21 14:22:29 +00:00
Peter Wemm
fc882c32be Fix stupid typo, I had only tested this in elf mode. 1998-06-12 19:45:14 +00:00
Peter Wemm
6c81492cb8 Only build rtld-aout if we're in an a.out build environment. 1998-06-12 16:09:33 +00:00
Peter Wemm
d5431fa51e Activate libbind 1998-06-11 09:17:58 +00:00
Poul-Henning Kamp
1499abeef4 Spelling fixes.
PR:		6903
Reviewed by:	phk
Submitted by:	Josh Gilliam <josh@quick.net>
1998-06-10 12:34:27 +00:00
Brian Somers
32b8743969 Search for libraries in dlopen() when the specified path
contains no ``/''s.
Elf already searches it seems.
Mostly submitted by: Mike Smith <mike@smith.net.au>
1998-06-07 03:53:08 +00:00
John Birrell
f24f28e28c named-xfer can't be linked static due to the duplicated symbols in
libc and libbind.

rpc.rstatd required libkvm.

Only try to build these on i386 for the time being.
1998-06-06 07:09:01 +00:00
Joseph Koshy
3dead0b645 Mention that syslog.conf(5) does not log LOG_FTP messages by default.
PR: 5287
1998-06-05 10:31:24 +00:00
Joerg Wunsch
09caeadeda Use gethostname(3) to obtain the local host name, as opposed to uname(3).
Otherwise the length of the name is limited to 32 characters only.
1998-06-03 20:01:28 +00:00