This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: assertion fails in elf/get-dynamic-info.h
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Chris Aoki <christopher dot aoki at oracle dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Sun, 03 Jun 2018 15:40:25 +0200
- Subject: Re: assertion fails in elf/get-dynamic-info.h
- References: <8F24BEC9-16B4-4AD8-A8D4-42DAC4770111@oracle.com>
* Chris Aoki:
> The glibc wiki includes helpful instructions for
> testing a prototype glibc build. The instructions are
> found under the heading “Compile against glibc in an
> installed location” at the following URL:
>
> https://sourceware.org/glibc/wiki/Testing/Builds#Compile_against_glibc_in_an_installed_location
>
> However, when I have followed these instructions, the
> prototype glibc fails an assertion early in process startup.
> In the file get-dynamic-info.h:
>
> /* Flags must not be set for ld.so. */
> assert (info[DT_RUNPATH] == NULL);
> assert (info[DT_RPATH] == NULL);
>
> As far as I can determine, the above assertions defeat the use
> of the following flags given in the aforementioned instructions:
>
>> SYSROOT=<path to the GLIBC install directory>
>> ...
>> -Wl,-rpath=${SYSROOT}/lib64 \
>> -Wl,--dynamic-linker=${SYSROOT}/lib64/ld-<version>.so \
Do you specify those flags when building glibc itself? That's not
correct. You should use them only when building against a
built-but-not-installed glibc.