|
17 | 17 | - 'docs/**' |
18 | 18 |
|
19 | 19 | jobs: |
20 | | - build: |
| 20 | + build-linux: |
21 | 21 | runs-on: ubuntu-latest |
22 | 22 | strategy: |
23 | 23 | matrix: |
|
67 | 67 | -DCMAKE_BUILD_TYPE=${BUILD_TYPE} \ |
68 | 68 | -DCMAKE_PREFIX_PATH:PATH="$PWD/../../popsift_install;${DEPS_INSTALL_DIR}" |
69 | 69 | make -j$(nproc) |
| 70 | +
|
| 71 | + build-windows: |
| 72 | + runs-on: windows-2022 |
| 73 | + strategy: |
| 74 | + matrix: |
| 75 | + build_type: ["Release", "Debug"] |
| 76 | + cuda_version: ["12.5.1"] |
| 77 | + |
| 78 | + env: |
| 79 | + BUILD_TYPE: ${{ matrix.build_type }} |
| 80 | + CTEST_OUTPUT_ON_FAILURE: 1 |
| 81 | + |
| 82 | + steps: |
| 83 | + - uses: actions/checkout@v4 |
| 84 | + |
| 85 | + - name: Install CUDA |
| 86 | + |
| 87 | + with: |
| 88 | + cuda: ${{ matrix.cuda_version }} |
| 89 | + method: 'network' |
| 90 | + sub-packages: '["nvcc", "cudart", "nvtx", "visual_studio_integration"]' |
| 91 | + |
| 92 | + - name: Set up vcpkg |
| 93 | + uses: lukka/run-vcpkg@v11 |
| 94 | + with: |
| 95 | + vcpkgDirectory: '${{ runner.workspace }}/vcpkg' |
| 96 | + vcpkgGitCommitId: 'f7423ee180c4b7f40d43402c2feb3859161ef625' |
| 97 | + |
| 98 | + - name: Install vcpkg dependencies |
| 99 | + run: | |
| 100 | + ${{ runner.workspace }}/vcpkg/vcpkg.exe install boost-system boost-program-options boost-thread boost-filesystem --triplet x64-windows |
| 101 | +
|
| 102 | + - name: Configure CMake |
| 103 | + run: | |
| 104 | + mkdir build |
| 105 | + cd build |
| 106 | + cmake .. -G "Visual Studio 17 2022" -A x64 ` |
| 107 | + -DBUILD_SHARED_LIBS:BOOL=ON ` |
| 108 | + -DPopSift_USE_NVTX_PROFILING:BOOL=OFF ` |
| 109 | + -DPopSift_USE_GRID_FILTER:BOOL=OFF ` |
| 110 | + -DPopSift_BUILD_DOCS:BOOL=OFF ` |
| 111 | + -DPopSift_USE_POSITION_INDEPENDENT_CODE:BOOL=ON ` |
| 112 | + -DPopSift_BUILD_EXAMPLES:BOOL=ON ` |
| 113 | + -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} ` |
| 114 | + -DCMAKE_INSTALL_PREFIX="${{ github.workspace }}/install" ` |
| 115 | + -DCMAKE_TOOLCHAIN_FILE="${{ runner.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" |
| 116 | +
|
| 117 | + - name: Build and Install |
| 118 | + run: | |
| 119 | + cd build |
| 120 | + cmake --build . --config ${{ matrix.build_type }} --parallel |
| 121 | + cmake --build . --config ${{ matrix.build_type }} --target install |
| 122 | +
|
| 123 | + - name: Build As Third Party |
| 124 | + run: | |
| 125 | + mkdir build_as_3rdparty |
| 126 | + cd build_as_3rdparty |
| 127 | + cmake ../src/application -G "Visual Studio 17 2022" -A x64 ` |
| 128 | + -DBUILD_SHARED_LIBS:BOOL=ON ` |
| 129 | + -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} ` |
| 130 | + -DCMAKE_PREFIX_PATH="${{ github.workspace }}/install" ` |
| 131 | + -DCMAKE_TOOLCHAIN_FILE="${{ runner.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake" |
| 132 | + cmake --build . --config ${{ matrix.build_type }} --parallel |
0 commit comments