leezu commented on a change in pull request #17297: Fix NCCL Cmake autodetect 
issue
URL: https://github.com/apache/incubator-mxnet/pull/17297#discussion_r369298016
 
 

 ##########
 File path: cmake/Modules/FindNCCL.cmake
 ##########
 @@ -31,7 +31,13 @@
 # install NCCL in the same location as the CUDA toolkit.
 # See https://github.com/caffe2/caffe2/issues/1601
 
-set(NCCL_ROOT_DIR "" CACHE PATH "Folder contains NVIDIA NCCL")
+set(NCCL_ROOT $ENV{NCCL_ROOT} CACHE PATH "Folder contains NVIDIA NCCL")
 
 Review comment:
   > You can also set(ENV{variable_name} value) and get $ENV{variable_name} 
environment variables, though it is generally a very good idea to avoid them.
   
   https://cliutils.gitlab.io/modern-cmake/chapters/basics/variables.html
   
   Should the env variable checks here be removed? You could just delete these 
3 lines.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to