Commit 9940736 1 parent 591cd08 commit 9940736 Copy full SHA for 9940736
File tree 3 files changed +28
-1
lines changed
3 files changed +28
-1
lines changed Original file line number Diff line number Diff line change 57
57
name : frontend
58
58
path : ${{github.workspace}}/frontend
59
59
60
+ - name : Install ninja on windows
61
+ run : choco install ninja
62
+ if : ${{ matrix.os }} == "windows-latest"
63
+
60
64
- name : Build and test
61
65
run : ./make.ps1 -prebuiltFrontend frontend/flipbook.js
62
66
shell : pwsh
Original file line number Diff line number Diff line change @@ -54,7 +54,11 @@ endif()
54
54
55
55
find_package (OpenMP)
56
56
if (OpenMP_CXX_FOUND)
57
- target_link_libraries (SimpleImageIOCore PUBLIC OpenMP::OpenMP_CXX)
57
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS} " )
58
+ set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${OpenMP_EXE_LINKER_FLAGS} " )
59
+ target_link_libraries (SimpleImageIOCore PUBLIC ${OpenMP_CXX_LIBRARIES} )
60
+ target_compile_options (SimpleImageIOCore PUBLIC ${OpenMP_CXX_FLAGS} )
61
+ target_link_options (SimpleImageIOCore PUBLIC ${OpenMP_EXE_LINKER_FLAGS} )
58
62
else ()
59
63
message ("WARNING: Could not find OpenMP! Performance will be lower." )
60
64
endif ()
Original file line number Diff line number Diff line change @@ -80,6 +80,25 @@ if (-not $skipRuntimes)
80
80
cmake -- build . -- config Release
81
81
if (-not $? ) { throw " Build failed" }
82
82
}
83
+ elseif ([environment ]::OSVersion::IsWindows())
84
+ {
85
+ if (Get-Command " ninja" - ErrorAction SilentlyContinue && Get-Command " clang" - ErrorAction SilentlyContinue)
86
+ {
87
+ cmake - G Ninja - DCMAKE_CXX_COMPILER= clang++ - DCMAKE_C_COMPILER= clang - DCMAKE_BUILD_TYPE= Release ..
88
+ if (-not $? ) { throw " CMake configure failed" }
89
+
90
+ cmake -- build . -- config Release
91
+ if (-not $? ) { throw " Build failed" }
92
+ }
93
+ else
94
+ {
95
+ cmake - DCMAKE_BUILD_TYPE= Release ..
96
+ if (-not $? ) { throw " CMake configure failed" }
97
+
98
+ cmake -- build . -- config Release
99
+ if (-not $? ) { throw " Build failed" }
100
+ }
101
+ }
83
102
else
84
103
{
85
104
cmake - DCMAKE_BUILD_TYPE= Release ..
You can’t perform that action at this time.
0 commit comments