This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: r147958 - in /trunk/libstdc++-v3: ChangeLog Mak...


On Fri, 29 May 2009, Tom Tromey wrote:

> Joseph> * Shared libraries are naturally copied from one place to
> Joseph> another, with the -gdb.py file copied along with them.  In
> Joseph> particular, for a cross compiler to a GNU/Linux target they
> Joseph> would be copied to the /usr/lib directory in a sysroot
> Joseph> directory that is the image of the target's root filesystem
> Joseph> and may be referenced with --sysroot in compilation commands,
> Joseph> "set sysroot" in GDB, etc.; in this case, do you want to
> Joseph> require all the share/ files (which may only be of use to a
> Joseph> cross-debugger, not on the target) to be copied there as well?
> 
> I don't follow.  Are you saying you want to copy just the -gdb.py file
> but nothing else, and have it work?  I don't think that is a scenario

The -gdb.py file together with libstdc++.so.6, since as I understand it 
the -gdb.py file has to be alongside the shared library (and you said it 
needs to be named after the actual file that is the library, not a symlink 
to it).  libstdc++.so.6 forms part of the root filesystem image for the 
target system; GDB has various options for locating the host's copy (or 
mount) of the target's root filesystem.  There is no particular reason for 
the pretty printers to need to be part of the target's filesystem when 
they are only needed on the host, but if they are not then they need 
locating relative to the debugger not to the filesystem containing the 
library.

The sysroot mechanism does have limitations regarding this separation of 
what is/isn't needed on the target (the sysroot image on the host may need 
headers and static libraries for compilation that aren't needed on the 
target, for example), but it would be nice to avoid adding to them.  
Though it may be difficult for one scenario of cross-debugging to work 
smoothly without breaking another of using a native debugger on the 
target.

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]