Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Gary Benson <gbenson@redhat.com>
To: gdb-patches@sourceware.org
Cc: Pedro Alves <palves@redhat.com>,
	       Sandra Loosemore <sandra@codesourcery.com>,
	Paul_Koning@Dell.com,
	       Jan Kratochvil <jan.kratochvil@redhat.com>,
	       Joel Brobecker <brobecker@adacore.com>
Subject: [PATCH 0/5] Change how "target:" gets into filenames
Date: Tue, 28 Jul 2015 15:36:00 -0000	[thread overview]
Message-ID: <1438097772-31480-1-git-send-email-gbenson@redhat.com> (raw)

Hi all,

This is a continuation of this thread:
https://sourceware.org/ml/gdb/2015-07/msg00038.html

In summary, GDB since April automatically locates and fetches
binary files from remote systems.  A number of people would
like this not to happen.

This automation hinged on changing the default sysroot from ""
to "target:".  This series reverts that change, and instead
updates solib_find_1 to use "target:" as the sysroot where it
would be necessary to access the files.

Most use cases proceed as before, but with this series the
files are *not* transferred if you supply GDB an executable
either on the command line or with a "file" command.

Remote examples:

  $ gdb ./a.out
  (gdb) target remote :9999
  # no "target:" prefix (=no files transferred)

  $ gdb
  (gdb) file a.out
  (gdb) target remote :9999
  # no "target:" prefix (=no files transferred)

  $ gdb
  (gdb) target remote :9999
  # "target:" prefix, files transferred

Aside from fixing this issue, GDB with this change has the advantage
that users don't see the "target:" prefix unless either they are
using GDB in a way that didn't work in 7.9 (remote target without
"file" and "set sysroot" commands, containerized target) or they
explitictly set it themselves (e.g. "set sysroot target:/foo/bar").

I've Cc'd Joel because, if this is the way we want to go, it would
be nice to have this in 7.10 as it minimises the difference from
7.9 and would avoid having 7.10 introduce the "target:" sysroot
only for 7.11 to remove it.

I've Cc'd Jan because he's working on making sysroot be a search
path. (defaulting to something like "/", "target:/").  I think you
could do that from this series by treating the auto-target-prefix
boolean as a stepping-stone that could be removed.  If nothing else
this series is a map of the places you'll need to update :)

Built and regtested on RHEL 6.6 x86_64.

Opinions?  (Should I commit this, and if so where?)

Cheers,
Gary

--
http://gbenson.net/


             reply	other threads:[~2015-07-28 15:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-28 15:36 Gary Benson [this message]
2015-07-28 15:36 ` [PATCH 4/5] Use TARGET_FILENAME_PREFIX as the system root in some cases Gary Benson
2015-07-28 15:40   ` Eli Zaretskii
2015-07-28 15:36 ` [PATCH 3/5] Rename TARGET_SYSROOT_PREFIX as TARGET_FILENAME_PREFIX Gary Benson
2015-07-28 15:36 ` [PATCH 2/5] Update Valgrind GDB special case Gary Benson
2015-07-28 15:45 ` [PATCH 5/5] Update exec_file_find callers Gary Benson
2015-07-28 15:45 ` [PATCH 1/5] Revert default system root back to "" Gary Benson
2015-07-28 15:58   ` Eli Zaretskii
2015-07-29 17:04 ` [PATCH 0/5] Change how "target:" gets into filenames Jan Kratochvil

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1438097772-31480-1-git-send-email-gbenson@redhat.com \
    --to=gbenson@redhat.com \
    --cc=Paul_Koning@Dell.com \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jan.kratochvil@redhat.com \
    --cc=palves@redhat.com \
    --cc=sandra@codesourcery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox