ci: load compiler extension dependencies

master
韩天峰 3 weeks ago
parent 689ffee831
commit 6fe13b9548
  1. 10
      .github/workflows/linux-x64.yml
  2. 5
      .github/workflows/windows-build.yml

@ -329,10 +329,20 @@ jobs:
run: |
test -f ./tpc
test -f "${PHPX_HOME}/lib/libphpx.so"
test -f third_party/phpy/modules/phpy.so
test -f "${PHP_HOME}/lib/libphp.so"
chmod +x ./tpc
echo "LD_LIBRARY_PATH=${PHPX_HOME}/lib:${PHP_HOME}/lib" >> "${GITHUB_ENV}"
- name: Enable phpy extension for compiler
shell: bash
run: |
php_ini_dir="$(php-config --ini-dir)"
echo "extension=${GITHUB_WORKSPACE}/third_party/phpy/modules/phpy.so" \
| sudo tee "${php_ini_dir}/90-phpy.ini"
echo "PHP_INI_SCAN_DIR=${php_ini_dir}" >> "${GITHUB_ENV}"
php --ri phpy
- name: Run EXT/LIB integration tests
shell: bash
run: |

@ -42,7 +42,7 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: none
extensions: zip
extensions: zip, mbstring
tools: composer:v2
env:
fail-fast: true
@ -350,11 +350,13 @@ jobs:
run: |
$ErrorActionPreference = 'Stop'
$env:PHPRC = Join-Path $env:PHP_HOME 'php.ini'
$env:PATH = "$env:PHPX_HOME\build;$env:PATH"
& .\tpc.exe tests\windows\smoke\project.yml --job 1 --no-progress
if ($LASTEXITCODE -ne 0) {
throw "Windows smoke project compilation failed with exit code $LASTEXITCODE"
}
Remove-Item Env:PHPRC
$smokeExe = Join-Path '${{ github.workspace }}' 'tests\windows\smoke\windows_smoke.exe'
if (-not (Test-Path $smokeExe)) {
@ -392,6 +394,7 @@ jobs:
shell: pwsh
run: |
$ErrorActionPreference = 'Stop'
$env:PHPRC = Join-Path $env:PHP_HOME 'php.ini'
composer install --no-dev --prefer-dist --no-progress --classmap-authoritative
if ($LASTEXITCODE -ne 0) {

Loading…
Cancel
Save