This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH][BZ #16046] Static dlopen correction fallout fixes
- From: "Maciej W. Rozycki" <macro at linux-mips dot org>
- To: Andreas Schwab <schwab at suse dot de>
- Cc: Roland McGrath <roland at hack dot frob dot com>, Ondřej Bílka <neleai at seznam dot cz>, Allan McRae <allan at archlinux dot org>, libc-alpha at sourceware dot org
- Date: Tue, 4 Aug 2015 15:53:19 +0100 (BST)
- Subject: Re: [PATCH][BZ #16046] Static dlopen correction fallout fixes
- Authentication-results: sourceware.org; auth=none
- References: <20131017174710 dot GA4993 at domone dot podge> <20131025210328 dot 39E69746B6 at topped-with-meat dot com> <alpine dot DEB dot 1 dot 10 dot 1310252347350 dot 12843 at tp dot orcam dot me dot uk> <20140116203847 dot GB20838 at domone dot podge> <alpine dot DEB dot 1 dot 10 dot 1401172303320 dot 4268 at tp dot orcam dot me dot uk> <20140117233957 dot 64E307441B at topped-with-meat dot com> <alpine dot DEB dot 1 dot 10 dot 1401271320170 dot 4268 at tp dot orcam dot me dot uk> <alpine dot DEB dot 1 dot 10 dot 1401291054290 dot 4268 at tp dot orcam dot me dot uk> <mvmfv3zxkhk dot fsf at hawking dot suse dot de>
On Tue, 4 Aug 2015, Andreas Schwab wrote:
> > Index: glibc-fsf-trunk-quilt/elf/dl-support.c
> > ===================================================================
> > --- glibc-fsf-trunk-quilt.orig/elf/dl-support.c 2014-01-29 11:23:16.000000000 +0000
> > +++ glibc-fsf-trunk-quilt/elf/dl-support.c 2014-01-29 12:12:22.092011006 +0000
> > @@ -91,6 +91,7 @@ static struct link_map _dl_main_map =
> > .l_scope = _dl_main_map.l_scope_mem,
> > .l_local_scope = { &_dl_main_map.l_searchlist },
> > .l_used = 1,
> > + .l_flags_1 = DF_1_NODEFLIB,
> > .l_tls_offset = NO_TLS_OFFSET,
> > .l_serial = 1,
> > };
>
> Why is that needed?
As per the commit message this removes the need for special cases for
static executables in elf/dl-load.c removed with the same commit
(0d23a5c1), while preserving the semantics. Previously the main static
executable was treated as always having DF_1_NODEFLIB set as the check for
`l' being non-NULL excluded the conditional in elf/dl-load.c from being
executed.
What problem are you seeing or trying to solve?
Maciej