]> git.ipfire.org Git - thirdparty/gcc.git/commit
modula-2, testsuite: Make libs and interfaces consistent.
authorIain Sandoe <iain@sandoe.co.uk>
Sat, 14 Jan 2023 19:33:52 +0000 (19:33 +0000)
committerIain Sandoe <iain@sandoe.co.uk>
Thu, 19 Jan 2023 17:08:47 +0000 (17:08 +0000)
commitf8cb07a7a445c61a704476746b971ddd967627aa
tree0ec734af0b49a69fb73d3b35a5bbd01cf9e77041
parent5115508919325bfa78bb894acdb468c173637982
modula-2, testsuite: Make libs and interfaces consistent.

In some case the libraries list was being set before gm2_init_xxx was
called.  In some cases it was omitted - this could lead to a difference
between the link libs and the interfaces (the effect of this would be
dependent on the order in which the .exps were run, which makes it also
depend on the -j and the system).

To avoid a mismatch between the module include paths and the added libs
we now make sure that they are both added in the gm_init_xxxx functions
(if finer control over granularity is needed, then we should as a TODO
add a generic gm_init_xxx that takes a library list and ensures that the
imports and libs are matched in the same order).

Also we cannot use a default variable in tcl if the source for that
variable could be absent, but something else follows, there is no way
to put an empty placeholder in.

Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>
gcc/testsuite/ChangeLog:

* gm2/complex/run/pass/complex-run-pass.exp: Remove gm2_link_lib.
* gm2/iso/run/pass/iso-run-pass.exp: Likewise.
* gm2/link/externalscaffold/pass/link-externalscaffold-pass.exp:
* gm2/pimlib/logitech/run/pass/pimlib-logitech-run-pass.exp: Likewise.
* gm2/pimlib/run/pass/pimlib-run-pass.exp: Likewise.
* gm2/projects/iso/run/pass/halma/projects-iso-run-pass-halma.exp:
Likewise.
* gm2/projects/iso/run/pass/hello/projects-iso-run-pass-hello.exp:
Likewise.
* gm2/projects/pim/run/pass/hello/projects-pim-run-pass-hello.exp:
Likewise.
* gm2/sets/run/pass/sets-run-pass.exp: Likewise.
* gm2/switches/none/run/pass/gm2-none.exp: Likewise.
* gm2/switches/pic/run/pass/switches-pic-run-pass.exp: Likewise.
* gm2/projects/pim/run/pass/random/projects-pim-run-pass-random.exp:
Likewise, and also ensure that the -g option is appended to avoid it
being taken as a path.
* lib/gm2.exp: Ensure for each gm2_init_xxxx function that the set of
libraries added matches the set of -I and -L options.
13 files changed:
gcc/testsuite/gm2/complex/run/pass/complex-run-pass.exp
gcc/testsuite/gm2/iso/run/pass/iso-run-pass.exp
gcc/testsuite/gm2/link/externalscaffold/pass/link-externalscaffold-pass.exp
gcc/testsuite/gm2/pimlib/logitech/run/pass/pimlib-logitech-run-pass.exp
gcc/testsuite/gm2/pimlib/run/pass/pimlib-run-pass.exp
gcc/testsuite/gm2/projects/iso/run/pass/halma/projects-iso-run-pass-halma.exp
gcc/testsuite/gm2/projects/iso/run/pass/hello/projects-iso-run-pass-hello.exp
gcc/testsuite/gm2/projects/pim/run/pass/hello/projects-pim-run-pass-hello.exp
gcc/testsuite/gm2/projects/pim/run/pass/random/projects-pim-run-pass-random.exp
gcc/testsuite/gm2/sets/run/pass/sets-run-pass.exp
gcc/testsuite/gm2/switches/none/run/pass/gm2-none.exp
gcc/testsuite/gm2/switches/pic/run/pass/switches-pic-run-pass.exp
gcc/testsuite/lib/gm2.exp