[PyOpenCL] easy_install pyopencl -- Can't find include files.

Neal Becker ndbecker2 at gmail.com
Wed Jun 15 17:28:01 PDT 2011


Andreas Kloeckner wrote:

> On Wed, 15 Jun 2011 08:54:22 -0600, Amy Frederico
> <afrederico at gmail.com> wrote:
>> Hi, Andreas!  Thanks for the reply.  It didn't seem to work but maybe
>> I'm doing something wrong.  Here's all the info I have:
>> 
>> So I created the file in my home dir and here it is:
>> 
>> [amy at amy ~]$ cat .aksetup-defaults.py
>> CL_INC_DIR=["/usr/local/cuda/include"]
>> CL_LIB_DIR=["/usr/local/cuda/lib"]
>> [amy at amy ~]$
>> 
>> Then I try easy_install again:
>> 
>> [amy at amy ~]$ sudo easy_install pyopencl
>> install_dir /usr/lib/python2.7/site-packages/
>> Searching for pyopencl
>> Reading http://pypi.python.org/simple/pyopencl/
>> Reading http://mathema.tician.de/software/pyopencl
>> Best match: pyopencl 2011.1beta3
>> Downloading
>> 
http://pypi.python.org/packages/source/p/pyopencl/pyopencl-2011.1beta3.tar.gz#md5=efc633bb5e7a03207fa657a61a12c7af
>> Processing pyopencl-2011.1beta3.tar.gz Running pyopencl-2011.1beta3/setup.py
>> -q bdist_egg --dist-dir
>> /tmp/easy_install-dz8zSW/pyopencl-2011.1beta3/egg-dist-tmp-CXyPFK In file
>> included from src/wrapper/wrap_cl.cpp:1:0: src/wrapper/wrap_cl.hpp:20:19:
>> fatal error: CL/cl.h: No such file or directory compilation terminated.
>> error: Setup script exited with error: command 'gcc' failed with exit status
>> 1
> 
> Can you also post the gcc compiler command line (I assume you clipped
> that from the output)?
> 
> Andreas

If you're doing sudo, then it's root's .aksetup-defaults.py that you'll have to 
edit.

I recommend
d/l the source
python setup.py build (this will use your .aksetup-defaults.py)
python setup.py bdist_egg
sudo python setup.py install

worked for me on fedora f15




More information about the PyOpenCL mailing list