add cuda build to ubuntu build matrix

This commit is contained in:
James Ravenscroft 2023-06-13 20:53:06 +01:00
parent ca7ce2f695
commit 021b3913c1

View File

@ -83,10 +83,11 @@ jobs:
defines: '-DGGML_AVX2=OFF'
- build: 'avx512'
defines: '-DGGML_AVX512=ON'
- build: 'openblas'
- build: 'avx2-openblas'
defines: '-DGGML_OPENBLAS=ON'
- build: 'avx2-cuda'
defines: '-DGGML_CUBLAS=ON -DCMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc'
steps:
- uses: actions/checkout@v3
@ -97,9 +98,16 @@ jobs:
run: sudo apt-get update && sudo apt-get install -yq libboost-dev
- name: Install OpenBlas
if: ${{ matrix.build == 'openblas' }}
if: ${{ matrix.build == 'avx2-openblas' }}
run: sudo apt-get install libopenblas-dev
- name: Install CUDA
if: ${{ matrix.build == 'avx2-cuda' }}
run: |
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.0-1_all.deb
sudo dpkg -i cuda-keyring_1.0-1_all.deb
sudo apt-get update && sudo apt-get install -yq libboost-dev cuda-nvcc-11-7 libcublas-dev-11-7
- name: Build
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type