Lines 115-128
Link Here
|
115 |
file, pathname, descr = find_module("pycuda") |
115 |
file, pathname, descr = find_module("pycuda") |
116 |
from os.path import join, exists |
116 |
from os.path import join, exists |
117 |
installed_path = join(pathname, "..", "include", "cuda") |
117 |
installed_path = join(pathname, "..", "include", "pycuda") |
118 |
development_path = join(pathname, "..", "src", "cuda") |
118 |
development_path = join(pathname, "..", "src", "cuda") |
|
|
119 |
usr_path = "/usr/include/pycuda" |
120 |
usr_local_path = "/usr/local/include/pycuda" |
121 |
|
122 |
import sys |
123 |
|
119 |
if exists(installed_path): |
124 |
if exists(installed_path): |
120 |
return installed_path |
125 |
return installed_path |
121 |
elif exists(development_path): |
126 |
elif exists(development_path): |
122 |
return development_path |
127 |
return development_path |
123 |
else: |
128 |
else: |
|
|
129 |
if sys.platform == "linux2": |
130 |
if exists(usr_path): |
131 |
return usr_path |
132 |
elif exists(usr_local_path): |
133 |
return usr_local_path |
134 |
|
124 |
raise RuntimeError("could not find path PyCUDA's C header files") |
135 |
raise RuntimeError("could not find path PyCUDA's C header files") |