name: github-windows on: workflow_call: concurrency: group: ${ {github.event_name }}-${{ github.workflow }}-${{ github.ref }}-win-x64 cancel-in-progress: ${{github.event_name == 'pull_request'}} permissions: read-all jobs: windows-cuda: # Cuda build on Windows name: Cuda VS-2022 runs-on: windows-2022 steps: - uses: Jimver/cuda-toolkit@b8bf9c6c28f8a92fbb04dcfcaee872e60c57462d # v0.2.36 id: cuda-toolkit with: cuda: '12.4.1' - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: configure shell: bash run: | cmake -B build -DBUILD_SHARED_LIBS=ON -DKokkos_ENABLE_CUDA=ON -DKokkos_ARCH_VOLTA70=ON -DKokkos_ENABLE_TESTS=ON -DKokkos_ENABLE_COMPILE_AS_CMAKE_LANGUAGE=ON - name: build library shell: bash run: | cmake --build build --parallel 4 --config Debug windows-serial: # Serial build on Windows name: Serial VS-2022 runs-on: windows-2025 steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: install gtest shell: bash run: | vcpkg install gtest - name: configure shell: bash run: | cmake -B build -DBUILD_SHARED_LIBS=ON -DKokkos_ENABLE_SERIAL=ON -DKokkos_ENABLE_TESTS=ON -DCMAKE_TOOLCHAIN_FILE=$VCPKG_INSTALLATION_ROOT/scripts/buildsystems/vcpkg.cmake -DCMAKE_REQUIRE_FIND_PACKAGE_GTest=ON - name: build library shell: bash run: | cmake --build build --parallel 4 --config Release - name: run tests shell: bash run: | export PATH="$(pwd)/build/core/src/Release:$(pwd)/build/containers/src/Release:$PATH" ctest --test-dir build -C Release -j 4 --output-on-failure windows-modules: # Modules build on Windows name: Modules VS-2022 runs-on: windows-2025 steps: - name: Setup MSVC uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: configure shell: bash run: | cmake -G Ninja -B build -DKokkos_ENABLE_EXPERIMENTAL_CXX20_MODULES=ON - name: build library shell: bash run: | cmake --build build --parallel 4 --target kokkoscore - name: build and execute example shell: bash run: | cd example/build_cmake_installed_modules cmake -G Ninja -B build -DKokkos_ROOT=../../build . cmake --build build --parallel 4 ctest --test-dir build --verbose windows-clang: # Threads build on Windows using ClangCL name: Threads Clang VS-2022 runs-on: windows-2025 steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - name: configure shell: bash run: | cmake -B build -T ClangCL -DKokkos_ENABLE_SERIAL=ON -DKokkos_ENABLE_THREADS=ON -DKokkos_ENABLE_TESTS=ON - name: build library shell: bash run: | cmake --build build --parallel 4 --config Release - name: run tests shell: bash run: | ctest --test-dir build -C Release -j 4 --output-on-failure