[flang] Fix test script portability problems.
authorTim Keith <tkeith@nvidia.com>
Tue, 17 Jul 2018 23:43:20 +0000 (16:43 -0700)
committerTim Keith <tkeith@nvidia.com>
Tue, 17 Jul 2018 23:48:50 +0000 (16:48 -0700)
commitbfd07032347480155a62f132110637585df6d8c4
treeb4c6e40bff5253f3598411705d2ac3c3fbfd1072
parentc11a62a3dd988cfaed1728386cd1de16b8dae07b
[flang] Fix test script portability problems.

Allow for bash anywhere on path.

Allow for utilites to be in /bin as well as /usr/bin.

Don't count on sed understanding '\t'.

The options to mktemp aren't portable. Instead just create a per-test
temp directory in the working directory (i.e. <build-dir>/test/semantics).
Setting the KEEP environment variable causes them all to be kept to help
in investigating failures.

Fixes flang-compiler/f18#128.

Original-commit: flang-compiler/f18@3736ceeca83965e3c9e282e92ddb6323523b9e5b
Reviewed-on: https://github.com/flang-compiler/f18/pull/129
flang/test/semantics/test_errors.sh
flang/test/semantics/test_modfile.sh
flang/test/semantics/test_symbols.sh