Some systems, notable Debian, ship perldoc and perl as seperate packages. The presence of Perl does not imply the presence of perldoc.
This patch will test to see if perldoc actually works, aborting the configuration if it does not.
I was considering making the build system not build the documentation if perldoc did not exist. However, I felt that (a) a perldoc-less Perl is a broken Perl, and (b) currently, parrot should ship with a lot of documentation. If somebody feels otherwise, I would be happy to revise the patch.
- James
[
config_perldoc.patch 1K ] diff -uNr config_o2/auto/perldoc.pl config/auto/perldoc.pl --- config_o2/auto/perldoc.pl 1970-01-01 00:00:00.000000000 +0000 +++ config/auto/perldoc.pl 2004-11-01 22:27:54.000000000 +0000 @@ -0,0 +1,31 @@ +#! perl -w +# Copyright: 2004 James deBoer. All Rights Reserved. + +=head1 NAME + +config/auto/perldoc - Perldoc + +=head1 DESCRIPTION + +Determines if Perldoc exists on the system. + +=cut + +package Configure::Step; + +use strict; +use vars qw($description @args); +use Parrot::Configure::Step ':auto'; + +$description="Determining if your system has perldoc installed..."; + +@args=qw(verbose); + +sub runstep { + my $a = `perldoc perldoc`; + unless ($a =~ m/perldoc/) { + die "Configure.pl: Could not find the perldoc package, which is required.\n"; + } +} + +1; Index: lib/Parrot/Configure/RunSteps.pm =================================================================== RCS file: /cvs/public/parrot/lib/Parrot/Configure/RunSteps.pm,v retrieving revision 1.44 diff -u -r1.44 RunSteps.pm --- lib/Parrot/Configure/RunSteps.pm 28 Sep 2004 08:51:47 -0000 1.44 +++ lib/Parrot/Configure/RunSteps.pm 1 Nov 2004 22:44:50 -0000 @@ -56,6 +56,7 @@ auto/aio.pl auto/gmp.pl auto/snprintf.pl + auto/perldoc.pl gen/icu.pl gen/config_h.pl gen/core_pmcs.pl
James deBoer <parrotbug-follo...@parrotcode.org> wrote: > Some systems, notable Debian, ship perldoc and perl as seperate > packages. The presence of Perl does not imply the presence of perldoc. > This patch will test to see if perldoc actually works, aborting the > configuration if it does not. > I was considering making the build system not build the documentation > if perldoc did not exist. However, I felt that (a) a perldoc-less Perl > is a broken Perl ...
Is ok for me.
> - James
[ patch looks fine, let's hear some more opinions on that issue ]
On Mon, 1 Nov 2004, James deBoer wrote: > Some systems, notable Debian, ship perldoc and perl as seperate > packages. The presence of Perl does not imply the presence of perldoc.
> This patch will test to see if perldoc actually works, aborting the > configuration if it does not.
I don't feel strongly about this, but I think aborting during configuration is a bit extreme at present. If I don't have perldoc, the 'make' process currently ends with a loud failure, but at least I can still see if parrot Configures and builds at all, and I can still run 'make test'. The only thing I can't do is install the documentation, which really isn't relevant yet because the whole installation system isn't really designed yet, and because there isn't really much to do (for most of us) with an installed parrot anyway.
This is not a mere hypothetical case. In the main build environment I use to test parrot, no perldoc is available, though I certainly have lots of other copies of perldoc elsewhere available to me. In the long run, parrot won't be using perldoc to extract documentation anyway. The reliance on perl is a "temporary" convenience.
If you want to have Configure.pl complain loudly, that's probably a good idea -- some users may not be aware that there's a separate perldoc package -- but I don't see the need to require stuff that's not really necessary.
>> Some systems, notable Debian, ship perldoc and perl as seperate >> packages. The presence of Perl does not imply the presence of perldoc.
>> This patch will test to see if perldoc actually works, aborting the >> configuration if it does not.
>> I was considering making the build system not build the documentation >> if perldoc did not exist. However, I felt that (a) a perldoc-less Perl >> is a broken Perl ...
>Is ok for me.
And me as well. -- Dan
--------------------------------------it's like this------------------- Dan Sugalski even samurai d...@sidhe.org have teddy bears and even teddy bears get drunk
On Tue, Nov 02, 2004 at 09:22:36AM -0500, Andy Dougherty wrote: > On Mon, 1 Nov 2004, James deBoer wrote:
> > Some systems, notable Debian, ship perldoc and perl as seperate > > packages. The presence of Perl does not imply the presence of perldoc.
> > This patch will test to see if perldoc actually works, aborting the > > configuration if it does not.
> I don't feel strongly about this, but I think aborting during > configuration is a bit extreme at present. If I don't have perldoc, the > 'make' process currently ends with a loud failure, but at least I can > still see if parrot Configures and builds at all, and I can still run > 'make test'. The only thing I can't do is install the documentation, > which really isn't relevant yet because the whole installation system > isn't really designed yet, and because there isn't really much to do (for > most of us) with an installed parrot anyway.
I don't like the build blowing up on me when there is no perldoc, and on some machines that I use I'm not in a position to change this. So I'd like a way of overriding Configure to skip building the documentation. I don't see overriding a bail out as incompatible with the sentiment that the default should be to bail out at Configure time if not found.
I'd prefer it to bail out at Configure time than at make time, as it results in the problem being shown up far earlier. Unattended builds that fail at the end for detectable reasons annoy me. Particularly when something else time consuming was depending on them to pass, and so did not run.
Nicholas Clark <n...@ccl4.org> wrote: > I don't like the build blowing up on me when there is no perldoc, and on > some machines that I use I'm not in a position to change this.
So, as opinions aren't really matching, let's try this approach:
The configure step from that patch doesn't bail out, but prints a big fat warning about the lack of accessing perl and parrot docs, disables the parrot doc make target and continues.
Sorry for the delay, but here is a revised patch to detect perldoc.
- If Perldoc is detected, no warning messages will be printed and things will work as before - If Perldoc is not detected - Configure.pl will print a message saying that the docs will not be built - docs/ will not be built - When 'make docs' or 'make html' is run, a message will be echoed to the screen explaining that perldoc is required.
Leopold Toetsch wrote: >Nicholas Clark <n...@ccl4.org> wrote:
>>I don't like the build blowing up on me when there is no perldoc, and on >>some machines that I use I'm not in a position to change this.
>So, as opinions aren't really matching, let's try this approach:
>The configure step from that patch doesn't bail out, but prints a big >fat warning about the lack of accessing perl and parrot docs, disables >the parrot doc make target and continues.