[TASK] Make BaseViewHelper Compilable
[Packages/TYPO3.CMS.git] / typo3 / sysext / install / Resources / Private / PHP / Boot.php
1 <?php
2 namespace TYPO3\CMS\Install;
3
4 /*
5 * This file is part of the TYPO3 CMS project.
6 *
7 * It is free software; you can redistribute it and/or modify it under
8 * the terms of the GNU General Public License, either version 2
9 * of the License, or any later version.
10 *
11 * For the full copyright and license information, please read the
12 * LICENSE.txt file that was distributed with this source code.
13 *
14 * The TYPO3 project - inspiring people to share!
15 */
16
17 defined('TYPO3_MODE') or die();
18
19 // Bootstrap bare minimum: class loader, LocalConfiguration, but no extensions and such
20 require __DIR__ . '/../../../../core/Classes/Core/Bootstrap.php';
21 \TYPO3\CMS\Core\Core\Bootstrap::getInstance()
22 ->baseSetup('typo3/sysext/install/Start/')
23 ->startOutputBuffering()
24 ->loadConfigurationAndInitialize(FALSE, \TYPO3\CMS\Core\Package\FailsafePackageManager::class);
25
26 // Execute 'tool' or 'step' controller depending on install[controller] GET/POST parameter
27 $getPost = \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('install');
28 $controllerClassName = \TYPO3\CMS\Install\Controller\StepController::class;
29 if (isset($getPost['controller'])) {
30 switch ($getPost['controller']) {
31 case 'tool':
32 $controllerClassName = \TYPO3\CMS\Install\Controller\ToolController::class;
33 break;
34 case 'ajax':
35 $controllerClassName = \TYPO3\CMS\Install\Controller\AjaxController::class;
36 break;
37 }
38 }
39 \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($controllerClassName)->execute();