Skip to content

Commit 60d0c86

Browse files
committed
added cmake-find-build-windows
1 parent 33e4500 commit 60d0c86

File tree

1 file changed

+71
-0
lines changed

1 file changed

+71
-0
lines changed
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: cmake-find-build-windows
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
ubuntu:
7+
runs-on: ${{ matrix.os }}
8+
strategy:
9+
fail-fast: false
10+
matrix:
11+
os: [windows-latest]
12+
branch: [master, latest, cmake]
13+
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- name: Checkout HiGHS repo
18+
uses: actions/checkout@v4
19+
with:
20+
repository: ERGO-Code/HiGHS
21+
ref: ${{matrix.branch}}
22+
path: HiGHS-${{matrix.branch}}-b
23+
24+
- name: Checkout CMakeHighsFindPackage
25+
uses: actions/checkout@v4
26+
with:
27+
repository: galabovaa/CMakeHighsFindPackage
28+
ref: master
29+
path: CMakeHighsFindPackage-master-${{matrix.branch}}-b
30+
31+
- name: Create build and install dirs
32+
run: |
33+
mkdir ${{runner.workspace}}\\build-highs-${{matrix.branch}}-b
34+
mkdir ${{runner.workspace}}\\build-find-build-${{matrix.branch}}
35+
mkdir ${{runner.workspace}}\\install-find-build-${{matrix.branch}}
36+
37+
- name: Configure CMake HiGHS
38+
working-directory: ${{runner.workspace}}\\build-highs-${{matrix.branch}}-b
39+
run:
40+
cmake ${{runner.workspace}}\\highs-tests\\HiGHS-${{matrix.branch}}-b
41+
42+
- name: Build, ctest and install HiGHS
43+
working-directory: ${{runner.workspace}}\\build-highs-${{matrix.branch}}-b
44+
run: |
45+
cmake --build . --parallel
46+
ctest
47+
48+
- name: Configure CMakeFindHighsPackage
49+
working-directory: ${{runner.workspace}}\\build-find-build-${{matrix.branch}}
50+
run: >-
51+
cmake ${{runner.workspace}}\\highs-tests\\CMakeHighsFindPackage-master-${{matrix.branch}}-b
52+
-DHIGHS_DIR=${{runner.workspace}}\\build-highs-${{matrix.branch}}-b
53+
-DCMAKE_INSTALL_PREFIX=${{runner.workspace}}\\install-find-build-${{matrix.branch}}
54+
55+
- name: Build and install CMakeFindHighsPackage
56+
working-directory: ${{runner.workspace}}\\build-find-build-${{matrix.branch}}
57+
run: |
58+
cmake --build . --parallel --config Release
59+
cmake --install .
60+
61+
- name: Test build
62+
working-directory: ${{runner.workspace}}\\build-find-build-${{matrix.branch}}
63+
shell: bash
64+
run: |
65+
.\\Release\\main.exe
66+
67+
- name: Test install
68+
working-directory: ${{runner.workspace}}\\install-find-build-${{matrix.branch}}
69+
shell: bash
70+
run: |
71+
.\\bin\\main.exe

0 commit comments

Comments
 (0)