[Module-build-general] Re: [PATCH] make doesn't create man pages
Status: Beta
Brought to you by:
kwilliams
|
From: Ken W. <ke...@ma...> - 2003-08-08 16:53:42
|
On Friday, August 8, 2003, at 10:02 AM, Steve Purkis wrote:
>
> Anyways - here's a patch to fix the docs/build dependency bug, and
> make M::B create man pages at 'build' time.
Looks good, Steve - below is the patch I'll commit. It creates a new
action 'code', which does what 'build' used to do, and now 'build'
creates both code & docs.
Hmm, I guess this doesn't actually need the loop-avoidance patch
anymore, does it! Well, I guess it's still good to have that.
-Ken
Index: lib/Module/Build/Base.pm
===================================================================
RCS file: /cvsroot/module-build/Module-Build/lib/Module/Build/Base.pm,v
retrieving revision 1.160
diff -u -r1.160 Base.pm
--- lib/Module/Build/Base.pm 5 Aug 2003 17:28:35 -0000 1.160
+++ lib/Module/Build/Base.pm 8 Aug 2003 16:50:58 -0000
@@ -913,7 +913,7 @@
my $p = $self->{properties};
require Test::Harness;
- $self->depends_on('build');
+ $self->depends_on('code');
# Do everything in our power to work with all versions of
Test::Harness
local ($Test::Harness::switches,
@@ -967,7 +967,7 @@
$self->depends_on('test');
}
-sub ACTION_build {
+sub ACTION_code {
my ($self) = @_;
# All installable stuff gets created in blib/ .
@@ -990,6 +990,12 @@
$self->process_script_files;
}
+sub ACTION_build {
+ my $self = shift;
+ $self->depends_on('code');
+ $self->depends_on('docs');
+}
+
sub compile_support_files {
my $self = shift;
my $p = $self->{properties};
@@ -1167,6 +1173,7 @@
sub ACTION_docs {
my $self = shift;
+ $self->depends_on('code');
require Pod::Man;
$self->manify_bin_pods() if $self->install_destination('bindoc');
$self->manify_lib_pods() if $self->install_destination('libdoc');
@@ -1307,14 +1314,14 @@
sub ACTION_install {
my ($self) = @_;
require ExtUtils::Install;
- $self->depends_on('build', 'docs');
+ $self->depends_on('build');
ExtUtils::Install::install($self->install_map('blib'), 1, 0,
$self->{args}{uninst}||0);
}
sub ACTION_fakeinstall {
my ($self) = @_;
require ExtUtils::Install;
- $self->depends_on('build', 'docs');
+ $self->depends_on('build');
ExtUtils::Install::install($self->install_map('blib'), 1, 1,
$self->{args}{uninst}||0);
}
@@ -1324,7 +1331,7 @@
die "You must have only.pm 0.25 or greater installed for this
operation: $@\n"
unless eval { require only; 'only'->VERSION(0.25); 1 };
- $self->depends_on('build', 'docs');
+ $self->depends_on('build');
my %onlyargs = map {exists($self->{args}{$_}) ? ($_ =>
$self->{args}{$_}) : ()}
qw(version versionlib);
|