[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: question regarding prelinking (was: (inc. note from dpkg developers) (was: Bug#XXXXXX: (far too many packages) needs rebuilt for prelinking))



On Tue, Jan 14, 2003 at 10:21:54AM -0500, Branden Robinson wrote:
> On Mon, Jan 13, 2003 at 08:33:41PM -0500, Daniel Jacobowitz wrote:
> > > Automatic file modifications, for any means, is a rather serious flaw, imho.
> > 
> > I disagree with your categorical blanket here.  You might want to think
> > about the options a little more, and come back if you have any actual
> > arguments against it.  Meanwhile, once the other issues are resolved, I
> > may just implement the prelink integration as a base for further
> > discussion.
> 
> This is probably a stupid question, but:
> 
> Why couldn't .debs ship already-prelinked objects?  It's not like the
> package build environment doesn't already have all the shared library
> dependencies sitting right there.
> 
> Is it because our shlibdeps are (usually) not exact, and prelinking
> requires having symbol addresses exactly right, which may not be the
> case for, say, libX11.so.6.1 versus libX11.so.6.2, even though the two
> are ABI-compatible?
> 
> Alternatively, if you have a prelinked binary and the prelinking is
> wrong for the depended-upon shared objects on your system, is that a
> fatal error, or does the loader figure this out and say "bah, this
> prelinking is garbage, time to resolve the symbol dependencies the
> old-fashioned way"?  If the latter, then there would seem to be little
> to lose.

Prelinking depends on the entire, and exact, library set on a system. 
The symbol offsets vary in most builds of a library; it's much
finer-grained than ABI-compatibility.  The selected address ranges
depend on how many other libraries you have installed.

If prelinking fails at runtime, the linker will handle it gracefully;
but it's slow and generally undesirable.  Also, we lose the --verify
functionality; there's no way to reproduce the "previous" prelinking
state.

Does that make sense?  Glad to answer any questions, just not sure I'm
coherent right now.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer



Reply to: