mirror of
https://github.com/webmin/webmin.git
synced 2026-02-03 06:03:28 +00:00
Check for and use DBD::MariaBB as well
https://forum.virtualmin.com/t/webmin-2-6-not-available-yet/135883/45
This commit is contained in:
@@ -3,6 +3,6 @@ require 'mysql-lib.pl';
|
||||
|
||||
sub cpan_recommended
|
||||
{
|
||||
return ( "DBI", "DBD::mysql" );
|
||||
return ( "DBI", $mysql_version =~ /mariadb/ ? "DBD::MariaDB" : "DBD::mysql" );
|
||||
}
|
||||
|
||||
|
||||
@@ -320,9 +320,14 @@ else {
|
||||
if (foreign_available("cpan")) {
|
||||
eval "use DBI";
|
||||
push(@needs, "DBI") if ($@);
|
||||
$nodbi++ if ($@);
|
||||
eval "use DBD::mysql";
|
||||
push(@needs, "DBD::mysql") if ($@);
|
||||
if ($@) {
|
||||
eval "use DBD::MariaDB";
|
||||
if ($@) {
|
||||
push(@needs, $mysql_version =~ /mariadb/ ? "DBD::MariaDB"
|
||||
: "DBD::mysql");
|
||||
}
|
||||
}
|
||||
if (@needs) {
|
||||
$needs = &urlize(join(" ", @needs));
|
||||
print &ui_alert_box(&text(@needs == 2 ? 'index_nomods' : 'index_nomod', @needs,
|
||||
|
||||
Reference in New Issue
Block a user