Skip to content

Commit f48af1a

Browse files
committed
Clean up Windows CI workflow and VS project files
Simplify windows-check.yml: remove ${{env.GITHUB_WORKSPACE}} indirection, drop PlatformToolset/WindowsTargetPlatformVersion overrides, add timeout, pin wolfSSL ref, consolidate env vars. Update VS project to v145 toolset, add missing source files to filters, enable multi-processor compilation.
1 parent be40be0 commit f48af1a

4 files changed

Lines changed: 73 additions & 62 deletions

File tree

.github/workflows/windows-check.yml

Lines changed: 38 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -2,67 +2,51 @@ name: Windows Build Test
22

33
on:
44
push:
5-
branches: [ '*' ]
5+
branches: ['*']
66
pull_request:
7-
branches: [ '*' ]
8-
9-
env:
10-
# Path to the solution file relative to the root of the project.
11-
WOLFSSL_SOLUTION_FILE_PATH: wolfssl/wolfssl64.sln
12-
SOLUTION_FILE_PATH: wolfclu.sln
13-
USER_SETTINGS_H_NEW: wolfclu/ide/winvs/user_settings.h
14-
USER_SETTINGS_H: wolfssl/IDE/WIN/user_settings.h
15-
INCLUDE_DIR: wolfclu
16-
17-
# Configuration type to build.
18-
# You can convert this to a build matrix if you need coverage of multiple configuration types.
19-
# https://docs.github.com/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
20-
WOLFSSL_BUILD_CONFIGURATION: Release
21-
WOLFCLU_BUILD_CONFIGURATION: Release
22-
BUILD_PLATFORM: x64
23-
TARGET_PLATFORM: 10
7+
branches: ['*']
248

259
jobs:
2610
build:
2711
runs-on: windows-latest
12+
timeout-minutes: 10
13+
14+
env:
15+
BUILD_PLATFORM: x64
16+
BUILD_CONFIGURATION: Release
2817

2918
steps:
30-
- uses: actions/checkout@v4
31-
with:
32-
repository: wolfssl/wolfssl
33-
path: wolfssl
34-
35-
- uses: actions/checkout@v4
36-
with:
37-
path: wolfclu
38-
39-
- name: Add MSBuild to PATH
40-
uses: microsoft/setup-msbuild@v2
19+
- uses: actions/checkout@v4
20+
with:
21+
repository: wolfssl/wolfssl
22+
ref: master
23+
path: wolfssl
24+
25+
- uses: actions/checkout@v4
26+
with:
27+
path: wolfclu
28+
29+
- name: Add MSBuild to PATH
30+
uses: microsoft/setup-msbuild@v2
31+
32+
- name: Restore wolfSSL NuGet packages
33+
run: nuget restore wolfssl/wolfssl64.sln
34+
35+
- name: Replace user_settings.h
36+
run: cp wolfclu/ide/winvs/user_settings.h wolfssl/IDE/WIN/user_settings.h
37+
38+
- name: Build wolfSSL
39+
run: msbuild /m /p:Platform=${{ env.BUILD_PLATFORM }} /p:Configuration=${{ env.BUILD_CONFIGURATION }} wolfssl/wolfssl64.sln
40+
41+
- name: Restore wolfCLU NuGet packages
42+
working-directory: wolfclu
43+
run: nuget restore wolfclu.sln
4144

42-
- name: Restore wolfSSL NuGet packages
43-
working-directory: ${{env.GITHUB_WORKSPACE}}
44-
run: nuget restore ${{env.WOLFSSL_SOLUTION_FILE_PATH}}
45-
46-
- name: replace with wolfCLU user_settings.h
47-
working-directory: ${{env.GITHUB_WORKSPACE}}
48-
run: cp ${{env.USER_SETTINGS_H_NEW}} ${{env.USER_SETTINGS_H}}
49-
50-
- name: Build wolfssl
51-
working-directory: ${{env.GITHUB_WORKSPACE}}
52-
# Add additional options to the MSBuild command line here (like platform or verbosity level).
53-
# See https://docs.microsoft.com/visualstudio/msbuild/msbuild-command-line-reference
54-
run: msbuild /m /p:PlatformToolset=v142 /p:Platform=${{env.BUILD_PLATFORM}} /p:WindowsTargetPlatformVersion=${{env.TARGET_PLATFORM}} /p:Configuration=${{env.WOLFSSL_BUILD_CONFIGURATION}} ${{env.WOLFSSL_SOLUTION_FILE_PATH}}
45+
- name: Build wolfCLU
46+
working-directory: wolfclu
47+
run: msbuild /m /p:Platform=${{ env.BUILD_PLATFORM }} /p:Configuration=${{ env.BUILD_CONFIGURATION }} wolfclu.sln
5548

56-
- name: Restore NuGet packages
57-
working-directory: ${{env.GITHUB_WORKSPACE}}wolfclu
58-
run: nuget restore ${{env.SOLUTION_FILE_PATH}}
59-
60-
- name: Build
61-
working-directory: ${{env.GITHUB_WORKSPACE}}wolfclu
62-
# Add additional options to the MSBuild command line here (like platform or verbosity level).
63-
# See https://docs.microsoft.com/visualstudio/msbuild/msbuild-command-line-reference
64-
run: msbuild /m /p:PlatformToolset=v142 /p:Platform=${{env.BUILD_PLATFORM}} /p:WindowsTargetPlatformVersion=${{env.TARGET_PLATFORM}} /p:Configuration=${{env.WOLFCLU_BUILD_CONFIGURATION}} ${{env.SOLUTION_FILE_PATH}}
49+
- name: Run tests
50+
working-directory: wolfclu
51+
run: python tests/run_tests.py
6552

66-
- name: Run tests
67-
working-directory: ${{env.GITHUB_WORKSPACE}}wolfclu
68-
run: python tests/run_tests.py

wolfCLU.vcxproj

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,22 +28,22 @@
2828
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
2929
<ConfigurationType>Application</ConfigurationType>
3030
<UseDebugLibraries>true</UseDebugLibraries>
31-
<PlatformToolset>v143</PlatformToolset>
31+
<PlatformToolset>v145</PlatformToolset>
3232
</PropertyGroup>
3333
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
3434
<ConfigurationType>Application</ConfigurationType>
3535
<UseDebugLibraries>false</UseDebugLibraries>
36-
<PlatformToolset>v143</PlatformToolset>
36+
<PlatformToolset>v145</PlatformToolset>
3737
</PropertyGroup>
3838
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
3939
<ConfigurationType>Application</ConfigurationType>
4040
<UseDebugLibraries>true</UseDebugLibraries>
41-
<PlatformToolset>v143</PlatformToolset>
41+
<PlatformToolset>v145</PlatformToolset>
4242
</PropertyGroup>
4343
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
4444
<ConfigurationType>Application</ConfigurationType>
4545
<UseDebugLibraries>false</UseDebugLibraries>
46-
<PlatformToolset>v143</PlatformToolset>
46+
<PlatformToolset>v145</PlatformToolset>
4747
</PropertyGroup>
4848
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
4949
<ImportGroup Label="ExtensionSettings">
@@ -89,6 +89,7 @@
8989
<WarningLevel>Level3</WarningLevel>
9090
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
9191
<Optimization>Disabled</Optimization>
92+
<MultiProcessorCompilation>true</MultiProcessorCompilation>
9293
</ClCompile>
9394
<Link>
9495
<TargetMachine>MachineX86</TargetMachine>
@@ -120,6 +121,7 @@
120121
<ClCompile>
121122
<AdditionalIncludeDirectories>$(ProjectDir);.;./../wolfssl/;../wolfssl/IDE/WIN;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
122123
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;WOLFCLU_EXPORTS;WOLFSSL_LIB;_WINDLL;WOLFSSL_USER_SETTINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
124+
<MultiProcessorCompilation>true</MultiProcessorCompilation>
123125
</ClCompile>
124126
<Link>
125127
<AdditionalDependencies>Ws2_32.lib;wolfssl.lib;%(AdditionalDependencies)</AdditionalDependencies>
@@ -131,6 +133,7 @@
131133
<ClCompile>
132134
<AdditionalIncludeDirectories>$(ProjectDir);.;./../wolfssl/;../wolfssl/IDE/WIN;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
133135
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_USRDLL;WOLFCLU_EXPORTS;WOLFSSL_LIB;_WINDLL;WOLFSSL_USER_SETTINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
136+
<MultiProcessorCompilation>true</MultiProcessorCompilation>
134137
</ClCompile>
135138
<Link>
136139
<AdditionalDependencies>Ws2_32.lib;wolfssl.lib;%(AdditionalDependencies)</AdditionalDependencies>
@@ -210,4 +213,4 @@
210213
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
211214
<ImportGroup Label="ExtensionTargets">
212215
</ImportGroup>
213-
</Project>
216+
</Project>

wolfCLU.vcxproj.filters

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,30 @@
132132
<ClCompile Include="src\x509\clu_x509_sign.c">
133133
<Filter>Source Files</Filter>
134134
</ClCompile>
135+
<ClCompile Include="src\ocsp\clu_ocsp.c">
136+
<Filter>Source Files</Filter>
137+
</ClCompile>
138+
<ClCompile Include="src\pkcs\clu_pkcs8.c">
139+
<Filter>Source Files</Filter>
140+
</ClCompile>
141+
<ClCompile Include="src\server\clu_server_setup.c">
142+
<Filter>Source Files</Filter>
143+
</ClCompile>
144+
<ClCompile Include="src\server\server.c">
145+
<Filter>Source Files</Filter>
146+
</ClCompile>
147+
<ClCompile Include="src\tools\clu_http.c">
148+
<Filter>Source Files</Filter>
149+
</ClCompile>
150+
<ClCompile Include="src\tools\clu_pem_der.c">
151+
<Filter>Source Files</Filter>
152+
</ClCompile>
153+
<ClCompile Include="src\tools\clu_scgi.c">
154+
<Filter>Source Files</Filter>
155+
</ClCompile>
156+
<ClCompile Include="src\tools\clu_base64.c">
157+
<Filter>Source Files</Filter>
158+
</ClCompile>
135159
</ItemGroup>
136160
<ItemGroup>
137161
<ClInclude Include="wolfclu\client.h">
@@ -189,4 +213,4 @@
189213
<Filter>Header Files</Filter>
190214
</ClInclude>
191215
</ItemGroup>
192-
</Project>
216+
</Project>

wolfclu.sln

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio Version 17
4-
VisualStudioVersion = 17.0.32014.148
3+
# Visual Studio Version 18
4+
VisualStudioVersion = 18.4.11620.152 stable
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wolfCLU", "wolfCLU.vcxproj", "{CFC6FB69-7DA4-4E35-851E-776010E92FB3}"
77
EndProject

0 commit comments

Comments
 (0)