perl: add 5.38.0, 5.36.1; prefer all even minor versions over development versions (#38690)

* perl: add 5.38.0, 5.36.1; prefer all even minor versions over development versions

* fix libxcrypt build with new perl

* fix libxcrypt with a patch
This commit is contained in:
Harmen Stoppels 2023-07-06 00:08:54 +02:00 committed by GitHub
parent f884e71a03
commit 06268f7b72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 123 additions and 15 deletions

View file

@ -0,0 +1,59 @@
From 95d6e03ae37f4ec948474d111105bbdd2938aba2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20K=2E=20H=C3=BCttel?= <dilfridge@gentoo.org>
Date: Sun, 25 Jun 2023 01:35:08 +0200
Subject: [PATCH] Remove smartmatch usage from gen-crypt-h
Needed for Perl 5.38
---
build-aux/scripts/gen-crypt-h | 31 ++++++++++++++-----------------
1 file changed, 14 insertions(+), 17 deletions(-)
diff --git a/build-aux/scripts/gen-crypt-h b/build-aux/scripts/gen-crypt-h
index 12aecf6d..b113b791 100644
--- a/build-aux/scripts/gen-crypt-h
+++ b/build-aux/scripts/gen-crypt-h
@@ -12,7 +12,6 @@ use v5.14; # implicit use strict, use feature ':5.14'
use warnings FATAL => 'all';
use utf8;
use open qw(:std :utf8);
-no if $] >= 5.018, warnings => 'experimental::smartmatch';
no if $] >= 5.022, warnings => 'experimental::re_strict';
use if $] >= 5.022, re => 'strict';
@@ -37,22 +36,20 @@ sub process_config_h {
local $_;
while (<$fh>) {
chomp;
- # Yes, 'given $_' is really required here.
- given ($_) {
- when ('#define HAVE_SYS_CDEFS_H 1') {
- $have_sys_cdefs_h = 1;
- }
- when ('#define HAVE_SYS_CDEFS_BEGIN_END_DECLS 1') {
- $have_sys_cdefs_begin_end_decls = 1;
- }
- when ('#define HAVE_SYS_CDEFS_THROW 1') {
- $have_sys_cdefs_throw = 1;
- }
- when (/^#define PACKAGE_VERSION "((\d+)\.(\d+)\.\d+)"$/) {
- $substs{XCRYPT_VERSION_STR} = $1;
- $substs{XCRYPT_VERSION_MAJOR} = $2;
- $substs{XCRYPT_VERSION_MINOR} = $3;
- }
+
+ if ($_ eq '#define HAVE_SYS_CDEFS_H 1') {
+ $have_sys_cdefs_h = 1;
+ }
+ elsif ($_ eq '#define HAVE_SYS_CDEFS_BEGIN_END_DECLS 1') {
+ $have_sys_cdefs_begin_end_decls = 1;
+ }
+ elsif ($_ eq '#define HAVE_SYS_CDEFS_THROW 1') {
+ $have_sys_cdefs_throw = 1;
+ }
+ elsif (/^#define PACKAGE_VERSION "((\d+)\.(\d+)\.\d+)"$/) {
+ $substs{XCRYPT_VERSION_STR} = $1;
+ $substs{XCRYPT_VERSION_MAJOR} = $2;
+ $substs{XCRYPT_VERSION_MINOR} = $3;
}
}

View file

@ -20,6 +20,8 @@ def url_for_version(self, version):
version, version
)
version("4.4.35", sha256="a8c935505b55f1df0d17f8bfd59468c7c6709a1d31831b0f8e3e045ab8fd455d")
version("4.4.34", sha256="bb3f467af21c48046ce662186eb2ddf078ca775c441fdf1c3628448a3833a230")
version("4.4.33", sha256="e87acf9c652c573a4713d5582159f98f305d56ed5f754ce64f57d4194d6b3a6f")
version("4.4.32", sha256="0613f9bd51d713f8bb79fa10705b68d2ab705c3be4c4fc119f0a96bdc72256c4")
version("4.4.31", sha256="c0181b6a8eea83850cfe7783119bf71fddbde69adddda1d15747ba433d5c57ba")
@ -41,6 +43,11 @@ def url_for_version(self, version):
# Some distros have incomplete perl installs, +open catches that.
depends_on("perl@5.14.0: +open", type="build", when="@4.4.18:")
# Support Perl 5.38. todo: remove patch and update depends_on
# range once the commit ends up in a tagged release
depends_on("perl@:5.36", type="build", when="@:4.4.34")
patch("commit-95d56e0.patch", when="@4.4.35")
def configure_args(self):
args = [
# Disable test dependency on Python (Python itself depends on libxcrypt).

View file

@ -37,6 +37,63 @@ class Perl(Package): # Perl doesn't use Autotools, it should subclass Package
# see https://www.cpan.org/src/README.html for
# explanation of version numbering scheme
# Maintenance releases (even numbers, preferred)
version(
"5.38.0",
sha256="213ef58089d2f2c972ea353517dc60ec3656f050dcc027666e118b508423e517",
preferred=True,
)
version(
"5.36.1",
sha256="68203665d8ece02988fc77dc92fccbb297a83a4bb4b8d07558442f978da54cc1",
preferred=True,
)
version(
"5.36.0",
sha256="e26085af8ac396f62add8a533c3a0ea8c8497d836f0689347ac5abd7b7a4e00a",
preferred=True,
)
version(
"5.34.1",
sha256="357951a491b0ba1ce3611263922feec78ccd581dddc24a446b033e25acf242a1",
preferred=True,
)
version(
"5.34.0",
sha256="551efc818b968b05216024fb0b727ef2ad4c100f8cb6b43fab615fa78ae5be9a",
preferred=True,
)
version(
"5.32.1",
sha256="03b693901cd8ae807231b1787798cf1f2e0b8a56218d07b7da44f784a7caeb2c",
preferred=True,
)
version(
"5.32.0",
sha256="efeb1ce1f10824190ad1cadbcccf6fdb8a5d37007d0100d2d9ae5f2b5900c0b4",
preferred=True,
)
version(
"5.30.3",
sha256="32e04c8bb7b1aecb2742a7f7ac0eabac100f38247352a73ad7fa104e39e7406f",
preferred=True,
)
version(
"5.30.2",
sha256="66db7df8a91979eb576fac91743644da878244cf8ee152f02cd6f5cd7a731689",
preferred=True,
)
version(
"5.30.1",
sha256="bf3d25571ff1ee94186177c2cdef87867fd6a14aa5a84f0b1fb7bf798f42f964",
preferred=True,
)
version(
"5.30.0",
sha256="851213c754d98ccff042caa40ba7a796b2cee88c5325f121be5cbb61bbf975f2",
preferred=True,
)
# Development releases (odd numbers)
version("5.37.9", sha256="9884fa8a4958bf9434b50f01cbfd187f9e2738f38fe1ae37f844e9950c5117c1")
version("5.35.0", sha256="d6c0eb4763d1c73c1d18730664d43fcaf6100c31573c3b81e1504ec8f5b22708")
@ -44,21 +101,6 @@ class Perl(Package): # Perl doesn't use Autotools, it should subclass Package
version("5.31.7", sha256="d05c4e72128f95ef6ffad42728ecbbd0d9437290bf0f88268b51af011f26b57d")
version("5.31.4", sha256="418a7e6fe6485cc713a86d1227ef112f0bb3f80322e3b715ffe42851d97804a5")
# Maintenance releases (even numbers, recommended)
version(
"5.36.0",
sha256="e26085af8ac396f62add8a533c3a0ea8c8497d836f0689347ac5abd7b7a4e00a",
preferred=True,
)
version("5.34.1", sha256="357951a491b0ba1ce3611263922feec78ccd581dddc24a446b033e25acf242a1")
version("5.34.0", sha256="551efc818b968b05216024fb0b727ef2ad4c100f8cb6b43fab615fa78ae5be9a")
version("5.32.1", sha256="03b693901cd8ae807231b1787798cf1f2e0b8a56218d07b7da44f784a7caeb2c")
version("5.32.0", sha256="efeb1ce1f10824190ad1cadbcccf6fdb8a5d37007d0100d2d9ae5f2b5900c0b4")
version("5.30.3", sha256="32e04c8bb7b1aecb2742a7f7ac0eabac100f38247352a73ad7fa104e39e7406f")
version("5.30.2", sha256="66db7df8a91979eb576fac91743644da878244cf8ee152f02cd6f5cd7a731689")
version("5.30.1", sha256="bf3d25571ff1ee94186177c2cdef87867fd6a14aa5a84f0b1fb7bf798f42f964")
version("5.30.0", sha256="851213c754d98ccff042caa40ba7a796b2cee88c5325f121be5cbb61bbf975f2")
# End of life releases
version("5.28.0", sha256="7e929f64d4cb0e9d1159d4a59fc89394e27fa1f7004d0836ca0d514685406ea8")
version("5.26.2", sha256="572f9cea625d6062f8a63b5cee9d3ee840800a001d2bb201a41b9a177ab7f70d")