diff --git a/.github/workflows/dependencies/dependencies_hip.sh b/.github/workflows/dependencies/dependencies_hip.sh index c1e64800..b7fab89f 100755 --- a/.github/workflows/dependencies/dependencies_hip.sh +++ b/.github/workflows/dependencies/dependencies_hip.sh @@ -13,9 +13,9 @@ set -eu -o pipefail # Ref.: https://rocmdocs.amd.com/en/latest/Installation_Guide/Installation-Guide.html#ubuntu -wget -q -O - http://repo.radeon.com/rocm/rocm.gpg.key \ - | sudo apt-key add - -echo 'deb [arch=amd64] http://repo.radeon.com/rocm/apt/debian/ ubuntu main' \ +curl -O https://repo.radeon.com/rocm/rocm.gpg.key +sudo apt-key add rocm.gpg.key +echo "deb [arch=amd64] https://repo.radeon.com/rocm/apt/${1-debian}/ ubuntu main" \ | sudo tee /etc/apt/sources.list.d/rocm.list echo 'export PATH=/opt/rocm/llvm/bin:/opt/rocm/bin:/opt/rocm/profiler/bin:/opt/rocm/opencl/bin:$PATH' \ @@ -47,6 +47,7 @@ sudo apt-get install -y --no-install-recommends \ # source /etc/profile.d/rocm.sh hipcc --version +hipconfig --full which clang which clang++ diff --git a/.github/workflows/dependencies/dependencies_nvcc10.sh b/.github/workflows/dependencies/dependencies_nvcc10.sh index a91a4d8a..af5a14e0 100755 --- a/.github/workflows/dependencies/dependencies_nvcc10.sh +++ b/.github/workflows/dependencies/dependencies_nvcc10.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash # -# Copyright 2020 Axel Huebl +# Copyright 2020-2022 Axel Huebl # # License: BSD-3-Clause-LBNL @@ -11,27 +11,34 @@ set -eu -o pipefail -sudo apt-get update +# `man apt.conf`: +# Number of retries to perform. If this is non-zero APT will retry +# failed files the given number of times. +echo 'Acquire::Retries "3";' | sudo tee /etc/apt/apt.conf.d/80-retries -sudo apt-get install -y --no-install-recommends\ +sudo apt-get -qqq update +sudo apt-get install -y \ build-essential \ - g++-6 \ + ca-certificates \ + cmake \ + g++ \ + gfortran \ + gnupg \ libopenmpi-dev \ openmpi-bin \ + pkg-config \ + wget -sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/3bf863cc.pub -echo "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64 /" \ - | sudo tee /etc/apt/sources.list.d/cuda.list +VERSION_DOTTED=${1-12.0} && VERSION_DASHED=$(sed 's/\./-/' <<< $VERSION_DOTTED) +curl -O https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/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 -y \ - cuda-command-line-tools-10-2 \ - cuda-compiler-10-2 \ - cuda-cupti-dev-10-2 \ - cuda-minimal-build-10-2 \ - cuda-nvml-dev-10-2 \ - cuda-nvtx-10-2 \ - cuda-curand-dev-10-2 \ - cuda-cusolver-dev-10-2 \ - cuda-cublas-dev-10-2 \ - cuda-cusparse-dev-10-2 -sudo ln -s cuda-10.2 /usr/local/cuda + cuda-command-line-tools-$VERSION_DASHED \ + cuda-compiler-$VERSION_DASHED \ + cuda-cupti-dev-$VERSION_DASHED \ + cuda-minimal-build-$VERSION_DASHED \ + cuda-nvml-dev-$VERSION_DASHED \ + cuda-nvtx-$VERSION_DASHED \ + libcurand-dev-$VERSION_DASHED +sudo ln -s cuda-$VERSION_DOTTED /usr/local/cuda diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index a03a8688..b23a3d21 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -43,7 +43,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Dependencies - run: .github/workflows/dependencies/dependencies_nvcc10.sh + run: .github/workflows/dependencies/dependencies_nvcc10.sh 10.2 - name: Build & Install run: | export PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:${PATH}