[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[patches] Linking EGLIBC test programs for debugging



I have a wonky question for the other GLIBC hackers:

I find myself often wanting to link test binaries so that they have
the path of the build tree's dynamic linker hardcoded, and a DT_RPATH
in their dynamic section that hardcodes the build tree directories
containing .so's.  This way you can actually run GDB on them without
too much trouble.  At the moment, I do this by cutting and pasting the
link line, editing the -dynamic-linker argument, and changing the
-rpath-link to -rpath.  But this seems like a pretty basic thing to
want, especially for test programs.  Other people at CodeSourcery have
wanted it.

Does anyone have a nicely packaged way to do this?  I don't see any
nice boundaries or variables in Makeconfig that one could take
advantage of.