Skip to content

Commit 9ae56cd

Browse files
committed
perf: switched to jom for windows builds
1 parent b74e0f7 commit 9ae56cd

11 files changed

Lines changed: 275 additions & 33 deletions

File tree

.github/actions/setup-windows/action.yml

Lines changed: 31 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,38 @@ name: Setup
22
runs:
33
using: composite
44
steps:
5-
- name: Setup MySQL
6-
shell: cmd
7-
run: |
8-
mysqld --initialize-insecure
9-
mysqld --install
10-
net start MySQL
11-
mysql --port=3306 --user=root --password="" -e "ALTER USER 'root'@'localhost' IDENTIFIED BY 'Password12!'; FLUSH PRIVILEGES;"
12-
- name: Setup MSSQL
5+
- name: Setup jom
136
shell: pwsh
147
run: |
15-
choco install sql-server-express -y --no-progress --install-arguments="/SECURITYMODE=SQL /SAPWD=Password12!"
16-
- name: Setup PostgreSQL
8+
$jomDirectory = Join-Path $env:RUNNER_TEMP "jom"
9+
$jomArchive = Join-Path $env:RUNNER_TEMP "jom.zip"
10+
Invoke-WebRequest https://download.qt.io/official_releases/jom/jom_1_1_7.zip -OutFile $jomArchive
11+
if ((Get-FileHash $jomArchive -Algorithm SHA256).Hash -ne "4C8AF345586A9A08FBFD2F613FCAC748226D91A75627AA3581B297DD513046FE") {
12+
throw "Unexpected jom archive checksum"
13+
}
14+
Expand-Archive $jomArchive -DestinationPath $jomDirectory
15+
$jomDirectory | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
16+
- name: Setup sccache
17+
if: ${{ env.CLANG_TOOLSET != '1' }}
1718
shell: pwsh
1819
run: |
19-
$postgresService = if ($env:PHP_BUILD_CRT -eq "vs18") { "postgresql-x64-17" } else { "postgresql-x64-14" }
20-
Set-Service -Name $postgresService -StartupType manual -Status Running
21-
pwsh -Command { $env:PGPASSWORD="root"; & "$env:PGBIN\psql" -U postgres -c "ALTER USER postgres WITH PASSWORD 'Password12!';" }
20+
$sccacheDirectory = Join-Path $env:RUNNER_TEMP "sccache-bin"
21+
$sccacheCacheDirectory = Join-Path $env:RUNNER_TEMP "sccache"
22+
$sccacheArchive = Join-Path $env:RUNNER_TEMP "sccache.zip"
23+
Invoke-WebRequest https://github.com/mozilla/sccache/releases/download/v0.15.0/sccache-v0.15.0-x86_64-pc-windows-msvc.zip -OutFile $sccacheArchive
24+
if ((Get-FileHash $sccacheArchive -Algorithm SHA256).Hash -ne "DCF489090AA5EF4C7D145E8B29F759124C803D636C3107F397BD50D425B5F341") {
25+
throw "Unexpected sccache archive checksum"
26+
}
27+
Expand-Archive $sccacheArchive -DestinationPath $sccacheDirectory
28+
(Join-Path $sccacheDirectory "sccache-v0.15.0-x86_64-pc-windows-msvc") |
29+
Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
30+
"SCCACHE_DIR=$sccacheCacheDirectory" |
31+
Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
32+
- name: Restore compiler cache
33+
if: ${{ env.CLANG_TOOLSET != '1' }}
34+
continue-on-error: true
35+
uses: actions/cache/restore@v5
36+
with:
37+
path: ${{ runner.temp }}\sccache
38+
key: ${{ env.SCCACHE_CACHE_KEY }}
39+
restore-keys: ${{ env.SCCACHE_CACHE_RESTORE_PREFIX }}

.github/matrix.php

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@
88
['name' => 'PHP-8.2', 'ref' => 'PHP-8.2', 'version' => [8, 2]],
99
];
1010

11+
// Temporary while profiling Windows CI builds. Remove after this work is complete.
12+
const WINDOWS_ONLY_CI = true;
13+
const WINDOWS_SINGLE_VARIANT_CI = true;
14+
1115
function get_branch_commit_cache_file_path(): string {
1216
return dirname(__DIR__) . '/branch-commit-cache.json';
1317
}
@@ -180,13 +184,21 @@ function select_jobs($repository, $trigger, $nightly, $labels, $php_version, $re
180184

181185
$labels = json_decode($argv[4] ?? '[]', true) ?? [];
182186
$labels = array_column($labels, 'name');
183-
$all_variations = $nightly || in_array('CI: All variations', $labels, true);
187+
$all_variations = WINDOWS_ONLY_CI || $nightly || in_array('CI: All variations', $labels, true);
184188

185189
$repository = $argv[5] ?? null;
186190

187191
foreach ($branches as &$branch) {
188192
$php_version = $branch['version'][0] . '.' . $branch['version'][1];
189193
$branch['jobs'] = select_jobs($repository, $trigger, $nightly, $labels, $php_version, $branch['ref'], $all_variations);
194+
if (WINDOWS_ONLY_CI) {
195+
$branch['jobs'] = array_intersect_key($branch['jobs'], ['WINDOWS' => true]);
196+
if (WINDOWS_SINGLE_VARIANT_CI) {
197+
$branch['jobs']['WINDOWS']['matrix']['include'] = [
198+
$branch['jobs']['WINDOWS']['matrix']['include'][0],
199+
];
200+
}
201+
}
190202
$branch['config']['ubuntu_version'] = version_compare($php_version, '8.5', '>=') ? '24.04' : '22.04';
191203
}
192204

.github/scripts/windows/build_task.bat

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ if "%CLANG_TOOLSET%" equ "1" (
4141

4242
cmd /c configure.bat ^
4343
--enable-snapshot-build ^
44+
--enable-parallel-build ^
4445
--disable-debug-pack ^
4546
--without-analyzer ^
4647
--enable-object-out-dir=%PHP_BUILD_OBJ_DIR% ^
@@ -49,9 +50,23 @@ cmd /c configure.bat ^
4950
--disable-test-ini
5051
if %errorlevel% neq 0 exit /b 3
5152

52-
nmake /NOLOGO
53+
if "%CLANG_TOOLSET%" equ "1" goto build_clang
54+
55+
sccache --zero-stats
56+
jom /NOLOGO CC="sccache cl.exe"
57+
if %errorlevel% neq 0 exit /b 3
58+
jom /NOLOGO CC="sccache cl.exe" comtest.dll
5359
if %errorlevel% neq 0 exit /b 3
54-
nmake /NOLOGO comtest.dll
60+
sccache --show-stats
61+
sccache --stop-server
62+
goto build_complete
63+
64+
:build_clang
65+
jom /NOLOGO
5566
if %errorlevel% neq 0 exit /b 3
67+
jom /NOLOGO comtest.dll
68+
if %errorlevel% neq 0 exit /b 3
69+
70+
:build_complete
5671

5772
exit /b 0
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
$ErrorActionPreference = "Stop"
2+
3+
function Invoke-NativeCommand {
4+
param(
5+
[string] $Description,
6+
[string] $FilePath,
7+
[string[]] $ArgumentList
8+
)
9+
10+
& $FilePath @ArgumentList
11+
if ($LASTEXITCODE -ne 0) {
12+
throw "$Description exited with code $LASTEXITCODE"
13+
}
14+
}
15+
16+
Invoke-NativeCommand "SQL Server Express installation" "choco.exe" @(
17+
"install",
18+
"sql-server-express",
19+
"-y",
20+
"--no-progress",
21+
"--install-arguments=/SECURITYMODE=SQL /SAPWD=Password12!"
22+
)
23+
24+
Invoke-NativeCommand "MySQL initialization" "mysqld.exe" @("--initialize-insecure")
25+
Invoke-NativeCommand "MySQL service installation" "mysqld.exe" @("--install")
26+
Invoke-NativeCommand "MySQL service startup" "net.exe" @("start", "MySQL")
27+
Invoke-NativeCommand "MySQL root account setup" "mysql.exe" @(
28+
"--port=3306",
29+
"--user=root",
30+
"--password=",
31+
"-e",
32+
"ALTER USER 'root'@'localhost' IDENTIFIED BY 'Password12!'; FLUSH PRIVILEGES;"
33+
)
34+
35+
$postgresService = if ($env:PHP_BUILD_CRT -eq "vs18") { "postgresql-x64-17" } else { "postgresql-x64-14" }
36+
Set-Service -Name $postgresService -StartupType Manual -Status Running
37+
$env:PGPASSWORD = "root"
38+
Invoke-NativeCommand "PostgreSQL account setup" "$env:PGBIN\psql.exe" @(
39+
"-U",
40+
"postgres",
41+
"-c",
42+
"ALTER USER postgres WITH PASSWORD 'Password12!';"
43+
)

.github/workflows/test-suite.yml

Lines changed: 41 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -857,10 +857,14 @@ jobs:
857857
PLATFORM: ${{ matrix.x64 && 'x64' || 'x86' }}
858858
THREAD_SAFE: "${{ matrix.zts && '1' || '0' }}"
859859
INTRINSICS: "${{ matrix.zts && 'AVX2' || '' }}"
860-
PARALLEL: -j2
860+
PARALLEL: -j4
861861
OPCACHE: "${{ matrix.opcache && '1' || '0' }}"
862862
ASAN: "${{ matrix.asan && '1' || '0' }}"
863863
CLANG_TOOLSET: "${{ matrix.clang && '1' || '0' }}"
864+
SCCACHE_CACHE_SIZE: 1G
865+
SCCACHE_IGNORE_SERVER_IO_ERROR: "1"
866+
SCCACHE_CACHE_KEY: windows-sccache-v2-php${{ join(fromJson(inputs.branch).version, '.') }}-${{ fromJson(inputs.branch).jobs.WINDOWS.config.vs_crt_version }}-${{ matrix.x64 && 'x64' || 'x86' }}-zts${{ matrix.zts && '1' || '0' }}-asan${{ matrix.asan && '1' || '0' }}-${{ github.sha }}
867+
SCCACHE_CACHE_RESTORE_PREFIX: windows-sccache-v2-php${{ join(fromJson(inputs.branch).version, '.') }}-${{ fromJson(inputs.branch).jobs.WINDOWS.config.vs_crt_version }}-${{ matrix.x64 && 'x64' || 'x86' }}-zts${{ matrix.zts && '1' || '0' }}-asan${{ matrix.asan && '1' || '0' }}-
864868
steps:
865869
- name: git config
866870
run: git config --global core.autocrlf false && git config --global core.eol lf
@@ -870,10 +874,44 @@ jobs:
870874
ref: ${{ fromJson(inputs.branch).ref }}
871875
- name: Setup
872876
uses: ./.github/actions/setup-windows
873-
- name: Build
874-
run: .github/scripts/windows/build.bat
877+
- name: Build and setup databases
878+
shell: pwsh
879+
run: |
880+
$ErrorActionPreference = "Stop"
881+
$databaseSetup = Resolve-Path .github\scripts\windows\setup_databases.ps1
882+
$databaseJob = Start-Job -FilePath $databaseSetup
883+
884+
& .github\scripts\windows\build.bat
885+
$buildExitCode = $LASTEXITCODE
886+
887+
try {
888+
Receive-Job -Job $databaseJob -Wait -AutoRemoveJob -ErrorAction Stop
889+
} catch {
890+
$databaseError = $_
891+
}
892+
893+
if ($buildExitCode -ne 0) {
894+
throw "PHP build exited with code $buildExitCode"
895+
}
896+
if ($null -ne $databaseError) {
897+
throw "Database setup failed: $databaseError"
898+
}
899+
# Temporary measurement; remove after recording the compiler-cache hit rate.
900+
- name: Benchmark warm compiler cache
901+
if: ${{ !matrix.clang }}
902+
shell: cmd
903+
run: |
904+
rmdir /s /q %PHP_BUILD_OBJ_DIR%
905+
.github\scripts\windows\build.bat
875906
- name: Test
876907
run: .github/scripts/windows/test.bat
908+
- name: Save compiler cache
909+
if: ${{ !matrix.clang && github.event_name != 'pull_request' }}
910+
continue-on-error: true
911+
uses: actions/cache/save@v5
912+
with:
913+
path: ${{ runner.temp }}\sccache
914+
key: ${{ env.SCCACHE_CACHE_KEY }}
877915
FREEBSD:
878916
if: ${{ fromJson(inputs.branch).jobs.FREEBSD }}
879917
strategy:

ext/com_dotnet/Makefile.frag.w32

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,17 @@ $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c: ext\com_dotnet\tests\comt
22
-md $(BUILD_DIR)\ext\com_dotnet\tests\comtest
33
midl /nologo /h $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.h /iid $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c /tlb $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.tlb ext\com_dotnet\tests\comtest\comtest.idl
44

5+
!if "$(PARALLEL_BUILD)" == "yes"
6+
$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj: ext\com_dotnet\tests\comtest\comtest.cpp $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c
7+
$(PHP_CL) /nologo /c /Fo$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj /I $(BUILD_DIR)\ext\com_dotnet\tests\comtest ext\com_dotnet\tests\comtest\comtest.cpp
8+
9+
$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj: $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c
10+
$(PHP_CL) /nologo /c /Fo$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c
11+
!else
512
$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj: ext\com_dotnet\tests\comtest\comtest.cpp $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c
613
$(PHP_CL) /nologo /c /Fo$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj /I $(BUILD_DIR)\ext\com_dotnet\tests\comtest ext\com_dotnet\tests\comtest\comtest.cpp
714
$(PHP_CL) /nologo /c /Fo$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.c
15+
!endif
816

917
$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.dll: $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj ext\com_dotnet\tests\comtest\comtest.def
1018
"$(LINK)" /nologo /dll /out:$(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.dll $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest.obj $(BUILD_DIR)\ext\com_dotnet\tests\comtest\comtest_i.obj /def:ext\com_dotnet\tests\comtest\comtest.def OleAut32.lib

ext/json/Makefile.frag.w32

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
1+
!if "$(PARALLEL_BUILD)" == "yes"
2+
ext\json\php_json_scanner_defs.h: ext\json\json_scanner.c
3+
ext\json\json_scanner.c: ext\json\json_scanner.re ext\json\json_parser.tab.h
4+
$(RE2C) $(RE2C_FLAGS) -t ext/json/php_json_scanner_defs.h -bci -o ext/json/json_scanner.c ext/json/json_scanner.re
5+
6+
ext\json\json_parser.tab.h: ext\json\json_parser.tab.c
7+
ext\json\json_parser.tab.c: ext\json\json_parser.y
8+
$(BISON) $(BISON_FLAGS) --defines -l ext/json/json_parser.y -o ext/json/json_parser.tab.c
9+
!else
110
ext\json\json_scanner.c ext\json\php_json_scanner_defs.h: ext\json\json_scanner.re ext\json\json_parser.tab.h
211
$(RE2C) $(RE2C_FLAGS) -t ext/json/php_json_scanner_defs.h -bci -o ext/json/json_scanner.c ext/json/json_scanner.re
312

413
ext\json\json_parser.tab.c ext\json\json_parser.tab.h: ext\json\json_parser.y
514
$(BISON) $(BISON_FLAGS) --defines -l ext/json/json_parser.y -o ext/json/json_parser.tab.c
15+
!endif

ext/standard/Makefile.frag.w32

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ ext\standard\url_scanner_ex.c: ext\standard\url_scanner_ex.re
66
cd $(PHP_SRC_DIR)
77
$(RE2C) $(RE2C_FLAGS) -b -o ext/standard/url_scanner_ex.c ext/standard/url_scanner_ex.re
88

9-
$(BUILD_DIR)\ext\standard\basic_functions.obj: $(PHP_SRC_DIR)\Zend\zend_language_parser.h
9+
$(BUILD_DIR)\ext\standard\basic_functions.obj: Zend\zend_language_parser.h
1010

1111
$(PHP_SRC_DIR)\ext\standard\tests\helpers\bad_cmd.exe: $(PHP_SRC_DIR)\ext\standard\tests\helpers\bad_cmd.c
1212
cd $(PHP_SRC_DIR)\ext\standard\tests\helpers

win32/build/Makefile

Lines changed: 54 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,31 @@ DEBUGGER_ARGS=
5454

5555
all: generated_files $(EXT_TARGETS) $(PECL_TARGETS) $(SAPI_TARGETS) test_helpers
5656

57+
!if "$(PARALLEL_BUILD)" == "yes"
58+
BUILD_DIR_TARGET=build_dirs
59+
!else
5760
build_dirs: $(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV)
61+
BUILD_DIR_TARGET=$(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV)
62+
!endif
5863

64+
!if "$(PARALLEL_BUILD)" == "yes"
65+
!if $(RE2C) == ""
66+
generated_files: build_dirs .SYNC \
67+
Zend\zend_ini_parser.c Zend\zend_ini_parser.h \
68+
Zend\zend_language_parser.c Zend\zend_language_parser.h \
69+
sapi\phpdbg\phpdbg_parser.c sapi\phpdbg\phpdbg_parser.h \
70+
$(PHPDEF) $(MCFILE)
71+
!else
72+
generated_files: build_dirs .SYNC \
73+
Zend\zend_ini_parser.c Zend\zend_ini_parser.h \
74+
Zend\zend_language_parser.c Zend\zend_language_parser.h \
75+
Zend\zend_ini_scanner.c Zend\zend_ini_scanner_defs.h \
76+
Zend\zend_language_scanner.c Zend\zend_language_scanner_defs.h \
77+
sapi\phpdbg\phpdbg_parser.c sapi\phpdbg\phpdbg_parser.h \
78+
sapi\phpdbg\phpdbg_lexer.c \
79+
$(PHPDEF) $(MCFILE)
80+
!endif
81+
!else
5982
!if $(RE2C) == ""
6083
generated_files: build_dirs \
6184
Zend\zend_ini_parser.c Zend\zend_ini_parser.h \
@@ -71,10 +94,28 @@ generated_files: build_dirs \
7194
sapi\phpdbg\phpdbg_parser.c sapi\phpdbg\phpdbg_lexer.c \
7295
$(PHPDEF) $(MCFILE)
7396
!endif
97+
!endif
7498

7599
$(BUILD_DIR)\$(PHPDLL).def: $(PHP_DLL_DEF_SOURCES)
76100
type $(PHP_DLL_DEF_SOURCES) > $(BUILD_DIR)\$(PHPDLL).def
77101

102+
!if "$(PARALLEL_BUILD)" == "yes"
103+
# Bison and re2c generate two files per invocation. Give the recipe to one
104+
# target and make the side-effect output depend on it, so jom runs it once.
105+
Zend\zend_ini_parser.h: Zend\zend_ini_parser.c
106+
Zend\zend_ini_parser.c: Zend\zend_ini_parser.y
107+
$(BISON) $(BISON_FLAGS) --output=Zend/zend_ini_parser.c -v -d Zend/zend_ini_parser.y
108+
109+
Zend\zend_language_parser.h: Zend\zend_language_parser.c
110+
Zend\zend_language_parser.c: Zend\zend_language_parser.y
111+
$(BISON) $(BISON_FLAGS) --output=Zend/zend_language_parser.c -v -d Zend/zend_language_parser.y
112+
@if "$(SED)" neq "" $(SED) -i "s,^int zendparse\(.*\),ZEND_API int zendparse\1,g" Zend/zend_language_parser.c
113+
@if "$(SED)" neq "" $(SED) -i "s,^int zendparse\(.*\),ZEND_API int zendparse\1,g" Zend/zend_language_parser.h
114+
115+
sapi\phpdbg\phpdbg_parser.h: sapi\phpdbg\phpdbg_parser.c
116+
sapi\phpdbg\phpdbg_parser.c: sapi\phpdbg\phpdbg_parser.y
117+
$(BISON) $(BISON_FLAGS) --output=sapi/phpdbg/phpdbg_parser.c -v -d sapi/phpdbg/phpdbg_parser.y
118+
!else
78119
Zend\zend_ini_parser.c Zend\zend_ini_parser.h: Zend\zend_ini_parser.y
79120
$(BISON) $(BISON_FLAGS) --output=Zend/zend_ini_parser.c -v -d Zend/zend_ini_parser.y
80121

@@ -85,13 +126,24 @@ Zend\zend_language_parser.c Zend\zend_language_parser.h: Zend\zend_language_pars
85126

86127
sapi\phpdbg\phpdbg_parser.c sapi\phpdbg\phpdbg_parser.h: sapi\phpdbg\phpdbg_parser.y
87128
$(BISON) $(BISON_FLAGS) --output=sapi/phpdbg/phpdbg_parser.c -v -d sapi/phpdbg/phpdbg_parser.y
129+
!endif
88130

89131
!if $(RE2C) != ""
132+
!if "$(PARALLEL_BUILD)" == "yes"
133+
Zend\zend_ini_scanner_defs.h: Zend\zend_ini_scanner.c
134+
Zend\zend_ini_scanner.c: Zend\zend_ini_scanner.l
135+
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l
136+
137+
Zend\zend_language_scanner_defs.h: Zend\zend_language_scanner.c
138+
Zend\zend_language_scanner.c: Zend\zend_language_scanner.l
139+
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l
140+
!else
90141
Zend\zend_ini_scanner.c Zend\zend_ini_scanner_defs.h: Zend\zend_ini_scanner.l
91142
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_ini_scanner_defs.h -oZend/zend_ini_scanner.c Zend/zend_ini_scanner.l
92143

93144
Zend\zend_language_scanner.c Zend\zend_language_scanner_defs.h: Zend\zend_language_scanner.l
94145
$(RE2C) $(RE2C_FLAGS) --case-inverted -cbdFt Zend/zend_language_scanner_defs.h -oZend/zend_language_scanner.c Zend/zend_language_scanner.l
146+
!endif
95147

96148
sapi\phpdbg\phpdbg_lexer.c: sapi\phpdbg\phpdbg_lexer.l
97149
$(RE2C) $(RE2C_FLAGS) -cbdFo sapi/phpdbg/phpdbg_lexer.c sapi/phpdbg/phpdbg_lexer.l
@@ -124,7 +176,7 @@ _VC_MANIFEST_EMBED_EXE= if exist $@.manifest $(MT) -nologo -manifest $@.manifest
124176
_VC_MANIFEST_EMBED_DLL= if exist $@.manifest $(MT) -nologo -manifest $@.manifest -outputresource:$@;2
125177
!endif
126178

127-
$(PHPDLL_RES): win32\build\template.rc
179+
$(PHPDLL_RES): generated_files $(MCFILE) win32\build\template.rc
128180
$(RC) /nologo /fo $(PHPDLL_RES) /d FILE_DESCRIPTION="\"PHP Script Interpreter\"" \
129181
/d FILE_NAME="\"$(PHPDLL)\"" /d PRODUCT_NAME="\"PHP Script Interpreter\"" \
130182
/I$(BUILD_DIR) /d MC_INCLUDE="\"$(MCFILE)\"" \
@@ -138,7 +190,7 @@ $(BUILD_DIR)\$(PHPDLL): generated_files $(PHPDEF) $(PHP_GLOBAL_OBJS) $(STATIC_EX
138190

139191
$(BUILD_DIR)\$(PHPLIB): $(BUILD_DIR)\$(PHPDLL)
140192

141-
$(BUILD_DIR) $(BUILD_DIRS_SUB) $(BUILD_DIR_DEV):
193+
$(BUILD_DIR_TARGET):
142194
@echo Recreating build dirs
143195
@if not exist $(BUILD_DIR) mkdir $(BUILD_DIR)
144196
@cd $(BUILD_DIR)

0 commit comments

Comments
 (0)