From ee7447d3adff597c0a39f1c91f8f4873c8940808 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Fri, 24 Nov 2006 22:10:11 +0000 Subject: [PATCH] * Installer support for experimental MySQL 4.1/5.0 binary-safe schema --- RELEASE-NOTES | 2 ++ config/index.php | 29 ++++++++++++++++++++--------- 2 files changed, 22 insertions(+), 9 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 68c08987b1..46bc64f9e7 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -214,6 +214,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN in the autoblock_whitelist system message. * Added placeholders for text injection by hooks to EditPage.php * (bug 8009) Automatic edit summary for redirects is not filled for edits in existing pages +* Installer support for experimental MySQL 4.1/5.0 binary-safe schema + == Languages updated == diff --git a/config/index.php b/config/index.php index 515712e9ff..a99ba330d7 100644 --- a/config/index.php +++ b/config/index.php @@ -532,9 +532,10 @@ print "
  • Environment check $conf->RootPW = importPost( "RootPW", "-" ); ## MySQL specific: - $conf->DBprefix = importPost( "DBprefix" ); - $conf->DBmysql5 = (importPost( "DBmysql5" ) == "true") ? "true" : "false"; - $conf->LanguageCode = importPost( "LanguageCode", "en" ); + $conf->DBprefix = importPost( "DBprefix" ); + $conf->DBschema = importPost( "DBschema", "mysql4" ); + $conf->DBmysql5 = ($conf->DBschema == "mysql5" || $conf->DBschema == "mysql5-binary"); + $conf->LanguageCode = importPost( "LanguageCode", "en" ); ## Postgres specific: $conf->DBport = importPost( "DBport", "5432" ); @@ -836,12 +837,21 @@ if( $conf->posted && ( 0 == count( $errs ) ) ) { # FIXME: Check for errors print "
  • Creating tables..."; if ($conf->DBtype == 'mysql') { - if( $wgDBmysql5 ) { - print " using MySQL 5 table defs..."; - dbsource( "../maintenance/mysql5/tables.sql", $wgDatabase ); - } else { + switch( $conf->DBschema ) { + case "mysql4": print " using MySQL 4 table defs..."; dbsource( "../maintenance/tables.sql", $wgDatabase ); + break; + case "mysql5": + print " using MySQL 5 UTF-8 table defs..."; + dbsource( "../maintenance/mysql5/tables.sql", $wgDatabase ); + break; + case "mysql5-binary": + print " using MySQL 5 binary table defs..."; + dbsource( "../maintenance/mysql5/tables-binary.sql", $wgDatabase ); + break; + default: + dieout( " invalid schema selection!
  • " ); } dbsource( "../maintenance/interwiki.sql", $wgDatabase ); } else if ($conf->DBtype == 'postgres') { @@ -1198,8 +1208,9 @@ if( count( $errs ) ) {
    Select one:

    -- 2.20.1