View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0016096CMakeCMakepublic2016-05-06 15:032016-06-10 14:31
ReporterRyan Desmond 
Assigned ToKitware Robot 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionmoved 
PlatformLinuxOSUbuntuOS Version14.04
Product VersionCMake 3.5.2 
Target VersionFixed in Version 
Summary0016096: FindCUDA requires dynamic runtime even if building statically
DescriptionIn https://gitlab.kitware.com/cmake/cmake/commit/7fea2b77df2d70283f4918a8ff52836dbc68db6b, [^] support was added to use the static CUDA libraries. The script still checks for and requires that the dynamic libraries are installed in order to build successfully, though they are not needed for a static build.
Steps To Reproduce - Setup a machine on which to use build CUDA, which has the static libraries available
 - Remove or delete cudart.so
 - Create a cmake script with `find_package(CUDA REQUIRED)`
 - When run, the script will fail with:

CMake Error at /usr/local/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148 (message):
  Could NOT find CUDA (missing: CUDA_CUDART_LIBRARY) (found version "7.5")
Call Stack (most recent call first):
  /usr/local/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:388 (_FPHSA_FAILURE_MESSAGE)
  /usr/local/share/cmake-3.5/Modules/FindCUDA.cmake:949 (find_package_handle_standard_args)
  imagery/CMakeLists.txt:43 (find_package)
Additional Information
The dynamic library is located at:

 725 cuda_find_library_local_first(CUDA_CUDART_LIBRARY cudart "\"cudart\" library")

The static library is located at:

 734 cuda_find_library_local_first(CUDA_cudart_static_LIBRARY cudart_static "static CUDA runtime library")

Later in the script, the variable for the dynamic library is required, even if the library itself is not required for a successful build.

 950 find_package_handle_standard_args(CUDA
 951 REQUIRED_VARS
 952 CUDA_TOOLKIT_ROOT_DIR
 953 CUDA_NVCC_EXECUTABLE
 954 CUDA_INCLUDE_DIRS
 955 CUDA_CUDART_LIBRARY
 956 VERSION_VAR
 957 CUDA_VERSION
 958 )
TagsNo tags attached.
Attached Files

 Relationships

  Notes
(0042999)
Kitware Robot (administrator)
2016-06-10 14:29

Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page.

 Issue History
Date Modified Username Field Change
2016-05-06 15:03 Ryan Desmond New Issue
2016-06-10 14:29 Kitware Robot Note Added: 0042999
2016-06-10 14:29 Kitware Robot Status new => resolved
2016-06-10 14:29 Kitware Robot Resolution open => moved
2016-06-10 14:29 Kitware Robot Assigned To => Kitware Robot
2016-06-10 14:31 Kitware Robot Status resolved => closed


Copyright © 2000 - 2018 MantisBT Team