php: fix build in case mysql is not mariadb

fixes #20986
This commit is contained in:
Robin Gloster 2017-01-25 18:00:48 +01:00
parent 2262763b1a
commit cb30150bd5
No known key found for this signature in database
GPG Key ID: 5E4C836C632C2882

View File

@ -9,9 +9,10 @@ let
generic = generic =
{ version, sha256 }: { version, sha256 }:
let php7 = lib.versionAtLeast version "7.0"; in let php7 = lib.versionAtLeast version "7.0";
mysqlHeaders = mysql.lib.dev or mysql;
composableDerivation.composableDerivation {} (fixed: { in composableDerivation.composableDerivation {} (fixed: {
inherit version; inherit version;
@ -114,12 +115,12 @@ let
mysql = { mysql = {
configureFlags = ["--with-mysql"]; configureFlags = ["--with-mysql"];
buildInputs = [ mysql.lib.dev ]; buildInputs = [ mysqlHeaders ];
}; };
mysqli = { mysqli = {
configureFlags = ["--with-mysqli=${mysql.lib.dev}/bin/mysql_config"]; configureFlags = ["--with-mysqli=${mysqlHeaders}/bin/mysql_config"];
buildInputs = [ mysql.lib.dev ]; buildInputs = [ mysqlHeaders ];
}; };
mysqli_embedded = { mysqli_embedded = {
@ -129,8 +130,8 @@ let
}; };
pdo_mysql = { pdo_mysql = {
configureFlags = ["--with-pdo-mysql=${mysql.lib.dev}"]; configureFlags = ["--with-pdo-mysql=${mysqlHeaders}"];
buildInputs = [ mysql.lib.dev ]; buildInputs = [ mysqlHeaders ];
}; };
bcmath = { bcmath = {