This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: RFC: Should we link dynamic tests to use the newly built glibc dirctly
On Mon, Oct 8, 2012 at 7:14 AM, Joseph S. Myers <joseph@codesourcery.com> wrote:
> On Sat, 6 Oct 2012, H.J. Lu wrote:
>
>> The current dynamic tests requires
>>
>> ../ld.so --library-path ...
>>
>> to run. It isn't easy to run it under gdb. Should we link dynamic tests
>> to use the newly built glibc directly? Like
>
> Without regard to the specific proposed patch, I think the principle of
> linking them to use the newly built glibc directly is good.
Doing it exposed a ld.so bug:
http://www.sourceware.org/bugzilla/show_bug.cgi?id=14681
I pushed my proposed changes into hjl/dynamic-test branch.
> I think we should go further (in several incremental steps) and actually
> have the testsuite run the tests directly (except for a few that verify
> that running them via executing the dynamic linker itself does work),
> since that's how people will generally use normal programs built with
> glibc. And I'd also have the testsuite setup install glibc into a staging
> directory within the build directory, then link and run tests using that
> copy in which the various files are located relative to each other in the
> same way they would be after actual installation of glibc, to make the
> test environment still closer to that for normal user programs linked with
> glibc (and further simplify the command lines needed to build / run
> programs).
>
Even if we do this, we still need to set DT_RPATH and PT_INTERP
as well as some environment variables to the staging directory.
Otherwise, we can't run tests directly using the newly built glibc.
--
H.J.