Vincent Lefevre said:
With the cpan utility, what configuration option need to be modified
to install the man pages of modules at some place?
Installation currently fails with the following error:
mkdir /usr/local/man/man3: Permission denied at /usr/share/perl/5.8/ExtUtils/Install.pm line 112
So, I need to tell cpan to install the man pages in ~/man/man1
and ~/man/man3.
I've debugged this a bit. After the failure of Compress::Raw::Bzip2
installation, /home/vlefevre/.cpan/build/Compress-Raw-Bzip2-2.008/Makefile
contains:
INSTALLMAN1DIR = /home/vlefevre/man/man1
INSTALLMAN3DIR = /home/vlefevre/man/man3
as expected, but in fact, these variables are not taken into account,
probably because the Makefile also has:
INSTALLDIRS = site
DESTDIR =
PREFIX = /usr
PERLPREFIX = $(PREFIX)
SITEPREFIX = $(PREFIX)/local
The following is OK:
INSTALLSITELIB = /home/vlefevre/lib/site_perl
but why do I get the following values in the Makefile?
INSTALLSITEMAN1DIR = $(SITEPREFIX)/man/man1
INSTALLSITEMAN3DIR = $(SITEPREFIX)/man/man3
Then, the command
make install NOECHO=''
gives:
------------------------------------------------------------------------
/bin/sh -c true
/bin/sh -c true
/bin/sh -c true
/bin/sh -c true
/bin/sh -c true
/bin/sh -c true
/usr/bin/perl "-MExtUtils::Command::MM" -e pod2man "--" --section=3pm --perm_rw=644 \
lib/Compress/Raw/Bzip2.pm blib/man3/Compress::Raw::Bzip2.3pm
/bin/sh -c true
umask 02; /usr/bin/perl -MExtUtils::Install -e 'install({@ARGV}, '\''0'\'', 0, '\''0'\'');' \
read /usr/local/lib/perl/5.8.8/auto/Compress/Raw/Bzip2/.packlist \
write /home/vlefevre/lib/site_perl/x86_64-linux-gnu-thread-multi/auto/Compress/Raw/Bzip2/.packlist \
blib/lib /home/vlefevre/lib/site_perl \
blib/arch /home/vlefevre/lib/site_perl/x86_64-linux-gnu-thread-multi \
blib/bin /usr/local/bin \
blib/script /usr/local/bin \
blib/man1 /usr/local/man/man1 \
blib/man3 /usr/local/man/man3
mkdir /usr/local/man/man3: Permission denied at /usr/share/perl/5.8/ExtUtils/Install.pm line 112
make: *** [pure_site_install] Error 13
------------------------------------------------------------------------
If I add INSTALLDIRS=perl to makepl_arg in .cpan/CPAN/MyConfig.pm
(I recall I already had "LIB=~/lib/site_perl INSTALLMAN1DIR=~/man/man1
INSTALLMAN3DIR=~/man/man3"), then everything is OK. This is *really*
confusing and seems to be documented nowhere!