Skip Menu |
 

This queue is for tickets about the Math-BigInt CPAN distribution.

Report information
The Basics
Id: 119199
Status: resolved
Priority: 0/
Queue: Math-BigInt

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

Bug Information
Severity: Critical
Broken in: 1.999803
Fixed in: 1.999806

Attachments
0001-Set-INSTALLDIRS-perl-to-ensure-we-install-over-the-c.patch



Subject: [PATCH] After switching to MakeMaker, no longer installs over core version
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
X-RT-Interface: Web
Message-ID: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
X-RT-Original-Encoding: utf-8
Content-Type: multipart/mixed; boundary="----------=_1481411131-10741-3"
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 0
Content-Disposition: inline
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
Content-Length: 224
Download (untitled) / with headers
text/plain 224b
The Module::Install version of this module made sure to install itself over the core version by using install_as_core(). Now that MakeMaker is used, the similar INSTALLDIRS => 'perl' setting needs to be used. Patch attached.
Subject: 0001-Set-INSTALLDIRS-perl-to-ensure-we-install-over-the-c.patch
MIME-Version: 1.0
Content-Type: application/octet-stream; name="0001-Set-INSTALLDIRS-perl-to-ensure-we-install-over-the-c.patch"
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline; filename="0001-Set-INSTALLDIRS-perl-to-ensure-we-install-over-the-c.patch"
Content-Transfer-Encoding: base64
Content-Length: 932
From a02399c35f170b50bc1652a42d1edbe8d18f7686 Mon Sep 17 00:00:00 2001 From: Andy Grundman <andyg@activestate.com> Date: Sat, 10 Dec 2016 18:04:31 -0500 Subject: [PATCH] Set INSTALLDIRS => 'perl' to ensure we install over the core version and not into sitelib or elsewhere. --- Makefile.PL | 1 + 1 file changed, 1 insertion(+) mode change 100644 => 100755 Makefile.PL diff --git a/Makefile.PL b/Makefile.PL old mode 100644 new mode 100755 index 4e8cb12..21d526a --- a/Makefile.PL +++ b/Makefile.PL @@ -15,6 +15,7 @@ WriteMakefile 'Test::More' => 0.94, 'Math::Complex' => 1.39, }, + 'INSTALLDIRS' => 'perl', # install over the core version 'LICENSE' => 'perl_5', 'LIBS' => [''], # e.g., '-lm' 'DEFINE' => '', # e.g., '-DHAVE_SOMETHING' -- 2.8.1
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-11733-1481411512-265.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 118
Download (untitled) / with headers
text/plain 118b
I forgot to mention that the same fix needs to be applied to any other core modules that made the switch to MakeMaker.
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-11733-1481411512-265.119199-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org> <rt-4.0.18-11733-1481411512-265.119199-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-2006-1481460646-1993.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 203
Download (untitled) / with headers
text/plain 203b
Thanks. I have uploaded the following four distributions to CPAN Math-BigInt-1.999805.tar.gz Math-BigRat-0.2610.tar.gz Math-BigInt-FastCalc-0.5004.tar.gz bignum-0.46.tar.gz Sorry for the inconvenience.
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-30741-1481638318-883.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 589
Download (untitled) / with headers
text/plain 589b
On Sat Dec 10 18:05:31 2016, AGRUNDMA wrote: Show quoted text
> The Module::Install version of this module made sure to install itself > over the core version by using install_as_core(). Now that MakeMaker > is used, the similar INSTALLDIRS => 'perl' setting needs to be used. > Patch attached.
Because of this change anyone who has installed 1.999803 or 1.999804 on perl 5.12+ can't upgrade their Math::BigInt anymore because since 5.12 'site' is ahead of 'perl', as one would expect it to be. There are legitimate reasons to want to install to core on <5.12, but you never want to do it on 5.12+. Leon
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-30741-1481638318-883.119199-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org> <rt-4.0.18-30741-1481638318-883.119199-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-2617-1481642506-658.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 401
Download (untitled) / with headers
text/plain 401b
On Tue Dec 13 09:11:58 2016, LEONT wrote: Show quoted text
> There are legitimate reasons to want to install to core on <5.12, but > you never want to do it on 5.12+.
I noticed this issue when trying to upgrade the Math::* modules on a 5.10 build of ActivePerl, where as you say it needs to be installed to core to work at all. Is the right fix something like this, then? INSTALLDIRS => $] >= 5.012 ? 'site' : 'perl'
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-22635-1481655255-484.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 654
Download (untitled) / with headers
text/plain 654b
Copied my response on ticket #119225: The correct fix for this is to include logic such as other dual life modules have, such that INSTALLDIRS is 'perl' only after the module became core and before 5.012: https://metacpan.org/source/EXODIST/Test-Simple-1.302067/Makefile.PL#L53-54 https://metacpan.org/source/JPEACOCK/version-0.9917/Makefile.PL#L63-65 For bignum and Math::BigRat, INSTALLDIRS should be 'perl' if ($] >= 5.008 and $] < 5.012). For Math::BigInt::FastCalc, INSTALLDIRS should be 'perl' if ($] >= 5.009003 and $] < 5.012). For Math::BigInt, INSTALLDIRS should be 'perl' if ($] < 5.012). In all other cases, it should be 'site' or omitted.
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-22635-1481655255-484.119199-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org> <rt-4.0.18-22635-1481655255-484.119199-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-21395-1481661548-1250.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 266
Download (untitled) / with headers
text/plain 266b
Thanks Dan for the proper fix. Peter: Thanks for the quick response with new versions, and I'm sorry for not fully understanding the implications on newer versions. The details of the site vs perl @INC swap were new to me. Hopefully this didn't bite too many people.
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-21395-1481661548-1250.119199-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-10741-1481411131-1171.0-0-0 [...] rt.cpan.org> <rt-4.0.18-22635-1481655255-484.119199-0-0 [...] rt.cpan.org> <rt-4.0.18-21395-1481661548-1250.119199-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-25693-1481663457-1604.119199-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 275
Download (untitled) / with headers
text/plain 275b
Thanks to everyone who have contributed, and Dan especially for the exact fixes. I have now uploaded the following files to CPAN. Hopefully, it is correct this time. bignum-0.47.tar.gz Math-BigInt-1.999806.tar.gz Math-BigInt-FastCalc-0.5005.tar.gz Math-BigRat-0.2611.tar.gz


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.