Skip to content

Commit

Permalink
Fix path
Browse files Browse the repository at this point in the history
  • Loading branch information
WeiqunZhang committed Sep 20, 2024
1 parent aaccac6 commit bde5934
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/cuda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ jobs:
.github/workflows/dependencies/dependencies_nvcc.sh
- name: Tests
run: |
export PATH=/usr/local/cuda/bin:${PATH}
export LD_LIBRARY_PATH=/usr/local/cuda/lib64:${LD_LIBRARY_PATH}
which nvcc || echo "nvcc not in PATH!"
cd Tests/GPU
make -j4 USE_CUDA=TRUE
./main.gnu.ex
10 changes: 6 additions & 4 deletions .github/workflows/dependencies/dependencies_nvcc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ distro=ubuntu$(sed 's/\.//' <<< ${VERSION_ID})
wget https://developer.download.nvidia.com/compute/cuda/repos/${distro}/x86_64/cuda-keyring_1.1-1_all.deb
sudo dpkg -i cuda-keyring_1.1-1_all.deb
sudo apt-get update
CUDA_VERSION=$(apt-cache search cuda-compiler* | tail -n1 | cut -d' ' -f1 | sed 's/cuda-compiler-//')
VERSION_DASHED=$(apt-cache search cuda-compiler* | tail -n1 | cut -d' ' -f1 | sed 's/cuda-compiler-//')
VERSON_DOTTED=$(sed 's/-/\./' <<< $VERSION_DASHED)
sudo apt-get install -y \
cuda-command-line-tools-$CUDA_VERSION \
cuda-compiler-$CUDA_VERSION \
cuda-minimal-build-$CUDA_VERSION
cuda-command-line-tools-$VERSION_DASHED \
cuda-compiler-$VERSION_DASHED \
cuda-minimal-build-$VERSION_DASHED
sudo ln -s cuda-$VERSION_DOTTED /usr/local/cuda
2 changes: 1 addition & 1 deletion .github/workflows/gcc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ jobs:
make -j4
./main.gnu.ex
cd Tests/GPU
cd ../GPU
make -j4 USE_CPU=TRUE
./main.gnu.ex

0 comments on commit bde5934

Please sign in to comment.