public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Adhemerval Zanella <adhemerval.zanella@linaro.org>
To: Florian Weimer <fweimer@redhat.com>
Cc: libc-alpha@sourceware.org, Szabolcs Nagy <szabolcs.nagy@arm.com>,
	DJ Delorie <dj@redhat.com>
Subject: Re: [PATCH] elf: Fix tests that rely on ld.so.cache for cross-compiling
Date: Fri, 29 Jan 2021 10:59:25 -0300	[thread overview]
Message-ID: <ca22bbfd-b9ea-84ac-b4c8-ab4977a82393@linaro.org> (raw)
In-Reply-To: <87bld7yi7k.fsf@oldenburg.str.redhat.com>



On 29/01/2021 10:40, Florian Weimer wrote:
> * Adhemerval Zanella:
> 
>> For configurations with cross-compiling equal to 'maybe' or 'no',
>> ldconfig will not run and thus the ld.so.cache will not be created
>> on the container testroot.pristine.
>>
>> This lead to failures on both tst-glibc-hwcaps-prepend-cache and
>> tst-ldconfig-ld_so_conf-update on environments where the same
>> compiler can be used to build different ABIs (powerpc and x86 for
>> instance).
>>
>> This patch addas a new test-container hook, ldconfig.run, that
>> triggers a ldconfig execution prior the test execution.
> 
> Commit subject does not match patch: No tests are fixed yet, I think.

The fix is due the new two files:

  elf/tst-glibc-hwcaps-prepend-cache.root/ldconfig.run
  elf/tst-ldconfig-ld_so_conf-update.root/ldconfig.run

Otherwise in such described scenario ld.so.cache won't exist, the
tests will try to load it and failure will set the process to not
try to reload the cache (and then any ld.so.cache update won't change
dlopen outcome).

> 
> Should running ldconfig automatically trigger post-clean activities?

At least in such scenarios the ld.so.cache is already deleted, since
the sync with the pristine will detect the file existence.  Running
the tests with test-container -v I see:

sync /home/azanella/Projects/glibc/build/i686-linux-gnu/testroot.pristine/etc/ to /home/azanella/Projects/glibc/build/i686-linux-gnu/testroot.root/etc/ and delete
-F /home/azanella/Projects/glibc/build/i686-linux-gnu/testroot.root/etc/ld.so.conf
-F /home/azanella/Projects/glibc/build/i686-linux-gnu/testroot.root/etc/ld.so.cache

> 
> Place of the invocation of ldconfig in the patch looks right to me.
> 
> Thanks,
> Florian
> 

  reply	other threads:[~2021-01-29 13:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-29 13:36 Adhemerval Zanella
2021-01-29 13:40 ` Florian Weimer
2021-01-29 13:59   ` Adhemerval Zanella [this message]
2021-01-29 16:38     ` Florian Weimer
2021-01-29 21:23 ` DJ Delorie
2021-01-31 19:11   ` Florian Weimer
2021-01-31 19:29     ` DJ Delorie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ca22bbfd-b9ea-84ac-b4c8-ab4977a82393@linaro.org \
    --to=adhemerval.zanella@linaro.org \
    --cc=dj@redhat.com \
    --cc=fweimer@redhat.com \
    --cc=libc-alpha@sourceware.org \
    --cc=szabolcs.nagy@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).