Re: [Module::Build] Document install_base_relpaths
Status: Beta
Brought to you by:
kwilliams
|
From: David W. <da...@ki...> - 2006-03-03 21:44:13
|
On Feb 17, 2006, at 11:30, David Wheeler wrote:
>> I just discovered install-base_relpaths, and for setting up new
>> elements to simply be installed relative to whatever the
>> install_base happens to be, it's very convenient. I'd like to see
>> it documented in the cookbook. The attached patch adds a note
>> about it there. Think you might let this be documented?
>
> Or perhaps better still, add_build_element could make it the
> default? That patch would look like this:
>
> --- Base.pm 16 Feb 2006 22:06:21 -0800 1.546
> +++ Base.pm 17 Feb 2006 11:28:54 -0800
> @@ -449,8 +449,9 @@
>
>
> sub add_build_element {
> - my $self = shift;
> - push @{$self->build_elements}, shift;
> + my ($self, $elem) = @_;
> + $self->install_base_relpaths->{$elem} ||= [$elem];
> + push @{$self->build_elements}, $elem;
>
> }
>
> sub ACTION_config_data {
Any comments on these suggestions? Maybe a different method that does
both of these actions would be welcomed?
sub add_build_element_with_path {
my ($self, $elem) = @_;
$self->add_build_element($elem);
$self->install_base_relpaths->{$elem} ||= [$elem];
}
???
Thanks,
David
|