Skip to content

Merge pull request #159 from osqp/dependabot/github_actions/pypa/cibu… #308

Merge pull request #159 from osqp/dependabot/github_actions/pypa/cibu…

Merge pull request #159 from osqp/dependabot/github_actions/pypa/cibu… #308

Workflow file for this run

name: Build CUDA
on:
push:
branches:
- master
tags:
- '*'
pull_request:
branches:
- master
jobs:
build_wheels:
name: Build wheel on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-2022]
steps:
- uses: actions/checkout@master
- name: Add msbuild to PATH
uses: microsoft/[email protected]
if: runner.os == 'Windows'
- name: Add Windows SDK
shell: cmd
if: runner.os == 'Windows'
run: |
choco install windows-sdk-8.1
- name: Build wheels
uses: pypa/[email protected]
with:
package-dir: backend/cuda
output-dir: wheelhouse
env:
CIBW_BUILD: "cp3*"
# Temporarily skip 3.13 because it is still an RC and our dependencies aren't there yet
CIBW_SKIP: "cp36-* cp37-* *-win32 *-manylinux_i686 *-musllinux_* *-macosx_* cp313-*"
CIBW_BUILD_VERBOSITY: 1
# Clean the build directory between builds
CIBW_BEFORE_BUILD: >-
rm -rf {package}/osqp_sources/build
CIBW_ENVIRONMENT_LINUX: CMAKE_CUDA_COMPILER=/usr/local/cuda-12.4/bin/nvcc
CIBW_BEFORE_ALL_LINUX: bash .github/workflows/prepare_build_environment_linux_cuda.sh
CIBW_REPAIR_WHEEL_COMMAND_LINUX: ""
CIBW_ENVIRONMENT_WINDOWS: CMAKE_CUDA_COMPILER="C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.5/bin/nvcc.exe" CUDA_TOOLKIT_ROOT_DIR="C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.5" CMAKE_GENERATOR_TOOLSET="cuda=C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.5"
CIBW_BEFORE_ALL_WINDOWS: bash .github/workflows/prepare_build_environment_windows_cuda.sh
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: ""
- name: Upload artifacts to github
uses: actions/upload-artifact@v4
with:
name: wheels-cuda-${{ matrix.os }}
path: ./wheelhouse