summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorEdward Yang <ezyang@fb.com>2018-09-25 13:12:48 -0700
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>2018-09-25 13:27:54 -0700
commitceadde2a7f59b32196cf84b9242c0504ed178d4d (patch)
tree1c17f761c8cdefc1799b79e737e4d676c259be8c /tools
parentb263078bc3528c1e64a93290d2eaa473bce6ed92 (diff)
downloadpytorch-ceadde2a7f59b32196cf84b9242c0504ed178d4d.tar.gz
pytorch-ceadde2a7f59b32196cf84b9242c0504ed178d4d.tar.bz2
pytorch-ceadde2a7f59b32196cf84b9242c0504ed178d4d.zip
Add some more locations to search for nccl. (#12063)
Summary: Users generally expect ./configure to find libraries installed in /usr/local and /usr, so search for nccl there too. Signed-off-by: Edward Z. Yang <ezyang@fb.com> Pull Request resolved: https://github.com/pytorch/pytorch/pull/12063 Differential Revision: D10036248 Pulled By: ezyang fbshipit-source-id: d331ddd2ccc8ac9846fb54222db284b1ec371659
Diffstat (limited to 'tools')
-rw-r--r--tools/setup_helpers/nccl.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/setup_helpers/nccl.py b/tools/setup_helpers/nccl.py
index 7034465208..c1cc88657e 100644
--- a/tools/setup_helpers/nccl.py
+++ b/tools/setup_helpers/nccl.py
@@ -33,9 +33,11 @@ if USE_CUDA and not check_negative_env_flag('USE_SYSTEM_NCCL'):
os.path.join(ENV_ROOT, 'lib64') if ENV_ROOT is not None else None,
os.path.join(CUDA_HOME, 'lib'),
os.path.join(CUDA_HOME, 'lib64'),
+ '/usr/local/lib',
'/usr/lib/x86_64-linux-gnu/',
'/usr/lib/powerpc64le-linux-gnu/',
'/usr/lib/aarch64-linux-gnu/',
+ '/usr/lib',
] + gather_paths([
'LIBRARY_PATH',
]) + gather_paths([
@@ -45,7 +47,9 @@ if USE_CUDA and not check_negative_env_flag('USE_SYSTEM_NCCL'):
INCLUDE_DIR,
ENV_ROOT,
os.path.join(ENV_ROOT, 'include') if ENV_ROOT is not None else None,
- '/usr/include'
+ os.path.join(CUDA_HOME, 'include'),
+ '/usr/local/include',
+ '/usr/include',
]))
if IS_CONDA: