-
-
Notifications
You must be signed in to change notification settings - Fork 1
78 lines (63 loc) · 2.22 KB
/
msbuild.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Windows Build
on: [push]
env:
# Path to the solution file relative to the root of the project.
SOLUTION_FILE_PATH: .
# Configuration type to build.
# You can convert this to a build matrix if you need coverage of multiple configuration types.
# https://docs.github.com/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
#
# https://github.com/marketplace/actions/run-vcpkg
# https://github.com/ilammy/msvc-dev-cmd
BUILD_CONFIGURATION: Release
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- name: Clone
uses: actions/checkout@v2
- name: Checkout vscp repo
uses: actions/checkout@v2
with:
repository: grodansparadis/vscp
path: vscp
ref: development
- name: Get latest CMake and ninja
# Using 'latest' branch, the most recent CMake and ninja are installed.
uses: lukka/get-cmake@latest
- name: Add MSBuild to PATH
uses: microsoft/[email protected]
- name: Checkout vcpkg repo
uses: actions/checkout@v2
with:
repository: microsoft/vcpkg
path: vcpkg
- name: Setup vcpkg
run: |
cd vcpkg
bootstrap-vcpkg.bat
vcpkg.exe install integrate install
vcpkg install expat:x64-windows
vcpkg install pthread:x64-windows
vcpkg install dlfcn-win32:x64-windows
vcpkg install openssl:x64-windows
vcpkg install spdlog:x64-windows
cd ..
- name: Install 7Zip PowerShell Module
shell: powershell
run: Install-Module 7Zip4PowerShell -Force -Verbose
- name: Build
run: |
mkdir build
cd build
cmake .. -G "Visual Studio 16 2019" -DVCPKG_TARGET_TRIPLET=x64-windows -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=D:/a/vscp-helper-lib/vscp-helper-lib/vcpkg/scripts/buildsystems/vcpkg.cmake -DVSCP_PATH=vscp
msbuild libvscphelper.sln /p:Configuration=Release
cpack .
# Save artifacts
- uses: actions/upload-artifact@v2
with:
name: windows_libvscphelper
path: ${{github.workspace}}/build/Release/
retention-days: 30