Merge "Indicate the actual version of HHVM in use"
[lhc/web/wiklou.git] / includes / installer / Installer.php
index 28304c2..987925c 100644 (file)
@@ -434,7 +434,11 @@ abstract class Installer {
        public function doEnvironmentChecks() {
                // Php version has already been checked by entry scripts
                // Show message here for information purposes
-               $this->showMessage( 'config-env-php', PHP_VERSION );
+               if ( wfIsHHVM() ) {
+                       $this->showMessage( 'config-env-hhvm', HHVM_VERSION );
+               } else {
+                       $this->showMessage( 'config-env-php', PHP_VERSION );
+               }
 
                $good = true;
                // Must go here because an old version of PCRE can prevent other checks from completing
@@ -529,6 +533,14 @@ abstract class Installer {
        public static function getExistingLocalSettings() {
                global $IP;
 
+               // You might be wondering why this is here. Well if you don't do this
+               // then some poorly-formed extensions try to call their own classes
+               // after immediately registering them. We really need to get extension
+               // registration out of the global scope and into a real format.
+               // @see https://bugzilla.wikimedia.org/67440
+               global $wgAutoloadClasses;
+               $wgAutoloadClasses = array();
+
                wfSuppressWarnings();
                $_lsExists = file_exists( "$IP/LocalSettings.php" );
                wfRestoreWarnings();
@@ -728,6 +740,7 @@ abstract class Installer {
        /**
         * Environment check for register_globals.
         * Prevent installation if enabled
+        * @return bool
         */
        protected function envCheckRegisterGlobals() {
                if ( wfIniGetBool( 'register_globals' ) ) {
@@ -1511,6 +1524,7 @@ abstract class Installer {
                        array( 'name' => 'interwiki', 'callback' => array( $installer, 'populateInterwikiTable' ) ),
                        array( 'name' => 'stats', 'callback' => array( $this, 'populateSiteStats' ) ),
                        array( 'name' => 'keys', 'callback' => array( $this, 'generateKeys' ) ),
+                       array( 'name' => 'updates', 'callback' => array( $installer, 'insertUpdateKeys' ) ),
                        array( 'name' => 'sysop', 'callback' => array( $this, 'createSysop' ) ),
                        array( 'name' => 'mainpage', 'callback' => array( $this, 'createMainpage' ) ),
                );