Skip to content

Commit 68e7353

Browse files
committed
Add patch to fix packaging step 7.2.x build
1 parent 26e5140 commit 68e7353

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

php/BuildPhp/private/Get-PhpSrc.ps1

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,13 @@ function Get-PhpSrc {
3838
Get-File -Url $url -Outfile $zipFile
3939
[System.IO.Compression.ZipFile]::ExtractToDirectory($zipFilePath, $currentDirectory)
4040
Rename-Item -Path "php-src-$ref" -NewName $directory
41+
42+
if ($PhpVersion -match '^7\.2\.\d+$') {
43+
Set-Content -Path (Join-Path $directoryPath 'win32/build/mkdist.php') -Value ((Get-Content -Raw -Path (Join-Path $directoryPath 'win32/build/mkdist.php')).Replace('$hdr_data{$i}', '$hdr_data[$i]')) -NoNewline
44+
}
45+
4146
[System.IO.Compression.ZipFile]::CreateFromDirectory($directoryPath, $srcZipFilePath)
4247
}
4348
end {
4449
}
45-
}
50+
}

0 commit comments

Comments
 (0)