You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Only add typical CUDA paths to the linker search paths if no explicit path is supplied (#475)
* Only add typical locations to the linker search paths if no explicit path is supplied
* Clippy
* Apply suggestion from @coreylowman
---------
Co-authored-by: Corey Lowman <clowman1993@gmail.com>
// When building in a Conda-like environment with dynamic linking, if no
249
+
// CUDA path is supplied, then it is higly likely that, by defaulting our
250
+
// linker search paths to the typical locations below, linker errors will
251
+
// occur. Print a warning with some guidance.
252
+
#[cfg(feature = "dynamic-linking")]
253
+
if env_vars.is_empty() && std::env::var("CONDA_PREFIX").is_ok(){
254
+
println!("cargo::warning=Detected $CONDA_PREFIX, but no CUDA path was set through one of: {TYPICAL_CUDA_PATH_ENV_VARS:?}. Linking to system CUDA libraries; linker errors may occur. To use CUDA installed via conda please ensure the environment contains all required dependencies (e.g. the \"cuda-driver-dev\") and retry building with CUDA_HOME=$CONDA_PREFIX.")
0 commit comments