From 8876ac788fa09be63921f474ff5c746167070b75 Mon Sep 17 00:00:00 2001 From: Shivam Mathur Date: Mon, 3 Aug 2020 14:18:17 +0530 Subject: [PATCH] Use shivammathur/php-builder-windows for PHP 8 on Windows --- src/scripts/win32.ps1 | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/scripts/win32.ps1 b/src/scripts/win32.ps1 index ef1c48b6..c4e030ac 100644 --- a/src/scripts/win32.ps1 +++ b/src/scripts/win32.ps1 @@ -257,9 +257,11 @@ if ($null -eq $installed -or -not("$($installed.Version).".StartsWith(($version } if ($version -eq $master_version) { $version = 'master' + Invoke-WebRequest -UseBasicParsing -Uri https://dl.bintray.com/shivammathur/php/Install-PhpMaster.ps1 -OutFile $php_dir\Install-PhpMaster.ps1 > $null 2>&1 + & $php_dir\Install-PhpMaster.ps1 -Architecture $arch -ThreadSafe $ts -Path $php_dir + } else { + Install-Php -Version $version -Architecture $arch -ThreadSafe $ts -InstallVC -Path $php_dir -TimeZone UTC -InitialPhpIni Production -Force > $null 2>&1 } - - Install-Php -Version $version -Architecture $arch -ThreadSafe $ts -InstallVC -Path $php_dir -TimeZone UTC -InitialPhpIni Production -Force >$null 2>&1 } else { $status = "Found" } @@ -269,10 +271,4 @@ Set-PhpIniKey -Key 'date.timezone' -Value 'UTC' -Path $php_dir Set-PhpIniKey -Key 'memory_limit' -Value '-1' -Path $php_dir Enable-PhpExtension -Extension openssl, curl, opcache, mbstring -Path $php_dir Update-PhpCAInfo -Path $php_dir -Source CurrentUser -if ($version -eq 'master') { - Invoke-WebRequest -UseBasicParsing -Uri "https://github.com/shivammathur/php-extensions-windows/releases/latest/download/php_$env:phpts`_$arch`_pcov.dll" -OutFile $ext_dir"\php_pcov.dll" >$null 2>&1 - Invoke-WebRequest -UseBasicParsing -Uri "https://github.com/shivammathur/php-extensions-windows/releases/latest/download/php_$env:phpts`_$arch`_xdebug.dll" -OutFile $ext_dir"\php_xdebug.dll" >$null 2>&1 - Set-PhpIniKey -Key 'opcache.jit_buffer_size' -Value '256M' -Path $php_dir - Set-PhpIniKey -Key 'opcache.jit' -Value '1235' -Path $php_dir -} Add-Log $tick "PHP" "$status PHP $($installed.FullVersion)"