[gdb/testsuite] Normalize gdbserver path name
authorTom de Vries <tdevries@suse.de>
Tue, 15 Nov 2022 14:24:54 +0000 (15:24 +0100)
committerTom de Vries <tdevries@suse.de>
Tue, 15 Nov 2022 14:24:54 +0000 (15:24 +0100)
commitbfa50dc8820416dd362b1c59aabd50633b9bbc67
treec5ee27812e2fcd9652709be42e0f921c85c2e4f2
parent7642de570f32bf901f397c419172cd2ab863ebc6
[gdb/testsuite] Normalize gdbserver path name

Currently for the target board remote-gdbserver-on-localhost we use the
gdbserver file on build, using a file name which includes "/../".

Fix this by using a normalized file name instead.

This allows us to be more restrictive about which files REMOTE_TARGET_USERNAME
can access:
...
-    remote_exec build "chmod go-rx $objdir/outputs"
+    remote_exec build "chmod go-rx $objdir"
...

Tested on x86_64-linux.
gdb/testsuite/boards/gdbserver-base.exp
gdb/testsuite/boards/remote-gdbserver-on-localhost.exp