think that this could be done by specifying LDFLAGS="-R$ORIGIN/../lib" but while it does work for C, I'm not able to do this with Perl/CPAN. How can I do?

It works for perl too, simply export LDFLAGS=... or edit Makefile.PL and add it to ExtUtils::MakeMaker::WriteMakefile

Perl/"CPAN" does not override this, so export LDFLAGS= or any other linker/compiler options should just work, every time :)

http://perl5.git.perl.org/perl.git?a=search&h=HEAD&st=grep&s=rpath
http://perl5.git.perl.org/perl.git?a=search&h=HEAD&st=grep&s=rpath
http://www.gnu.org/software/libtool/manual/libtool.html#index-LDFLAGS-107

http://www.linuxsampler.org/msys.html

Re: Installing iodbc 0.1 via CPAN (or other means) on Mac OS 10.6

So you could, change Rpath after the fact

chrpath- a tool to change the DT_RPATH attribute of an executable and convert it to an DT_RUNPATH attribute
patchELF - a small utility to modify the dynamic linker and DT_RUNPATH attribute of ELF executables.

set it through ldflags

export LDFLAGS=...

link against static versions of libxml/libxslt/libexpat...

./configure --enable-static --disable-shared
./configure --enable-static --disable-shared CFLAGS=-static-libgcc prefix=/my/install/prefix
$config{LIBS}='-l...libxml2.a -l...libiconv.a'; $config{INC}='-I...include/libxml2'; $config{DEFINE} =' -DLIBXML_STATIC '; WriteMakefile( %INFOS, %config, );

Or when setting up your development enviroment, mirror your target directory structure with symbolic links

ln -s itsmylocal/xmltv /.../xmltv

In reply to Re: Editing RPATH of Perl module XML::Parser by Anonymous Monk
in thread Editing RPATH of Perl module XML::Parser by virtualdj

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.