Skip to content

ci/win: try self build openssl #3079

ci/win: try self build openssl

ci/win: try self build openssl #3079

Workflow file for this run

name: CMake and Windows
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Windows Debug",
os: windows-2022,
environment_script: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvars64.bat",
generators: "Ninja",
build: "Debug",
openssl: "VC-WIN64A",
testing: true
}
- {
name: "Windows Release",
os: windows-2022,
environment_script: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvars64.bat",
generators: "Ninja",
build: "Release",
openssl: "VC-WIN64A",
testing: true
}
- {
name: "Windows Debug 32-bit",
os: windows-2022,
environment_script: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvarsamd64_x86.bat",
generators: "Ninja",
build: "Debug",
openssl: "VC-WIN32",
testing: false
}
- {
name: "Windows Debug ARM64",
os: windows-2022,
environment_script: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvarsamd64_arm64.bat",
generators: "Ninja",
build: "Debug",
openssl: "VC-WIN64-ARM",
testing: false
}
steps:
- uses: actions/checkout@v4
- uses: ilammy/setup-nasm@v1
- uses: actions/cache@v3
id: openssl
with:
path: C:\\Program Files\OpenSSL
key: ${{ runner.os }}-${ matrix.config.openssl }-openssl-3.1.4
- name: Build OpenSSL
shell: cmd
run: |
call "${{ matrix.config.environment_script }}"
C:\msys64\usr\bin\wget.exe https://www.openssl.org/source/openssl-3.1.4.tar.gz
C:\msys64\usr\bin\tar.exe -xzf openssl-3.1.4.tar.gz
cd openssl-3.1.4
perl Configure ${{ matrix.config.openssl }}
nmake && nmake install
- name: Build
shell: cmd
run: |
call "${{ matrix.config.environment_script }}"
cmake --version
ninja --version
cmake -S . -B build -G "${{ matrix.config.generators }}" -DCMAKE_C_FLAGS="/WX" -DCMAKE_BUILD_TYPE=${{ matrix.config.build }} -DCMAKE_DISABLE_FIND_PACKAGE_OpenSSL=${{ matrix.config.disable_openssl }}
cmake --build build --parallel -t retest
- name: retest
if: ${{ matrix.config.testing }}
shell: cmd
run: |
build\test\retest.exe -a -v