Skip to content

Commit

Permalink
[ci] Update cudaInstallAppveyor.cmd
Browse files Browse the repository at this point in the history
added dependencies on CUDAToolkit to config file
change CC from native to all-major because build system has no GPU
platform toolset for VS19
disable NVTX explicitly
  • Loading branch information
Carsten Griwodz committed Jul 31, 2024
1 parent ddbc2e5 commit 7bbad38
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 16 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ project(PopSift VERSION 1.0.0 LANGUAGES CXX CUDA)
# Since CMake 3.18. See https://cmake.org/cmake/help/latest/policy/CMP0104.html
cmake_policy(SET CMP0104 NEW)

set(CMAKE_CUDA_ARCHITECTURES "native"
set(CMAKE_CUDA_ARCHITECTURES "all-major"
CACHE
STRING "Which CUDA CCs to support: native, all, all-major or an explicit list delimited by semicolons"
FORCE)
Expand Down
6 changes: 3 additions & 3 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
version: '1.0.{build}'

image: Visual Studio 2015
image: Visual Studio 2022

platform:
- x64

configuration:
- Release
- Debug
# - Debug

#environment:
# matrix:
Expand All @@ -26,7 +26,7 @@ install:
before_build:
- md build
- cd build
- cmake -G "Visual Studio 14 2015" -A x64 -T v140,host=x64 -DBUILD_SHARED_LIBS=%DBUILD_SHARED_LIBS% -DPopSift_BUILD_DOCS:BOOL=OFF -DPopSift_USE_POSITION_INDEPENDENT_CODE:BOOL=%DBUILD_SHARED_LIBS% -DPopSift_BUILD_EXAMPLES:BOOL=ON -DCMAKE_BUILD_TYPE=%configuration% -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake ..
- cmake -G "Visual Studio 17 2022" -A x64 -T v143,host=x64,cuda="%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5" -DBUILD_SHARED_LIBS=%DBUILD_SHARED_LIBS% -DPopSift_USE_NVTX_PROFILING:BOOL=OFF -DPopSift_BUILD_DOCS:BOOL=OFF -DPopSift_USE_POSITION_INDEPENDENT_CODE:BOOL=%DBUILD_SHARED_LIBS% -DPopSift_BUILD_EXAMPLES:BOOL=ON -DCMAKE_BUILD_TYPE=%configuration% -DCMAKE_TOOLCHAIN_FILE=c:/tools/vcpkg/scripts/buildsystems/vcpkg.cmake ..
- ls -l

build:
Expand Down
1 change: 1 addition & 0 deletions cmake/Config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@

include(CMakeFindDependencyMacro)
find_dependency(Threads REQUIRED)
find_dependency(CUDAToolkit REQUIRED)

include("${CMAKE_CURRENT_LIST_DIR}/@[email protected]")
check_required_components("@PROJECT_NAME@")
49 changes: 37 additions & 12 deletions cudaInstallAppveyor.cmd
Original file line number Diff line number Diff line change
@@ -1,19 +1,44 @@
@echo off
echo Downloading CUDA toolkit 9
appveyor DownloadFile https://developer.nvidia.com/compute/cuda/9.1/Prod/local_installers/cuda_9.1.85_windows -FileName cuda_9.1.85_windows.exe
echo Downloading CUDA toolkit 12 for Windows 10
# appveyor DownloadFile https://developer.download.nvidia.com/compute/cuda/12.5.1/network_installers/cuda_12.5.1_windows_network.exe -Filename cuda_12.5.1_windows.exe

appveyor DownloadFile https://developer.download.nvidia.com/compute/cuda/redist/cuda_nvcc/windows-x86_64/cuda_nvcc-windows-x86_64-12.5.82-archive.zip -Filename cuda_nvcc.zip
appveyor DownloadFile https://developer.download.nvidia.com/compute/cuda/redist/cuda_cudart/windows-x86_64/cuda_cudart-windows-x86_64-12.5.82-archive.zip -Filename cuda_cudart.zip
appveyor DownloadFile https://developer.download.nvidia.com/compute/cuda/redist/cuda_nvtx/windows-x86_64/cuda_nvtx-windows-x86_64-12.5.82-archive.zip -Filename cuda_nvtx.zip
appveyor DownloadFile https://developer.download.nvidia.com/compute/cuda/redist/visual_studio_integration/windows-x86_64/visual_studio_integration-windows-x86_64-12.5.82-archive.zip -Filename vs_integration.zip
dir

echo Unzipping CUDA toolkit 12
tar -xf cuda_nvcc.zip
tar -xf cuda_cudart.zip
tar -xf cuda_nvtx.zip
tar -xf vs_integration.zip
dir
echo Installing CUDA toolkit 9
cuda_9.1.85_windows.exe -s nvcc_9.1 ^
cublas_9.1 ^
cublas_dev_9.1 ^
cudart_9.1 ^
curand_9.1 ^
curand_dev_9.1

echo CUDA toolkit 9 installed
echo Making CUDA install dir(s)
mkdir "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5"
mkdir "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5\extras"

echo Copying toolkit files to install dir(s)
xcopy cuda_cudart-windows-x86_64-12.5.82-archive "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5" /s /e /i /y
xcopy cuda_nvcc-windows-x86_64-12.5.82-archive "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5" /s /e /i /y
xcopy cuda_nvtx-windows-x86_64-12.5.82-archive "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5" /s /e /i /y
xcopy visual_studio_integration-windows-x86_64-12.5.82-archive "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5\extras" /s /e /i /y


# echo Installing CUDA toolkit 12
# cuda_12.5.1_windows.exe
# cuda_9.1.85_windows.exe -s nvcc_12.5 cudart_12.5


echo CUDA toolkit 12 installed

dir "%ProgramFiles%"

set PATH=%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v9.1\bin;%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v9.1\libnvvp;%PATH%
set PATH=%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5\bin;%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5\libnvvp;%PATH%

dir "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA"
dir "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5"
dir "%ProgramFiles%\NVIDIA GPU Computing Toolkit\CUDA\v12.5\bin"

nvcc -V
nvcc -V

0 comments on commit 7bbad38

Please sign in to comment.