php: Refactor so we can upgrade PHP per platform (#47162)

This way we don't need to disable flags etc by platform and can still
backport new versions to stable for linux even if there's a bug or
something in the darwin build.
This commit is contained in:
Elis Hirwing 2018-09-22 20:22:57 +02:00 committed by xeji
parent f2ba1a4284
commit 0b82fbc3af

View File

@ -37,10 +37,7 @@ let
, opensslSupport ? config.php.openssl or true , opensslSupport ? config.php.openssl or true
, mbstringSupport ? config.php.mbstring or true , mbstringSupport ? config.php.mbstring or true
, gdSupport ? config.php.gd or true , gdSupport ? config.php.gd or true
# Because of an upstream bug: https://bugs.php.net/bug.php?id=76826 , intlSupport ? config.php.intl or true
# We need to disable the intl support on darwin. Whenever the upstream bug is
# fixed we should revert this to just just "config.php.intl or true".
, intlSupport ? (config.php.intl or true) && (!stdenv.isDarwin)
, exifSupport ? config.php.exif or true , exifSupport ? config.php.exif or true
, xslSupport ? config.php.xsl or false , xslSupport ? config.php.xsl or false
, mcryptSupport ? config.php.mcrypt or true , mcryptSupport ? config.php.mcrypt or true
@ -225,13 +222,35 @@ let
}; };
in { in {
php71 = generic { # Because of an upstream bug: https://bugs.php.net/bug.php?id=76826
version = "7.1.22"; # We can't update the darwin versions because they simply don't compile at
sha256 = "0qz74qdlk19cw478f42ckyw5r074y0fg73r2bzlhm0dar0cizsf8"; # all due to a bug in the intl extensions.
}; #
# The bug so far is present in 7.1.21, 7.1.22, 7.2.9, 7.2.10.
php72 = generic { php71 = generic (
version = "7.2.10"; if stdenv.isDarwin then
sha256 = "17fsvdi6ihjghjsz9kk2li2rwrknm2ccb6ys0xmn789116d15dh1"; {
}; version = "7.1.20";
sha256 = "0i8xd6p4zdg8fl6f0j430raanlshsshr3s3jlm72b0gvi1n4f6rs";
}
else
{
version = "7.1.22";
sha256 = "0qz74qdlk19cw478f42ckyw5r074y0fg73r2bzlhm0dar0cizsf8";
}
);
php72 = generic (
if stdenv.isDarwin then
{
version = "7.2.8";
sha256 = "1rky321gcvjm0npbfd4bznh36an0y14viqcvn4yzy3x643sni00z";
}
else
{
version = "7.2.10";
sha256 = "17fsvdi6ihjghjsz9kk2li2rwrknm2ccb6ys0xmn789116d15dh1";
}
);
} }