Bug 13333

Summary: remove rtld(1) XREF in dlopen.3
Product: Documentation Reporter: Steven G. Kargl <kargl>
Component: Books & ArticlesAssignee: Jeroen Ruigrok van der Werven <asmodai>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description Steven G. Kargl 1999-08-23 16:10:01 UTC
dlopen(3) contains a cross reference to rtld(1).  rtld(1)
appears to be absence on FreeBSD-current.
Comment 1 nik freebsd_committer freebsd_triage 1999-09-26 00:09:43 UTC
On Mon, Aug 23, 1999 at 08:13:13AM -0700, Steven G. Kargl wrote:
> dlopen(3) contains a cross reference to rtld(1).  rtld(1)
> appears to be absence on FreeBSD-current.

rtld(1) is in libexec/rtld-aout.  This is only built if OBJFORMAT == 
aout.

I don't know this chunk of the system.  The proper fix might be to 
have an aout specific dlopen(3) and an ELF specific dlopen(3).  If
you enquire on -hackers we can probably work out the best course of
action.

N
-- 
 [intentional self-reference] can be easily accommodated using a blessed,
 non-self-referential dummy head-node whose own object destructor severs
 the links.
    -- Tom Christiansen in <375143b5@cs.colorado.edu>
Comment 2 Steven G. Kargl 1999-09-26 02:33:31 UTC
Once upon a time, Nik Clayton said:
> On Mon, Aug 23, 1999 at 08:13:13AM -0700, Steven G. Kargl wrote:
> > dlopen(3) contains a cross reference to rtld(1).  rtld(1)
> > appears to be absence on FreeBSD-current.
> 
> rtld(1) is in libexec/rtld-aout.  This is only built if OBJFORMAT == 
> aout.
> 
> I don't know this chunk of the system.  The proper fix might be to 
> have an aout specific dlopen(3) and an ELF specific dlopen(3).  If
> you enquire on -hackers we can probably work out the best course of
> action.
> 

On a FreeBSD-current with the default ELF format, rtld.1 is not installed.
Perhaps, rtld.1 should be installed into share/man/man1aout?
Otherwise, the .Xr in dlopen(3) points to a man page that does not
exist.

-- 
Steve
Comment 3 Alexey M. Zelkin 1999-09-26 04:21:13 UTC
hi,

On Sat, Sep 25, 1999 at 06:40:01PM -0700, Steven G. Kargl wrote:

>  > rtld(1) is in libexec/rtld-aout.  This is only built if OBJFORMAT == 
>  > aout.
>  > 
>  > I don't know this chunk of the system.  The proper fix might be to 
>  > have an aout specific dlopen(3) and an ELF specific dlopen(3).  If
>  > you enquire on -hackers we can probably work out the best course of
>  > action.
>  > 
>  
>  On a FreeBSD-current with the default ELF format, rtld.1 is not installed.
>  Perhaps, rtld.1 should be installed into share/man/man1aout?
>  Otherwise, the .Xr in dlopen(3) points to a man page that does not
>  exist.

You have to install compatXX dist to get this manpage installed. I not sure
that we will do any specific actions with rtld.1 (like installing to man1aout)
because we already have such precendents -- "man kerberos" is good one.

May I close PR ?

-- 
/* Alexey Zelkin                       && phantom@cris.net    */
/* Tavric National University          && phantom@crimea.edu  */
/* http://www.ccssu.crimea.ua/~phantom && phantom@FreeBSD.org */
Comment 4 Steven G. Kargl 1999-09-26 19:52:21 UTC
Once upon a time, Alexey Zelkin said:
> hi,
> 
> On Sat, Sep 25, 1999 at 06:40:01PM -0700, Steven G. Kargl wrote:
> 
> >  > rtld(1) is in libexec/rtld-aout.  This is only built if OBJFORMAT == 
> >  > aout.
> >  > 
> >  > I don't know this chunk of the system.  The proper fix might be to 
> >  > have an aout specific dlopen(3) and an ELF specific dlopen(3).  If
> >  > you enquire on -hackers we can probably work out the best course of
> >  > action.
> >  > 
> >  
> >  On a FreeBSD-current with the default ELF format, rtld.1 is not installed.
> >  Perhaps, rtld.1 should be installed into share/man/man1aout?
> >  Otherwise, the .Xr in dlopen(3) points to a man page that does not
> >  exist.
> 
> You have to install compatXX dist to get this manpage installed. I not sure
> that we will do any specific actions with rtld.1 (like installing to man1aout)
> because we already have such precendents -- "man kerberos" is good one.
> 
> May I close PR ?
> 

Sure.  Close the PR.

I update my systems via "make world", and I went from aout to
elf format via "make update; make world".  I have the equivalent
of the compatXX installed on my system with respect to the binaries
and libraries.  I do not have rtld.1 except in /usr/src/whatever.
The .Xr to rtld(1) in dlopen(3) should be removed on a FreeBSD-current
system.

-- 
Steve
Comment 5 Alexey M. Zelkin 1999-09-27 05:07:26 UTC
hi,

On Sun, Sep 26, 1999 at 11:52:21AM -0700, Steven G. Kargl wrote:

> > May I close PR ?
> > 
> 
> Sure.  Close the PR.
Ok.

> I update my systems via "make world", and I went from aout to
> elf format via "make update; make world".  I have the equivalent
> of the compatXX installed on my system with respect to the binaries
> and libraries.  I do not have rtld.1 except in /usr/src/whatever.
> The .Xr to rtld(1) in dlopen(3) should be removed on a FreeBSD-current
> system.
Just try to "make -DWANT_AOUT world" and you'll get it in /usr/libexec/aout.

-- 
/* Alexey Zelkin                       && phantom@cris.net    */
/* Tavric National University          && phantom@crimea.edu  */
/* http://www.ccssu.crimea.ua/~phantom && phantom@FreeBSD.org */
Comment 6 Alexey M. Zelkin 1999-09-27 11:11:56 UTC
hi,

On Mon, Sep 27, 1999 at 05:38:00AM -0500, Mike Pritchard wrote:

> > > > May I close PR ?

> > > Sure.  Close the PR.
> > Ok.
> 
> Only after removing the refernce to rtld(1) :-).
Maybe we just should replace rtld(1) reference with ld.so(1) reference ?
I not sure that dinamic linker routine dlopen(3) not referencing dinamic
loader (ld.so(1)). Just for note: we still have no elf(5) manpage (but as I
know it's in progress) and we still have no ELF dinamic loader (ld-elf.so(1)).

It means that we will not remove rtld(1) refernce, but create rtld(1)
manpage (which by default will describe ELF format). And current rtld(1)
manpage (a.out) will be installed under share/man/man1aout.

Any correction for MHO ?
 
> rtld(1) isn't installed by default anymore, so it shouldn't be xrefed.
> I've done *many* "make world"'s in the last 5 months or so, and the last time
> rtld(1) was installed was last May (about when I upgraded my main machine
Yes. About this time AOUT world building was tunred off by default.

-- 
/* Alexey Zelkin                       && phantom@cris.net    */
/* Tavric National University          && phantom@crimea.edu  */
/* http://www.ccssu.crimea.ua/~phantom && phantom@FreeBSD.org */
Comment 7 mpp freebsd_committer freebsd_triage 1999-09-27 11:38:00 UTC
> hi,
> 
> On Sun, Sep 26, 1999 at 11:52:21AM -0700, Steven G. Kargl wrote:
> 
> > > May I close PR ?
> > > 
> > 
> > Sure.  Close the PR.
> Ok.

Only after removing the refernce to rtld(1) :-).

rtld(1) isn't installed by default anymore, so it shouldn't be xrefed.
I've done *many* "make world"'s in the last 5 months or so, and the last time
rtld(1) was installed was last May (about when I upgraded my main machine
from 2.2.8 - 4.0-current).  My "virgin" 3.2 machine, and my 3.3-RC 
machine do not have rtld.1 at all.

Yes, rtld(1) can be installed under some configurations, but since
you have to jump through some hoops to do that, we shouldn't xref rtld(1).

(This reminds me, I should probably blow away my current /usr/share/man
just so I can catch these kinds of things with 'manck')

-Mike
  
> > I update my systems via "make world", and I went from aout to
> > elf format via "make update; make world".  I have the equivalent
> > of the compatXX installed on my system with respect to the binaries
> > and libraries.  I do not have rtld.1 except in /usr/src/whatever.
> > The .Xr to rtld(1) in dlopen(3) should be removed on a FreeBSD-current
> > system.
> Just try to "make -DWANT_AOUT world" and you'll get it in /usr/libexec/aout.
> -- 
> /* Alexey Zelkin                       && phantom@cris.net    */
-- 
Mike Pritchard
mpp@FreeBSD.org or mpp@mpp.pro-ns.net
Comment 8 mpp freebsd_committer freebsd_triage 1999-09-27 13:12:09 UTC
> On Mon, Sep 27, 1999 at 05:38:00AM -0500, Mike Pritchard wrote:
> > > > > May I close PR ?
> > > > Sure.  Close the PR.
> > > Ok.
> > 
> > Only after removing the refernce to rtld(1) :-).
> Maybe we just should replace rtld(1) reference with ld.so(1) reference ?
> I not sure that dinamic linker routine dlopen(3) not referencing dinamic
> loader (ld.so(1)). Just for note: we still have no elf(5) manpage (but as I
> know it's in progress) and we still have no ELF dinamic loader (ld-elf.so(1)).

I'm no loader expert, so I'll leave that to someone else.  But,
ld.so(1) also isn't on my 3.2, or 3.3 systems, much less the actual
ld.so binary.  It is on my 4.0 system, but I suspect that is left over 
from when this machine used to be 2.2.8 before I upgraded it to 3.2 then
4.0.  I should really do a fresh 4.0 install on this machine :-(.

Someone is slowly working on an elf(5) man page.

As a side note, link(5) could probably use a "SEE ALSO" section.
  
> It means that we will not remove rtld(1) refernce, but create rtld(1)
> manpage (which by default will describe ELF format). And current rtld(1)
> manpage (a.out) will be installed under share/man/man1aout.

I don't have an rtld command installed on any of my 3.2, 3.3, or 4.0 systems,
so I don't think we need to create a man page for it.
-- 
Mike Pritchard
mpp@FreeBSD.org or mpp@mpp.pro-ns.net
Comment 9 Alexey M. Zelkin 1999-09-27 13:13:27 UTC
hi,

On Mon, Sep 27, 1999 at 07:12:09AM -0500, Mike Pritchard wrote:

> > > Only after removing the refernce to rtld(1) :-).
> > Maybe we just should replace rtld(1) reference with ld.so(1) reference ?
> > I not sure that dinamic linker routine dlopen(3) not referencing dinamic
> > loader (ld.so(1)). Just for note: we still have no elf(5) manpage (but as I
> > know it's in progress) and we still have no ELF dinamic loader (ld-elf.so(1)).
> 
> I'm no loader expert, so I'll leave that to someone else.  But,
Let's ask about this specific question loader maintainer.

[I added Cc: to jdp@FreeBSD.ORG (ld-elf.so maintainer) and hope that he'll
clarify this question]

> ld.so(1) also isn't on my 3.2, or 3.3 systems, much less the actual
> ld.so binary.  It is on my 4.0 system, but I suspect that is left over 
> from when this machine used to be 2.2.8 before I upgraded it to 3.2 then
> 4.0.  I should really do a fresh 4.0 install on this machine :-(.
:-)

> Someone is slowly working on an elf(5) man page.
>
> As a side note, link(5) could probably use a "SEE ALSO" section.
Agreed.

> > It means that we will not remove rtld(1) refernce, but create rtld(1)
> > manpage (which by default will describe ELF format). And current rtld(1)
> > manpage (a.out) will be installed under share/man/man1aout.
> 
> I don't have an rtld command installed on any of my 3.2, 3.3, or 4.0 systems,
> so I don't think we need to create a man page for it.
Why not ? Please take a look on src/libexec/rtld-aout/rtld.1. Pay special
attention to first ".Nm" directive. It says that rtld(1) and ld.so(1) are same
utils and, depends on my output "locate ld-elf.so", I sure that ELF variant of
rtld.1 manpage (ld-elf.so.1) will be added into FreeBSD source tree.

2John Polstra: Am I right ?

-- 
/* Alexey Zelkin                       && phantom@cris.net    */
/* Tavric National University          && phantom@crimea.edu  */
/* http://www.ccssu.crimea.ua/~phantom && phantom@FreeBSD.org */
Comment 10 bill fumerola freebsd_committer freebsd_triage 2000-01-31 19:20:00 UTC
Responsible Changed
From-To: freebsd-doc->jdp

John recently shuffled around the man pages and such for this. 
He's also the resident linker maintainer. 
Comment 11 John Polstra freebsd_committer freebsd_triage 2000-01-31 22:12:14 UTC
State Changed
From-To: open->closed

I have added an ELF version of rtld(1) to FreeBSD. 
. 
Comment 12 Jeroen Ruigrok van der Werven freebsd_committer freebsd_triage 2000-02-01 09:41:26 UTC
Responsible Changed
From-To: jdp->asmodai

I would take care of these pr's about rtld for John.