mirror of
https://github.com/php-win-ext/winlib-builder.git
synced 2026-03-25 09:42:10 +01:00
This fixes the test failures we've got so far[1]. [1] <https://github.com/winlibs/winlib-builder/actions/runs/11526064416>
69 lines
2.3 KiB
YAML
69 lines
2.3 KiB
YAML
name: Build openssl
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
version:
|
|
description: openssl tag to build
|
|
required: true
|
|
php:
|
|
description: PHP version to build for
|
|
required: true
|
|
defaults:
|
|
run:
|
|
shell: cmd
|
|
jobs:
|
|
build:
|
|
strategy:
|
|
matrix:
|
|
arch: [x64, x86]
|
|
runs-on: windows-2022
|
|
steps:
|
|
- name: Set git to use LF
|
|
run: |
|
|
git config --global core.autocrlf false
|
|
git config --global core.eol lf
|
|
- name: Checkout winlib-builder
|
|
uses: actions/checkout@v4
|
|
with:
|
|
path: winlib-builder
|
|
- name: Checkout openssl
|
|
uses: actions/checkout@v4
|
|
with:
|
|
path: openssl
|
|
repository: winlibs/openssl
|
|
ref: ${{github.event.inputs.version}}
|
|
- name: Compute virtual inputs
|
|
id: virtuals
|
|
run: powershell winlib-builder/scripts/compute-virtuals -version ${{github.event.inputs.php}} -arch ${{matrix.arch}}
|
|
- name: Setup MSVC development environment
|
|
uses: ilammy/msvc-dev-cmd@v1
|
|
with:
|
|
arch: ${{matrix.arch}}
|
|
toolset: ${{steps.virtuals.outputs.toolset}}
|
|
- name: Setup NASM
|
|
uses: ilammy/setup-nasm@v1
|
|
- name: Configure openssl for x64
|
|
if: ${{matrix.arch == 'x64'}}
|
|
run: cd openssl && perl Configure VC-WIN64A --prefix=C:\usr\local\ssl --openssldir="C:/Program Files/Common Files/SSL" no-dynamic-engine
|
|
- name: Configure openssl for x86
|
|
if: ${{matrix.arch == 'x86'}}
|
|
run: cd openssl && perl Configure VC-WIN32 --prefix=C:\usr\local\ssl --openssldir="C:/Program Files (x86)/Common Files/SSL" no-dynamic-engine
|
|
- name: Build openssl
|
|
run: cd openssl && nmake
|
|
- name: Test openssl
|
|
continue-on-error: true
|
|
run: cd openssl && nmake test
|
|
- name: Install openssl
|
|
run: |
|
|
cd openssl
|
|
nmake install
|
|
xcopy C:\usr\local\ssl\bin ..\install\bin\*
|
|
xcopy /e C:\usr\local\ssl\include ..\install\include\*
|
|
xcopy /s /e C:\usr\local\ssl\lib ..\install\lib\*
|
|
xcopy apps\openssl.cnf ..\install\*
|
|
- name: Upload artifacts
|
|
uses: actions/upload-artifact@v4
|
|
with:
|
|
name: ${{github.event.inputs.version}}-${{steps.virtuals.outputs.vs}}-${{matrix.arch}}
|
|
path: install
|