| commit | ff000c4dbb2b99531c8cda1e0e67e787ce8aef20 | [log] [tgz] |
|---|---|---|
| author | Tom de Vries <tdevries@suse.de> | Fri Mar 17 13:29:13 2023 +0100 |
| committer | Tom de Vries <tdevries@suse.de> | Fri Mar 17 13:29:13 2023 +0100 |
| tree | bd353f92dd1c39361763cbdd3d0a24cc803bb2af | |
| parent | 92376883a9a18e478228ae14ac8f3b03398fdefa [diff] |
[gdb/testsuite] Add escape_for_host
In gdb_compile we have:
...
lappend new_options "ldflags=-Wl,-rpath,\\\$ORIGIN"
...
and we could improve readability by using {} rather than "":
...
lappend new_options {ldflags=-Wl,-rpath,\$ORIGIN}
...
But rather than manually adding escapes in a string, add a new proc
escape_for_host that care of this for us, allowing us to write:
...
lappend new_options [escape_for_host {ldflags=-Wl,-rpath,$ORIGIN}]
...
Tested on x86_64-linux.