[PATCH] elf: ld.so --help calls _dl_init_paths without a main map [BZ #27577]
H.J. Lu
hjl.tools@gmail.com
Mon Mar 15 12:48:56 GMT 2021
On Mon, Mar 15, 2021 at 5:28 AM Florian Weimer <fweimer@redhat.com> wrote:
>
> * H. J. Lu:
>
> > On Mon, Mar 15, 2021 at 5:14 AM Florian Weimer <fweimer@redhat.com> wrote:
> >>
> >> * H. J. Lu:
> >>
> >> >> +$(objpfx)tst-rtld-help.out: $(objpfx)ld.so
> >> >> + $(test-wrapper) $(rtld-prefix) --help > $@; \
> >> >> + $(evaluate-test)
> >> >> +$(objpfx)tst-rtld-help-2.out: $(objpfx)tst-rtld-help.out
> >> >> + grep -q 'Legacy HWCAP subdirectories under library search path directories' $<; \
> >> >> + $(evaluate-test)
> >> >
> >> > Can we avoid tst-rtld-help-2.out by grep $@ directly?
> >>
> >> We could use &&, but that would make diagnosing test failures difficult
> >> (as in: did --help fail, or grep?). The separate test seemed the
> >> easiest way.
> >
> > Running "ld.so --help" itself is very straight forward. When there is
> > foo.out, I usually search for foo.
>
> Sorry, I don't understand what your comment means in this context.
> Would you please elaborate?
A single tst-rtld-help.out doesn't make diagnosing ld.so --help
failures difficult.
Multiple output files is confusing.
--
H.J.
More information about the Libc-alpha
mailing list