On Nov 26, 2006, at 4:24 AM, Joel Rees wrote:

or what variable I must have walked on to make perl forget that it was installed under /usr/local ?

Did you add -L/usr/local/lib to the default linker flags when you built your Perl?

I was assuming that, since it would default to linking the executables under /usr/local/bin that putting /usr/local/lib in the search path would just be common sense. But I see from
------------------------------------
beast:/usr/local/share family$ perl -e 'for (@INC) { print $_ . "\n" }'
...
------------------------------------
that /usr/lib isn't in the stock perl's library path either.

Nor should it be. We're talking about GCC's library search path, not Perl's.

Okay, so what's the usual thing to do with stuff like expat? Build expat to install under site_perl/5.8.8/ (or site_perl/5.8.8/expat?)

Why would you want to do that??? It's not a Perl module, it's a C library. The default install for expat is fine.

or maybe link the already installed libraries in there? Or build everything that depends on it by hand?

If you export LDFLAGS and CFLAGS variables with the -L & -I options into your shell environment, most things (including Perl) will pick up on them. Here's an example from my shell startup script ~/.profile. I want to use both locally-installed libraries in /usr/ local, and DarwinPorts-installed libraries in /opt/local, so I add both to my search paths:

        export LDFLAGS="-L/usr/local/lib -L/opt/local/lib"
        export CFLAGS="-I/usr/local/include -I/opt/local/include"

sherm--

Web Hosting by West Virginians, for West Virginians: http://wv-www.net
Cocoa programming in Perl: http://camelbones.sourceforge.net


Reply via email to