[PATCH/RFC] Implement the ability to set the current working directory in GDBserver
Pedro Alves
palves@redhat.com
Thu Aug 31 22:01:00 GMT 2017
On 08/30/2017 06:38 AM, Sergio Durigan Junior wrote:
> I didn't want to implement a gdbserver-specific command (e.g., "set
> remote directory"), which means that my approach has some drawbacks.
> For example, if you want gdbserver to cd to "/abc", but "/abc" doesn't
> exist in the host, then you still won't be able to do this, because
> GDB obviously won't allow you to "cd" into a non-existing dir. So you
> will have to have the same directory structure in both host and target
> if you want to do that.
I'm not sure this is the right approach. I'd like to have a
better understanding of what are the use cases "cd" is used for.
Beyond affecting the inferior's cwd when it is started, what
else is/can "cd" used for? Or IOW, what else does GDB's
current working directory affect?
Thanks,
Pedro Alves
More information about the Gdb-patches
mailing list