diff options
-rw-r--r-- | .SRCINFO | 13 | ||||
-rw-r--r-- | 34.patch | 24 | ||||
-rw-r--r-- | PKGBUILD | 19 |
3 files changed, 11 insertions, 45 deletions
@@ -1,7 +1,7 @@ pkgbase = perl-math-prime-util pkgdesc = Math::Prime::Util - utilities related to prime numbers, including fast sieves and factoring (ntheory) pkgver = 0.73.git - pkgrel = 1 + pkgrel = 2 url = https://metacpan.org/release/Math-Prime-Util arch = i686 arch = x86_64 @@ -9,7 +9,7 @@ pkgbase = perl-math-prime-util license = GPL depends = glibc>=2.25 depends = perl>=5.6.2 - depends = perl-math-prime-util-gmp>=0.51 + depends = perl-math-prime-util-gmp>=0.52 optdepends = perl-math-bigint-gmp: for faster BigInt operations. provides = perl-math-prime-util provides = perl-math-prime-util-chacha @@ -26,12 +26,9 @@ pkgbase = perl-math-prime-util provides = perl-math-prime-util-zetabigfloat provides = perl-ntheory options = !emptydirs - source = 34.patch - source = https://github.com/danaj/Math-Prime-Util/archive/c20fed38aea4a0675d5ff7b5cdc43a47c815d027.zip - md5sums = 1a85cfb5afacd0a065ba4c033355cbe1 - md5sums = 363c0584aeaaac479e43f9cbda90e7a5 - sha512sums = 9ee18c357fce8d8a0575db8c204197f836fa6967606dbc51180fbd31f2abf6bdca6b1a1cfa8fccd1bbaf2bc6511046b742870240632051898a2c5ee73712361a - sha512sums = c2c04218d8ddcdba28884ece55b0b81ab9c502f6007f64680d4c289b654c26a9ae68837e7fd171b6fa92aaa695198572768c260809c5316bd7e311c71006ebcc + source = https://github.com/danaj/Math-Prime-Util/archive/86770d79b4da0aa40e2e352d7b4a09b7631def7b.zip + md5sums = e872e0ef0f56822e0ffe4abccb7b2df5 + sha512sums = e845ec8c352d1dd1d32763e16cc0880ae0665e9b58ee712587da918936ced4fd2cc9145fa8dc1839048e3dc863db83acf924f0825c616bc31e8dd500d2e57afa pkgname = perl-math-prime-util diff --git a/34.patch b/34.patch deleted file mode 100644 index 55c971971976..000000000000 --- a/34.patch +++ /dev/null @@ -1,24 +0,0 @@ -From e6258748e92f8244a144c21a67af7e3713beaac8 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Daniel=20=C8=98uteu?= <trizen@protonmail.com> -Date: Tue, 5 Nov 2019 16:47:38 +0200 -Subject: [PATCH] Handle 2^n in is_totient() - -Fixes https://github.com/danaj/Math-Prime-Util/issues/33. - -See also: [A058213](https://oeis.org/A058213), [A058215](https://oeis.org/A058215). ---- - util.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/util.c b/util.c -index e03ac43..4199254 100644 ---- a/util.c -+++ b/util.c -@@ -1059,6 +1059,7 @@ static int _totpred(UV n, UV maxd) { - int res; - - if (n & 1) return 0; -+ if ((n & (n-1)) == 0) return 1; - n >>= 1; - if (n == 1) return 1; - if (n < maxd && is_prime(2*n+1)) return 1; @@ -3,7 +3,7 @@ pkgname='perl-math-prime-util' pkgver='0.73.git' -pkgrel='1' +pkgrel='2' pkgdesc="Math::Prime::Util - utilities related to prime numbers, including fast sieves and factoring (ntheory)" arch=('i686' 'x86_64') license=('PerlArtistic' 'GPL') @@ -11,13 +11,13 @@ options=('!emptydirs') depends=( 'glibc>=2.25' 'perl>=5.6.2' - 'perl-math-prime-util-gmp>=0.51' + 'perl-math-prime-util-gmp>=0.52' ) optdepends=( 'perl-math-bigint-gmp: for faster BigInt operations.' ) makedepends=() -_githash="c20fed38aea4a0675d5ff7b5cdc43a47c815d027" +_githash="86770d79b4da0aa40e2e352d7b4a09b7631def7b" provides=( 'perl-math-prime-util' 'perl-math-prime-util-chacha' @@ -35,18 +35,11 @@ provides=( 'perl-ntheory' ) url='https://metacpan.org/release/Math-Prime-Util' -source=("34.patch" "https://github.com/danaj/Math-Prime-Util/archive/$_githash.zip") -md5sums=('1a85cfb5afacd0a065ba4c033355cbe1' - '363c0584aeaaac479e43f9cbda90e7a5') -sha512sums=('9ee18c357fce8d8a0575db8c204197f836fa6967606dbc51180fbd31f2abf6bdca6b1a1cfa8fccd1bbaf2bc6511046b742870240632051898a2c5ee73712361a' - 'c2c04218d8ddcdba28884ece55b0b81ab9c502f6007f64680d4c289b654c26a9ae68837e7fd171b6fa92aaa695198572768c260809c5316bd7e311c71006ebcc') +source=("https://github.com/danaj/Math-Prime-Util/archive/$_githash.zip") +md5sums=('e872e0ef0f56822e0ffe4abccb7b2df5') +sha512sums=('e845ec8c352d1dd1d32763e16cc0880ae0665e9b58ee712587da918936ced4fd2cc9145fa8dc1839048e3dc863db83acf924f0825c616bc31e8dd500d2e57afa') _distdir="Math-Prime-Util-$_githash" -prepare() { - cd "$srcdir/$_distdir" - patch --forward --strip=1 --input="${srcdir}/34.patch" -} - build() { ( export PERL_MM_USE_DEFAULT=1 PERL5LIB="" \ PERL_AUTOINSTALL=--skipdeps \ |