Discussion:
[Pdl-porters] PDL::Core::Dev patch for auto generation of ModName.pod during make dist
kmx
2014-05-15 08:33:25 UTC
Permalink
Hi,

Please find my enclosed patch for PDL::Core::Dev with a suggestion for
automatic generation of *.pod file during 'make dist'.

The generated *.pod file is packed into final tarball which in the end
improves documentation accessibility on metacpan.org.

It is just an idea not much tested yet.

--
kmx
Chris Marshall
2014-05-15 12:54:16 UTC
Permalink
Hi kmx-

What is the patch against and what does it fix? I can't
tell from looking at it and it doesn't match up to the
current git master.

Pre-building POD for the distribution is a good idea that
has been discussed on the mailing list and in some
sf.net tickets (e.g., http://sourceforge.net/p/pdl/feature-requests/64/ )
but no-one has taken on the issue---even so far as a quick fix.

--Chris
Post by kmx
Hi,
Please find my enclosed patch for PDL::Core::Dev with a suggestion for
automatic generation of *.pod file during 'make dist'.
The generated *.pod file is packed into final tarball which in the end
improves documentation accessibility on metacpan.org.
It is just an idea not much tested yet.
--
kmx
_______________________________________________
PDL-porters mailing list
http://mailman.jach.hawaii.edu/mailman/listinfo/pdl-porters
kmx
2014-05-15 13:30:36 UTC
Permalink
Chris,

My patch changes pdlpp_stdargs() in Core/Dev.pm and it works like this:


0/ let's have for example a module PDL::Something


1/ no change is needed in PDL::Something's Makefile.PL it contains as usual:

my $package = [qw/Something.pd Something PDL::Something/];
WriteMakefile(
pdlpp_stdargs($package),
VERSION_FROM => 'Something.pd',
CONFIGURE_REQUIRES => { PDL => 0 },
);
sub MY::postamble { pdlpp_postamble($package) }


3/ When running Makefile.PL my patched version of pdlpp_stdargs() creates
one extra item in resulting hash:

dist => { PREOP=> '$(PERL) "-MPDL::PP qw/PDL::Something PDL::Something
Something/" Something.pd && perldoc -u Something.pm >
$(DISTVNAME)/Something.pod' }


4/ Which turns into corresponding line in generated Makefile:

PREOP = $(PERL) "-MPDL::PP qw/PDL::Something PDL::Something Something/"
Something.pd && perldoc -u Something.pm > $(DISTVNAME)/Something.pod


5/ Then during 'make dist' the following two commands are executed before
distribution tarball creation:

perl "-MPDL::PP qw/PDL::Something PDL::Something Something/" Something.pd
perldoc -u Something.pm > Something-0.001/Something.pod'


6/ Which ends up with Something.pod packed into distribution tarball (it is
not listed in MANIFEST but IMO it's not such a big issue)


--
kmx
Post by Chris Marshall
Hi kmx-
What is the patch against and what does it fix? I can't
tell from looking at it and it doesn't match up to the
current git master.
Pre-building POD for the distribution is a good idea that
has been discussed on the mailing list and in some
sf.net <http://sf.net> tickets (e.g.,
http://sourceforge.net/p/pdl/feature-requests/64/ )
but no-one has taken on the issue---even so far as a quick fix.
--Chris
Hi,
Please find my enclosed patch for PDL::Core::Dev with a suggestion
for automatic generation of *.pod file during 'make dist'.
The generated *.pod file is packed into final tarball which in the
end improves documentation accessibility on metacpan.org
<http://metacpan.org>.
It is just an idea not much tested yet.
--
kmx
_______________________________________________
PDL-porters mailing list
http://mailman.jach.hawaii.edu/mailman/listinfo/pdl-porters
Loading...