outputs.exp: conditionals for split-dwarf and lto plugin
This patch introduces support for conditionals (and expr) expansions
to file lists in proc outest in outputs.exp.
The conditionals machinery is now used to guard files that are only
created by the LTO plugin, or when not using the LTO plugin.
It is also used to avoid special-casing .dwo files: the condition of
when they're expected is now encoded in the list.
Furthermore, the -g flag, that used to be specified along with
$gsplit_dwarf, is now moved into $gsplit_dwarf, so that we don't
compile with -g if -gsplit-dwarf is not needed. This avoids having to
deal with .dSYM directories.
Further removing special cases, $aout is now dealt with in a more
general way, using expr to perform variable/string expansion.
for gcc/testsuite/ChangeLog
PR testsuite/95416
PR testsuite/95577
* gcc.misc-tests/outputs.exp (gsplit_dwarf): Move -g into it.
(outest): Introduce conditionals and string/variable/expr
expansion. Drop special-casing of $aout and .dwo.
(gspd): New conditional. Guard all .dwo files with it.
(ltop): New conditional. Guard files created by the LTO
plugin with it. Guard files created by fat LTO compilation
with its negation. Add a few -fno-use-linker-plugin tests
guarded by it.