[testsuite] Fix ld action in run_dump_test

Thomas Preudhomme thomas.preudhomme@linaro.org
Fri Oct 26 13:28:00 GMT 2018


Hi,

run_dump_test proposes an ld action but when trying to make use of it in
a gas test it gave me some Tcl error. It turns out that it references
the check_shared_lib_support procedure and ld_elf_shared_opt variable
both only available in ld-lib.exp. I've thus moved the procedure in
binutils-common.exp and defined the variable needed in the various
default.exp of testsuite that seem to be using run_dump_test.

Since check_shared_lib_support itself references the ld variable not
defined in binutils-common I've defined it from LD in run_dump_test and
fixed LD and LDFLAGS to be defined as expected by run_dump_test in the
various default.exp of testsuite using run_dump_test.

ChangeLog entries are as follows:

*** binutils/ChangeLog ***

2018-10-26  Thomas Preud'homme  <thomas.preudhomme@linaro.org>

* testsuite/config/default.exp: Define LD, LDFLAGS and
ld_elf_shared_opt.
* testsuite/lib/binutils-common.exp (check_shared_lib_support): Moved
from ld-lib.exp.
(run_dump_test): Set ld to $LD.

*** gas/ChangeLog ***

2018-10-26  Thomas Preud'homme  <thomas.preudhomme@linaro.org>

* testsuite/config/default.exp: Define LD, LDFLAGS and
ld_elf_shared_opt.

*** ld/ChangeLog ***

2018-10-26  Thomas Preud'homme  <thomas.preudhomme@linaro.org>

* testsuite/lib/ld-lib.exp (check_shared_lib_support): Moved to
binutils-common.exp.

Testing: Successfully ran tests using the ld action in gas testsuite. No
regression in the testsuite when targeting arm-none-eabi.

Is this ok for master?

Best regards,

Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix_testsuite_ld_action_run_dump_test.patch
Type: text/x-patch
Size: 5297 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20181026/e6d00133/attachment.bin>


More information about the Binutils mailing list