Skip to content

Commit

Permalink
Look for libraries in some more places (Fixes inducer#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
inducer committed Jan 19, 2016
1 parent 215732e commit 08e2c16
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[flake8]
ignore = E126,E127,E128,E123,E226,E241,E242
ignore = E126,E127,E128,E123,E226,E241,E242,W503
max-line-length=85
16 changes: 9 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ def get_config_schema():
else:
cuda_root_default = normpath(join(dirname(nvcc_path), ".."))

default_lib_dirs = [
"${CUDA_ROOT}/lib", "${CUDA_ROOT}/lib64",
# https://github.com/inducer/pycuda/issues/98
"${CUDA_ROOT}/lib/stubs", "${CUDA_ROOT}/lib64/stubs",
]

return ConfigSchema(make_boost_base_options() + [
Switch("USE_SHIPPED_BOOST", True, "Use included Boost library"),

Expand All @@ -52,17 +58,13 @@ def get_config_schema():
Switch("CUDA_ENABLE_GL", False, "Enable CUDA GL interoperability"),
Switch("CUDA_ENABLE_CURAND", True, "Enable CURAND library"),

LibraryDir("CUDADRV", [
"${CUDA_ROOT}/lib", "${CUDA_ROOT}/lib64",
# https://github.com/inducer/pycuda/issues/98
"${CUDA_ROOT}/lib/stubs", "${CUDA_ROOT}/lib64/stubs",
]),
LibraryDir("CUDADRV", default_lib_dirs),
Libraries("CUDADRV", ["cuda"]),

LibraryDir("CUDART", ["${CUDA_ROOT}/lib", "${CUDA_ROOT}/lib64"]),
LibraryDir("CUDART", default_lib_dirs),
Libraries("CUDART", ["cudart"]),

LibraryDir("CURAND", ["${CUDA_ROOT}/lib", "${CUDA_ROOT}/lib64"]),
LibraryDir("CURAND", default_lib_dirs),
Libraries("CURAND", ["curand"]),

StringListOption("CXXFLAGS", [],
Expand Down

0 comments on commit 08e2c16

Please sign in to comment.