php: fix updateScript failure due to incorrect release url

This commit is contained in:
Piotr Kwiecinski
2026-02-25 11:29:40 +01:00
parent eac682cd51
commit 303884b3cb
2 changed files with 15 additions and 16 deletions
+14 -15
View File
@@ -7,17 +7,16 @@
}:
let
commonArgs = {
stdenv = if stdenv.cc.isClang then llvmPackages.stdenv else stdenv;
pcre2 = pcre2.override {
withJitSealloc = false; # See https://bugs.php.net/bug.php?id=78927 and https://bugs.php.net/bug.php?id=78630
};
};
generic =
mkPhp =
{ version, hash }:
let
base = callPackage ./generic.nix (commonArgs // { inherit version hash; });
base = callPackage ./generic.nix {
stdenv = if stdenv.cc.isClang then llvmPackages.stdenv else stdenv;
pcre2 = pcre2.override {
withJitSealloc = false; # See https://bugs.php.net/bug.php?id=78927 and https://bugs.php.net/bug.php?id=78630
};
inherit version hash;
};
in
base.withExtensions (
{ all, ... }:
@@ -64,24 +63,24 @@ let
zip
zlib
]
++ lib.optional (lib.versionOlder version "8.4") all.imap
++ lib.optional (lib.versionOlder version "8.5") all.opcache
++ lib.optionals (lib.versionOlder version "8.4") [ all.imap ]
++ lib.optionals (lib.versionOlder version "8.5") [ all.opcache ]
);
in
{
php82 = generic {
php82 = mkPhp {
version = "8.2.30";
hash = "sha256-EEggtsj8lZ3eSzNCE19CvavyRuhpGKFjgaF9hEfIZvo=";
};
php83 = generic {
php83 = mkPhp {
version = "8.3.30";
hash = "sha256-gAt7btULc8jueETuXy98xhL6p4daCqfEUp6O1YZqUDA=";
};
php84 = generic {
php84 = mkPhp {
version = "8.4.18";
hash = "sha256-WGsy2Szrz7yklcX2rRozZAVT0KnAv9LmcVM02VnPmFg=";
};
php85 = generic {
php85 = mkPhp {
version = "8.5.3";
hash = "sha256-/F7KvBg862TZ/KPc04e9KbK2dEgyavmY/eADEkkWgjs=";
};
@@ -382,7 +382,7 @@ let
jq
]
}
new_version=$(curl --silent "https://www.php.net/releases/active" | jq --raw-output '."${lib.versions.major version}"."${lib.versions.majorMinor version}".version')
new_version=$(curl --silent "https://www.php.net/releases/active.php" | jq --raw-output '."${lib.versions.major version}"."${lib.versions.majorMinor version}".version')
update-source-version "$UPDATE_NIX_ATTR_PATH.unwrapped" "$new_version" "--file=$1"
'';
in