Skip Menu |

This queue is for tickets about the Win32-SerialPort CPAN distribution.

Report information
The Basics
Id: 30088
Status: patched
Priority: 0/
Queue: Win32-SerialPort

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.19
Fixed in: (no value)



Subject: Not installable with CPAN.pm
Because Makefile.PL does not use neither ExtUtils::MakeMaker nor Module::Build, the module is not installable out-of-the-box using CPAN.pm (and probably also not using CPANPLUS.pm). Suggestion: * create also a small Makefile which has just rules for "all", "test" and "install" which would just call nothing, "perl test.pl" and "perl install.pl" * or better: if you don't like the "make" dependency, then convert the Makefile.PL into a Module::Build-compatible Build.PL Regards, Slaven
Subject: Re: [rt.cpan.org #30088] Not installable with CPAN.pm
Date: Fri, 19 Oct 2007 07:39:57 EDT
To: bug-Win32-SerialPort [...] rt.cpan.org
From: Bbirthisel [...] aol.com
Hi, In a message dated 10/18/2007 6:09:32 AM Eastern Daylight Time, bug-Win32-SerialPort@rt.cpan.org writes: Show quoted text
> Thu Oct 18 06:08:39 2007: Request 30088 was acted upon. > Transaction: Ticket created by SREZIC > Queue: Win32-SerialPort > Subject: Not installable with CPAN.pm > Broken in: (no value) > Severity: Normal > Owner: Nobody > Requestors: SREZIC@cpan.org > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=30088 > > > > Because Makefile.PL does not use neither ExtUtils::MakeMaker nor > Module::Build, the module is not installable out-of-the-box using CPAN.pm > (and probably also not using CPANPLUS.pm). > > Suggestion: > * create also a small Makefile which has just rules for "all", "test" > and "install" which would just call nothing, "perl test.pl" and > "perl install.pl" > * or better: if you don't like the "make" dependency, then convert the > Makefile.PL into a Module::Build-compatible Build.PL > > Regards, > Slaven
The issue is one of vintage. When the installer was released, it had to support perl versions 5.003 (no MakeMaker tools at all) and 5.004 (limited capability MakeMaker tools for Windows platforms) as well as 5.005. The method used was actually "leading edge" for its time - a close cousin for the MARC.pm module was written up in The Perl Journal in 1999. At that time, CPAN.pm did not work reliably on Windows; CPANPLUS and Module::Build had not even been proposed. If I manage enough TUITs for an update (there are some requests pending), I'll also include the suggested install changes. -bill ************************************** See what's new at http://www.aol.com
Simplified Makefile.PL. It will require 5.004. -- Alexandr Ciornii, http://chorny.net
#### use ExtUtils::MakeMaker; #### # See lib/ExtUtils/MakeMaker.pm for details of how to influence #### # the contents of the Makefile that is written. #### WriteMakefile( #### 'NAME' => 'SerialPort', #### 'VERSION_FROM' => 'SerialPort.pm', # finds $VERSION #### ); use 5.004; my $version = "0.19"; my $file = "COM1"; if (@ARGV) { $file = shift @ARGV; } my $dfile = "t/DefaultPort.pm"; unlink $dfile; print "\nCreating new $dfile\n"; open (DEFAULT, "> $dfile") or die "Can't create $dfile: $!\n"; print DEFAULT <<EOF; package SerialJunk; # Created by Makefile.PL \$Makefile_Test_Port = "$file"; EOF close DEFAULT; print "\n Win32::SerialPort and Win32API::CommPort\n"; print " VERSION $version\n"; print " No 'Makefile' will be created\n"; print " Test with: perl test.pl\n"; print " Install with: perl install.pl\n\n"; print " Test with nothing connected to $file\n"; print " or for different port: perl test.pl PORT\n"; print " Timeout tests can take up to 30 seconds per test\n\n"; $dfile = "test.pl"; unlink $dfile; print "Creating new $dfile\n"; open (DEFAULT, "> $dfile") or die "Can't create $dfile: $!\n"; print DEFAULT <<TEST4; # Created by Makefile.PL # VERSION $version use Test::Harness; runtests ("t/test1.t", "t/test2.t", "t/test3.t", "t/test4.t", "t/test5.t", "t/test6.t", "t/test7.t"); print "\\nTo run individual tests, type:\\n"; print " C:\\> perl t/test1.t Page_Pause_Time (0..5) [ $file ]\\n"; print "\\nContinue with 'perl t/test2.t' through 'perl t/test7.t'\\n"; print "See README and other documentation for additional information.\\n\\n"; TEST4 close DEFAULT; $dfile = "install.pl"; unlink $dfile; print "Creating new $dfile\n"; open (DEFAULT, "> $dfile") or die "Can't create $dfile: $!\n"; print DEFAULT <<INST4; # Created by Makefile.PL # VERSION $version BEGIN { require 5.004; } use Config qw(\%Config); use strict; use ExtUtils::Install qw( install ); my \$FULLEXT = "Win32/SerialPort"; my \$INST_LIB = "./lib"; my \$HTML_LIB = "./html"; my \$html_dest = ""; # edit real html base here if autodetect fails if (exists \$Config{installhtmldir} ) { \$html_dest = "\$Config{installhtmldir}"; } elsif (exists \$Config{installprivlib} ) { \$html_dest = "\$Config{installprivlib}"; \$html_dest =~ s%\\\\lib%\\\\html%; } if ( length (\$html_dest) ) { \$html_dest .= '\\lib\\site'; } else { die "Can't find html base directory. Edit install.pl manually.\\n"; } install({ read => "\$Config{sitearchexp}/auto/\$FULLEXT/.packlist", write => "\$Config{installsitearch}/auto/\$FULLEXT/.packlist", \$INST_LIB => "\$Config{installsitelib}", \$HTML_LIB => "\$html_dest" },1,0,0); __END__ INST4 close DEFAULT;
Version 0.20, released yesterday, creates a Makefile that works fine with Strawberry perl 5.10.1 as well as continuing to create nomake_xxx equivalents for the make deprived. Since I don't have the hardware and software to do a complete check of CPAN.pm installs, I'll leave this ticket open a little longer. -bill