build(cudnn-sys): Add CUDNN_INCLUDE_DIR#213
Merged
LegNeato merged 2 commits intoRust-GPU:mainfrom May 21, 2025
Merged
Conversation
Enables users to specify a non-standard cuDNN install path. This seems to be needed for the newer editions of the CUDA toolkit, as cuDNN isn't included by default (at least in the Fedora repo's, you have to install from a tarball)
LegNeato
requested changes
May 19, 2025
Contributor
LegNeato
left a comment
There was a problem hiding this comment.
Thanks for the PR and welcome to the project 🍻 !
I think it would be a bit more idiomatic like:
let mut cudnn_paths: Vec<&Path> = CUDNN_DEFAULT_PATHS.iter().map(Path::new).collect();
if let Some(override_path) = env::var_os("CUDNN_INCLUDE_DIR") {
cudnn_paths.push(Path::new(&override_path));
}
cudnn_paths
.iter()
.find(|p| Self::is_cudnn_include_path(p))
.map(|p| p.to_path_buf())
.ok_or("Cannot find cuDNN include directory.".into())
Contributor
|
Thanks again for the PR! 🥳 |
LegNeato
pushed a commit
to LegNeato/Rust-CUDA
that referenced
this pull request
Jul 12, 2025
* build(cudnn-sys): Add CUDNN_INCLUDE_DIR Enables users to specify a non-standard cuDNN install path. This seems to be needed for the newer editions of the CUDA toolkit, as cuDNN isn't included by default (at least in the Fedora repo's, you have to install from a tarball)
Contributor
|
This env var is useful for me to supply the latest v13.0 CUDA include path to enable build for cudnn-sys module. The hardcoded windows system default include path is outdated and only supports cuda v8 v9
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Enables users to specify a non-standard cuDNN install path. This seems to be needed for the newer editions of the CUDA toolkit, as cuDNN isn't included by default (at least in the Fedora repo's, you have to install from a tarball)