On Wednesday 01 December 2004 19:29 CET Tony Finch wrote:
> On Wed, 1 Dec 2004, Justin Mason wrote:
> > hmm, are you using the way documented in the INSTALL file? as far as I
> > know that should work reliably --
> >
> > perl Makefile.PL PREFIX=$HOME
> >
> > I *think* we got that working eventually. agreed, it was tricky due
> > to EU:MM wierdness.
>
> My install script says
>
> perl -pi -e "s|'contact_address' => undef|'contact_address' =>
> '[EMAIL PROTECTED]'|; s|'run_net_tests' =>
> undef|'run_net_tests' => 1|;
> s|\\\$[(]I_LIBDIR[)]|\\\$(INSTALLSITELIB)|;
> s|\\\$[(]PERL_BIN[)]|/usr/bin/perl|" Makefile.PL
Whoa. Apart from the PERL_BIN one (which EU::MM sometimes mixes up) thats
completely the wrong way. The first two you can set with the args
CONTACT_ADDRESS and RUN_NET_TESTS. Replacing I_LIBDIR with INSTALLSITELIB
breaks the whole logic inside Makefile.PL which ensures that the correct
libdir (from perl, site, vendor) is chosen. But more on that below.
> LIBPERL="$PREFIX/lib/perl5"
> PERL="/usr/bin/perl -I$LIBPERL"
> PERLCONF="SYSCONFDIR=$PREFIX/etc INSTALLDIRS=perl"
INSTALLDIRS=perl is very wrong. You must use the "perl" dirs *only* for
modules shipped with Perl itself. For everything else there is "site" (the
default, everything installed from CPAN and manually) and
"vendor" (everything installed by the distributor, ie. you).
Actually, the only difference this should make in our Makefile.PL is the
I_LIBDIR which chosen. Which you override again with the "site" one
above...
> PERLMAN1="INSTALLMAN1DIR=$PREFIX/man/man1"
> PERLMAN3="INSTALLMAN3DIR=$PREFIX/man/man3"
> PERLMAN5="INSTALLMAN5DIR=$PREFIX/man/man5"
> PERLMAKEARGS="PREFIX=$PREFIX LIB=$LIBPERL $PERLCONF $PERLMAN1 $PERLMAN3"
>
> $PERL Makefile.PL PERL="$PERL" FULLPERL="$PERL" $PERLMAKEARGS
>
> I have to blat a couple of things in SpamAssassin's Makefile.PL in order
> to support unattended installs. The other stuff is not necessary for
> SpamAssassin - some of the module dependencies have other path prefix
> configuration problems.
You should really have a look at the file PACKAGING shipped in the
SpamAssassin tarball.
Cheers,
Malte
--
[SGT] Simon G. Tatham: "How to Report Bugs Effectively"
<http://www.chiark.greenend.org.uk/~sgtatham/bugs.html>
[ESR] Eric S. Raymond: "How To Ask Questions The Smart Way"
<http://www.catb.org/~esr/faqs/smart-questions.html>