diff --git a/.github/workflows/extensions.yml b/.github/workflows/extensions.yml new file mode 100644 index 00000000..4714cd9a --- /dev/null +++ b/.github/workflows/extensions.yml @@ -0,0 +1,53 @@ +name: Build PHP Extension +on: + workflow_dispatch: + inputs: + extension_url: + description: 'Extension URL' + required: true + extension_ref: + description: 'Extension ref' + required: true +jobs: + get-extension-matrix: + runs-on: ubuntu-latest + outputs: + matrix: ${{ steps.extension-matrix.outputs.matrix }} + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Get the extension matrix + id: extension-matrix + uses: ./extension-matrix + with: + extension-url: ${{ inputs.extension_url }} + extension-ref: ${{ inputs.extension_ref }} + arch-list: 'x64, x86' + ts-list: 'nts, ts' + + extension: + needs: get-extension-matrix + runs-on: ${{ matrix.os }} + strategy: + matrix: ${{fromJson(needs.get-extension-matrix.outputs.matrix)}} + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Build the extension + uses: ./extension + with: + extension-url: ${{ inputs.extension_url }} + extension-ref: ${{ inputs.extension_ref }} + php-version: ${{ matrix.php-version }} + arch: ${{ matrix.arch }} + ts: ${{ matrix.ts }} + + artifacts: + runs-on: ubuntu-latest + needs: extension + steps: + - name: Upload artifacts + uses: actions/upload-artifact/merge@v4 + with: + name: artifacts + delete-merged: true diff --git a/.github/workflows/php8.2.18.yml b/.github/workflows/php8.2.18.yml new file mode 100644 index 00000000..16c40ce4 --- /dev/null +++ b/.github/workflows/php8.2.18.yml @@ -0,0 +1,29 @@ +name: Build PHP 8.2.18 +on: + release: + types: [published] +jobs: + php: + strategy: + matrix: + arch: x64 + ts: nts + runs-on: windows-2019 + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Build + uses: ./php + with: + php-version: ${{ github.event.inputs.php-version }} + arch: ${{ matrix.arch }} + ts: ${{ matrix.ts }} + + release: + runs-on: ubuntu-latest + steps: + - name: Upload artifact to the release + uses: php/php-windows-builder/release@v1 + with: + release: 8.2.18 + token: ${{ secrets.PHP_TOKEN }}