[Module-build-general] Re: Proposal for Module::Build installation dirs
Status: Beta
Brought to you by:
kwilliams
|
From: Ken W. <ke...@ma...> - 2003-07-03 15:11:40
|
On Thursday, July 3, 2003, at 08:24 AM, Abigail wrote:
> On Wed, May 14, 2003 at 12:14:02PM -0500, Ken Williams wrote:
>>
>> This means we can let people specify a family of defaults using an
>> "installdirs" parameter set to one of three options:
>>
>> 'installdirs' set to:
>> core site vendor
>>
>> results in the following defaults from Config.pm:
>>
>> arch => installarchlib installsitearch
>> installvendorarch
>> lib => installprivlib installsitelib installvendorlib
>> bin => installbin installsitebin installvendorbin
>> script => installscript installscript installscript
>> man1 => installman1dir installsiteman1dir
>> installvendorman1dir
>> man3 => installman3dir installsiteman3dir
>> installvendorman3dir
>
>
> Is the row for 'script' a typo, or are indeed all scripts, whether
> they are core, site and vendor always placed in the same directory?
Unfortunately it wasn't a typo. That's the way MakeMaker does it too,
because there's no such thing as 'installsitescript' or
'installvendorscript' in Config.pm.
However, I've since decided that this is unacceptable, since it really
does get in the way of sane layout management. It's also responsible
for the problem of LWP's /usr/bin/HEAD overwriting /usr/bin/head on Mac
OS X.
So in recent Module::Build betas, I've changed to this:
------------------------------------------------------------------
=head3 installdirs
The default destinations for these installable things come from
entries in your system's C<Config.pm>. You can select from three
different sets of default locations by setting the C<installdirs>
parameter as follows:
'installdirs' set to:
core site vendor
uses the following defaults from Config.pm:
lib => installprivlib installsitelib installvendorlib
arch => installarchlib installsitearch installvendorarch
script => installscript installsitebin installvendorbin
bin => installbin installsitebin installvendorbin
libdoc => installman3dir installsiteman3dir installvendorman3dir
bindoc => installman1dir installsiteman1dir installvendorman1dir
The default value of C<installdirs> is "site". If you're creating
vendor distributions of module packages, you may want to do something
like this:
perl Build.PL installdirs=vendor
or
Build install installdirs=vendor
If you're installing an updated version of a module that was included
with perl itself (i.e. a "core module"), then you may set
C<installdirs> to "core" to overwrite the module in its present
location.
(Note that the 'script' line is different from MakeMaker -
unfortunately there's no such thing as "installsitescript" or
"installvendorscript" entry in C<Config.pm>, so we use the
"installsitebin" and "installvendorbin" entries to at least get the
general location right. In the future, if C<Config.pm> adds some more
appropriate entries, we'll start using those.)
------------------------------------------------------------------
-Ken
|