binutils-gdb/gdb/testsuite/lib
Tom de Vries 436b5e99c8 [gdb/testsuite] Fix "text file busy" errors with cc-with-tweaks.exp
When using target board cc-with-gdb-index.exp and running tests in parallel,
we run into:
...
gdb compile failed, gdb/contrib/gdb-add-index.sh: line 86: \
  build/gdb/testsuite/gdb.sh: Text file busy
...

The problem is that because of the parallel test run, gdb.sh is created for
every single test-case, and eventually gdb.sh is overwritten while being
executed.

Fix this by creating gdb.sh only once.

Tested on x86_64-linux with target board cc-with-gdb-index.exp, using both a
serial and parallel -j 5 test run.

gdb/testsuite/ChangeLog:

2020-03-06  Tom de Vries  <tdevries@suse.de>

	* lib/gdb.exp (tentative_rename, cached_file): New proc.
	* boards/cc-with-tweaks.exp: Use cached_file to create gdb.sh.
2020-03-06 18:03:01 +01:00
..
ada.exp [gdb/testsuite] Handle missing gnatmake in gnat_runtime_has_debug_info 2020-02-18 10:18:36 +01:00
append_gdb_boards_dir.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
build-piece.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
cache.exp [gdb/testsuite] Ignore pass in gdb_caching_proc 2020-02-19 07:05:13 +01:00
cl_util.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
cl_util.h Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
compile-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
compiler.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
compiler.cc Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
completion-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
cp-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
d-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
data-structures.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
dtrace.exp [gdb/testsuite] Be quiet about untested dtrace-prob.exp 2020-02-19 00:05:40 +01:00
dwarf.exp gdb/testsuite: Allow DWARF assembler to create multiple line tables 2020-01-13 23:56:02 +00:00
fortran.exp gdb.fortran: Allow Flang kind printing in fortran testing 2020-03-04 17:16:52 +05:30
future.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
gdb-guile.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
gdb-python.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
gdb-utils.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
gdb.exp [gdb/testsuite] Fix "text file busy" errors with cc-with-tweaks.exp 2020-03-06 18:03:01 +01:00
gdbserver-support.exp Have testsuite find gdbserver in new location 2020-02-14 14:14:38 -07:00
gen-perf-test.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
gnat_debug_info_test.adb [PATCH] Adjust test gdb.ada/ptype_tagged_param.exp for when GNAT runtime does not have debug info 2019-12-27 21:02:35 -05:00
go.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
memory.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
mi-support.exp [gdb/testsuite] Remove unused globals 2020-02-27 14:27:09 +01:00
objc.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
opencl.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
opencl_hostapp.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
opencl_kernel.cl
pascal.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
pdtrace.in Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
perftest.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
prelink-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
prompt.exp [gdb/testsuite] Remove unused globals 2020-02-27 14:27:09 +01:00
range-stepping-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
read1.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
rust-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
selftest-support.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
set_unbuffered_mode.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
sym-info-cmds.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
trace-support.exp Update libinproctrace.so path in lib/trace-support.exp 2020-02-28 18:58:37 -05:00
tuiterm.exp [gdb/testsuite] Fix spawn in tuiterm.exp 2020-02-27 10:16:00 +01:00
unbuffer_output.c Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00
valgrind.exp Update copyright year range in all GDB files. 2020-01-01 10:20:53 +04:00