On Sun, Apr 5, 2009 at 10:03 PM, Danek Duvall <danek.duvall at sun.com> wrote: > On Sun, Apr 05, 2009 at 06:39:37PM -0500, Mike Gerdts wrote: > >> You may also consider -R../lib. ?This allows fairly arbitrary >> placement of the executable and library (e.g. as in user images) >> without having to resort to evil things like LD_LIBRARY_PATH. > > That won't work; relative paths are relative to the process' cwd. ?What > you'd want to use is $ORIGIN/../lib (where "$ORIGIN" is literal, and would > need to be properly quoted in your Makefile or on the commandline.
Ooops. Thanks for the correction. The method I suggested feels nearly as broken as using LD_LIBRARY_PATH. At the risk of wandering off-topic, is there ever a good reason for -R../lib? Did this behavior change at some point or have I been mistaken for a really long time? -- Mike Gerdts http://mgerdts.blogspot.com/