mirror of
https://github.com/php-win-ext/php-sdk-binary-tools.git
synced 2026-03-24 09:02:12 +01:00
Compare commits
5 Commits
php_downlo
...
php-sdk-2.
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8ae549bbbe | ||
|
|
d683a0977f | ||
|
|
b1e2870343 | ||
|
|
d1036b5b3d | ||
|
|
19c8ccbf07 |
22
README.md
22
README.md
@@ -206,3 +206,25 @@ previously.
|
||||
- `7za` should be preferred over `unzip` and `zip` for compatibility reasons.
|
||||
- If you experience some strange crashes on MSYS2 tools, try the phpsdk_rebase_msys2 tool. MSYS2 tools might be have unstable
|
||||
on ASLR enabled systems.
|
||||
|
||||
# Internal notes
|
||||
|
||||
## Releases
|
||||
|
||||
Users of the PHP SDK are supposed to use tagged versions for stability and
|
||||
reproducability. This requires the maintainers of the PHP SDK to create such
|
||||
tags for *all* *relevant* *changes*. The tag format should be `php-sdk-X.Y.Z`,
|
||||
with the common major, minor and revision numbers.
|
||||
|
||||
Comprehensive changes, which would be hard to test extensively, such as updates
|
||||
to the bundled PHP or the MinGW tools, should walk through a QA (aka. pre-release)
|
||||
process, typically with beta versions (e.g. `php-sdk-X.Y.Zbeta1`). Only after
|
||||
these have been thoroughly tested, and all relevant issues have been resolved,
|
||||
a GA release should be tagged.
|
||||
|
||||
After each tag, a couple of other repositories should be informed about the
|
||||
available update, ideally in form of a pull request. These repositories are:
|
||||
|
||||
* https://github.com/php/php-src (for Windows CI)
|
||||
* https://github.com/php/php-windows-builder
|
||||
* https://github.com/php/setup-php-sdk
|
||||
|
||||
@@ -55,6 +55,9 @@ if "%PHP_SDK_ARCH%"=="" (
|
||||
goto out_error
|
||||
)
|
||||
|
||||
set TOOLSET=
|
||||
if NOT "%3"=="" SET TOOLSET=%3
|
||||
|
||||
rem check OS arch
|
||||
rem todo: allow user choose host sdk arch (i.e. x64 target can be compiled at x64(native) or x86(cross))
|
||||
for /f "usebackq tokens=1*" %%i in (`wmic cpu get Architecture /value /format:table ^| findstr /r "[1234567890][1234567890]*"`) do (
|
||||
@@ -119,16 +122,18 @@ if 15 gtr %PHP_SDK_VS_NUM% (
|
||||
if /i "%PHP_SDK_OS_ARCH%"=="arm64" (
|
||||
set APPEND=ARM64
|
||||
)
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo -version !PHP_SDK_VS_RANGE! -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
set VS_VERSION_ARGS="-latest"
|
||||
if "%TOOLSET%"=="" set VS_VERSION_ARGS=-version !PHP_SDK_VS_RANGE!
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo !VS_VERSION_ARGS! -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
set PHP_SDK_VC_DIR=%%b\VC
|
||||
)
|
||||
if not exist "!PHP_SDK_VC_DIR!" (
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo -version !PHP_SDK_VS_RANGE! -products Microsoft.VisualStudio.Product.BuildTools -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo !VS_VERSION_ARGS! -products Microsoft.VisualStudio.Product.BuildTools -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
set PHP_SDK_VC_DIR=%%b\VC
|
||||
)
|
||||
if not exist "!PHP_SDK_VC_DIR!" (
|
||||
rem check for a preview release
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo -version !PHP_SDK_VS_RANGE! -prerelease -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
for /f "tokens=1* delims=: " %%a in ('%~dp0\vswhere -nologo !VS_VERSION_ARGS! -prerelease -requires Microsoft.VisualStudio.Component.VC.Tools.!APPEND! -property installationPath -format text') do (
|
||||
set PHP_SDK_VC_DIR=%%b\VC
|
||||
)
|
||||
if not exist "!PHP_SDK_VC_DIR!" (
|
||||
@@ -199,9 +204,17 @@ if "%HOST_ARCH_NAME%"=="%TARGET_ARCH_NAME%" (
|
||||
set VCVARSALL_ARCH_NAME=%HOST_ARCH_NAME%_%TARGET_ARCH_NAME%
|
||||
)
|
||||
if 15 gtr %PHP_SDK_VS_NUM% (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\vcvarsall.bat" !VCVARSALL_ARCH_NAME!
|
||||
if NOT "%TOOLSET%"=="" (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\vcvarsall.bat" !VCVARSALL_ARCH_NAME! -vcvars_ver=%TOOLSET%
|
||||
) else (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\vcvarsall.bat" !VCVARSALL_ARCH_NAME!
|
||||
)
|
||||
) else (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\Auxiliary\Build\vcvarsall.bat" !VCVARSALL_ARCH_NAME!
|
||||
if NOT "%TOOLSET%"=="" (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\Auxiliary\Build\vcvarsall.bat" !VCVARSALL_ARCH_NAME! -vcvars_ver=%TOOLSET%
|
||||
) else (
|
||||
set PHP_SDK_VS_SHELL_CMD="!PHP_SDK_VC_DIR!\Auxiliary\Build\vcvarsall.bat" !VCVARSALL_ARCH_NAME!
|
||||
)
|
||||
)
|
||||
set VCVARSALL_ARCH_NAME=
|
||||
|
||||
|
||||
@@ -7,10 +7,10 @@ use SDK\Build\Dependency\Fetcher;
|
||||
class Config
|
||||
{
|
||||
/* Config variables. */
|
||||
protected static $depsHost = 'windows.php.net';
|
||||
protected static $depsHost = 'downloads.php.net';
|
||||
protected static $depsPort = 443;
|
||||
protected static $depsUriScheme = "https";
|
||||
protected static $depsBaseUri = "/downloads/php-sdk/deps";
|
||||
protected static $depsBaseUri = "/~windows/php-sdk/deps";
|
||||
|
||||
/* protected static $sdkNugetFeedUrl = "http://127.0.0.1/sdk/nuget"; */
|
||||
|
||||
@@ -148,7 +148,7 @@ class Config
|
||||
$tmp = $fetcher->getByUri(self::$depsBaseUri . "/series/");
|
||||
if (false !== $tmp) {
|
||||
$data = array();
|
||||
if (preg_match_all(",/packages-(.+)-(v[cs]\d+)-(x86|x64|arm64)-(stable|staging)\.txt,U", $tmp, $m, PREG_SET_ORDER)) {
|
||||
if (preg_match_all(",packages-(.+)-(v[cs]\d+)-(x86|x64|arm64)-(stable|staging)\.txt,Us", $tmp, $m, PREG_SET_ORDER)) {
|
||||
foreach ($m as $b) {
|
||||
if (!isset($data[$b[1]])) {
|
||||
$data[$b[1]] = array();
|
||||
|
||||
1912
pgo/tpl/php/php-8.4-pgo-nts-cache.ini
Normal file
1912
pgo/tpl/php/php-8.4-pgo-nts-cache.ini
Normal file
File diff suppressed because it is too large
Load Diff
1898
pgo/tpl/php/php-8.4-pgo-nts.ini
Normal file
1898
pgo/tpl/php/php-8.4-pgo-nts.ini
Normal file
File diff suppressed because it is too large
Load Diff
1912
pgo/tpl/php/php-8.4-pgo-ts-cache.ini
Normal file
1912
pgo/tpl/php/php-8.4-pgo-ts-cache.ini
Normal file
File diff suppressed because it is too large
Load Diff
1898
pgo/tpl/php/php-8.4-pgo-ts.ini
Normal file
1898
pgo/tpl/php/php-8.4-pgo-ts.ini
Normal file
File diff suppressed because it is too large
Load Diff
@@ -14,6 +14,7 @@ set PHP_SDK_ROOT_PATH=%PHP_SDK_ROOT_PATH:~0,-1%
|
||||
if /i "%1" equ "-h" goto help
|
||||
if /i "%1" equ "-c" set CRT=%2 & shift
|
||||
if /i "%1" equ "-a" set ARCH=%2 & shift
|
||||
if /i "%1" equ "-s" set TOOLSET=%2 & shift
|
||||
if /i "%1" equ "-t" set TASK=%2 & shift
|
||||
if /i "%1" equ "--task-args" set TASK_ARGS=%2 & shift
|
||||
shift
|
||||
@@ -37,7 +38,7 @@ set PHP_SDK_RUN_FROM_ROOT=1
|
||||
|
||||
title PHP SDK %CRT% %ARCH%
|
||||
|
||||
call %PHP_SDK_ROOT_PATH%\bin\phpsdk_setshell.bat %CRT% %ARCH%
|
||||
call %PHP_SDK_ROOT_PATH%\bin\phpsdk_setshell.bat %CRT% %ARCH% %TOOLSET%
|
||||
|
||||
set PHP_SDK_RUN_FROM_ROOT=
|
||||
set CRT=
|
||||
|
||||
Reference in New Issue
Block a user