Subject: default @INC and where to install perl modules? (was Re: libbonobo
To: None <tech-pkg@netbsd.org>
From: Jeremy C. Reed <reed@reedmedia.net>
List: tech-pkg
Date: 02/12/2005 21:07:07
Maybe instead of installing perl modules to specific version directories
they could be installed to generic lib/perl5 or lib/perl5/site_perl.
(I am not sure what "site_perl" means.)
For example, on a Debian system, the @INC defaults to:
/usr/local/lib/perl/5.6.1
/usr/local/share/perl/5.6.1
/usr/lib/perl5
/usr/share/perl5
/usr/lib/perl/5.6.1
/usr/share/perl/5.6.1
/usr/local/lib/site_perl
. <-- default directory
By default, these directories really exist:
/usr/share/perl5
/usr/lib/perl/5.6.1
/usr/share/perl/5.6.1
and depending on what is installed:
/usr/lib/perl5
For example, a libdbd-mysql-perl package uses:
/usr/lib/perl5/Mysql/Statement.pm
/usr/lib/perl5/DBD/mysql.pm
And libmime-base64-perl (p5-MIME-Base64) package has:
/usr/lib/perl5/MIME/Base64.pm
/usr/lib/perl5/MIME/QuotedPrint.pm
/usr/lib/perl5/auto/MIME/Base64/Base64.so
/usr/lib/perl5/auto/MIME/Base64/Base64.bs
instead of:
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/MIME/Base64.pm
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/MIME/QuotedPrint.pm
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/MIME/Base64/Base64.bs
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/MIME/Base64/Base64.so
And one more example: libdigest-md5-perl (p5-Digest-MD5) package
provides:
/usr/lib/perl5/Digest/MD5.pm
/usr/lib/perl5/auto/Digest/MD5/MD5.so
/usr/lib/perl5/auto/Digest/MD5/MD5.bs
instead of
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/Digest/MD5.pm
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/Digest/MD5/MD5.bs
/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/Digest/MD5/MD5.so
Any thoughts on this?
Jeremy C. Reed
open source, Unix, *BSD, Linux training
http://www.pugetsoundtechnology.com/