Skip Menu |

This queue is for tickets about the Proc-Background CPAN distribution.

Report information
The Basics
Id: 47100
Status: resolved
Worked: 2 hours (120 min)
Priority: 0/
Queue: Proc-Background

People
Owner: Nobody in particular
Requestors: TJC [...] cpan.org
Cc: bobtfish [...] bobtfish.net
AdminCc:

Bug Information
Severity: Critical
Broken in:
  • 1.08
  • 1.09
Fixed in: 1.10



Subject: Build failure on Win32 due to missing require() of Win32::Process
This module fails to build on Win32, which breaks the Catalyst install, among other things. In the Makefile.PL, there is a "die unless Win32::Process is installed" which seems unnneccessary. Surely this should be require 'Win32::process'.. References: http://cpansearch.perl.org/src/BZAJAC/Proc-Background-1.08/Makefile.PL
I uploaded version 1.09 which changes the die() to a warn() which should allow it to work unattended, according to Tomas Doran, who supplied a patch to this. Let me know if this works.
On Thu Jul 02 02:09:55 2009, BZAJAC wrote: Show quoted text
> I uploaded version 1.09 which changes the die() to a warn() which should > allow it to work unattended, according to Tomas Doran, who supplied > a patch to this. > > Let me know if this works.
Thanks, I am just waiting for it to show up on search.cpan.org and I'll try it out to confirm.
1.09 does NOT fix the problem. Makefile.PL needs to have this in it: if ($^O eq 'MSWin32') { require 'Win32::Process' => 0.04; }
On Thu Jul 02 21:40:51 2009, TJC wrote: Show quoted text
> 1.09 does NOT fix the problem.
Yeah, sorry - I totally fail :/ Show quoted text
> Makefile.PL needs to have this in it: > > if ($^O eq 'MSWin32') { > require 'Win32::Process' => 0.04; > }
That won't work with EU::MM, you're thinking of Module::Install. I propose the attached patch, but I'm not totally sure that will do the right thing. I've asked on irc in #toolchain about if this will work, I'll report back.
Index: Makefile.PL =================================================================== --- Makefile.PL (revision 544) +++ Makefile.PL (working copy) @@ -3,6 +3,8 @@ require 5.004_04; use strict; +my %requires; + # Subroutine to check for installed modules. sub check_version { @@ -19,9 +21,11 @@ : "not found"; my $vnum = ${"${pkg}::VERSION"} || 0; - print $vnum >= $wanted ? "ok\n" : " " . $vstr . "\n"; + my $ok = $vnum >= $wanted; + print $ok ? "ok\n" : " " . $vstr . "\n"; - $vnum >= $wanted; + $requires{$pkg} = $wanted if !$ok; + return $ok; } # Check for needed modules. @@ -60,4 +64,6 @@ 'COMPRESS' => 'gzip', 'SUFFIX' => 'gz' }, + PREREQ_PM => \%requires, ); +
kane (CPANPLUS author) tells me that the proposed patch will work as expected. :) However the dist will need to be packaged on a non-windows machine, otherwise the dependency will show up in META.yml for everyone. Is that workable?
On Sun Jul 05 10:40:47 2009, BOBTFISH wrote: Show quoted text
> kane (CPANPLUS author) tells me that the proposed patch will work as > expected. :) > > However the dist will need to be packaged on a non-windows machine, > otherwise the dependency will show up in META.yml for everyone. > > Is that workable?
I'll build and put up a new version with the patch and build it on a Mac 10.5 system, which should work.
I uploaded 1.10 to PAUSE.
On Sun Jul 05 19:09:15 2009, BZAJAC wrote: Show quoted text
> I uploaded 1.10 to PAUSE.
Thanks. Version 1.10 successfully identified Win32::Process as a requirement, and CPANPLUS installed it as a prerequisite.