dwaaan / pyrit

Automatically exported from code.google.com/p/pyrit
0 stars 0 forks source link

error for cpyrit-opencl-0.4.0 #289

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
i got this error when trying to build cpyrit-opencl-0.4.0 on my notebook:

root@bt:/opt/cpyrit-opencl-0.4.0# python setup.py build
The headers required to build the OpenCL-kernel were not found. Trying to 
continue anyway...
svn: '.' is not a working copy
running build
running build_ext
Building modules...
building 'cpyrit._cpyrit_opencl' extension
creating build
creating build/temp.linux-i686-2.5
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fPIC -I/usr/include/python2.5 -c _cpyrit_opencl.c -o 
build/temp.linux-i686-2.5/_cpyrit_opencl.o -Wall -fno-strict-aliasing 
-DVERSION="0.4.0"
_cpyrit_opencl.c:45:23: error: CL/cl.h: No such file or directory
_cpyrit_opencl.c:69: error: expected specifier-qualifier-list before 
'cl_device_id'
_cpyrit_opencl.c:80: error: expected '=', ',', ';', 'asm' or '__attribute__' 
before '*' token
_cpyrit_opencl.c:81: error: expected '=', ',', ';', 'asm' or '__attribute__' 
before 'num_platforms'
_cpyrit_opencl.c:86: error: expected ')' before 'error'
_cpyrit_opencl.c: In function 'oclplatf_init':
_cpyrit_opencl.c:145: error: 'cl_uint' undeclared (first use in this function)
_cpyrit_opencl.c:145: error: (Each undeclared identifier is reported only once
_cpyrit_opencl.c:145: error: for each function it appears in.)
_cpyrit_opencl.c:145: error: expected ';' before 'num_devices'
_cpyrit_opencl.c:146: error: 'cl_int' undeclared (first use in this function)
_cpyrit_opencl.c:146: error: expected ';' before 'err'
_cpyrit_opencl.c:153: error: 'num_platforms' undeclared (first use in this 
function)
_cpyrit_opencl.c:163: error: 'err' undeclared (first use in this function)
_cpyrit_opencl.c:163: warning: implicit declaration of function 'clGetDeviceIDs'
_cpyrit_opencl.c:163: error: 'platforms' undeclared (first use in this function)
_cpyrit_opencl.c:163: error: 'CL_DEVICE_TYPE_ALL' undeclared (first use in this 
function)
_cpyrit_opencl.c:163: error: 'num_devices' undeclared (first use in this 
function)
_cpyrit_opencl.c:164: error: 'CL_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:166: warning: implicit declaration of function 'getCLresultMsg'
_cpyrit_opencl.c:166: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:177: warning: implicit declaration of function 
'clGetPlatformInfo'
_cpyrit_opencl.c:177: error: 'CL_PLATFORM_NAME' undeclared (first use in this 
function)
_cpyrit_opencl.c:180: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:190: error: 'CL_PLATFORM_VENDOR' undeclared (first use in this 
function)
_cpyrit_opencl.c:193: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c: In function 'ocldevice_init':
_cpyrit_opencl.c:219: error: 'cl_uint' undeclared (first use in this function)
_cpyrit_opencl.c:219: error: expected ';' before 'num_entries'
_cpyrit_opencl.c:220: error: 'cl_device_id' undeclared (first use in this 
function)
_cpyrit_opencl.c:220: error: 'devices' undeclared (first use in this function)
_cpyrit_opencl.c:221: error: 'cl_device_type' undeclared (first use in this 
function)
_cpyrit_opencl.c:221: error: expected ';' before 'device_type'
_cpyrit_opencl.c:225: error: 'cl_int' undeclared (first use in this function)
_cpyrit_opencl.c:225: error: expected ';' before 'err'
_cpyrit_opencl.c:230: error: 'num_platforms' undeclared (first use in this 
function)
_cpyrit_opencl.c:236: error: 'err' undeclared (first use in this function)
_cpyrit_opencl.c:236: error: 'platforms' undeclared (first use in this function)
_cpyrit_opencl.c:236: error: 'CL_DEVICE_TYPE_ALL' undeclared (first use in this 
function)
_cpyrit_opencl.c:236: error: 'num_entries' undeclared (first use in this 
function)
_cpyrit_opencl.c:237: error: 'CL_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:239: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:248: error: expected expression before ')' token
_cpyrit_opencl.c:257: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:261: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:264: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:264: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:264: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:265: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:266: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:267: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:268: error: 'OpenCLDevice' has no member named 'dev_queue'
_cpyrit_opencl.c:270: warning: implicit declaration of function 
'clGetDeviceInfo'
_cpyrit_opencl.c:270: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:270: error: 'CL_DEVICE_NAME' undeclared (first use in this 
function)
_cpyrit_opencl.c:273: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:276: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:277: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:283: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:283: error: 'CL_DEVICE_TYPE' undeclared (first use in this 
function)
_cpyrit_opencl.c:283: error: 'device_type' undeclared (first use in this 
function)
_cpyrit_opencl.c:286: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:289: error: 'CL_DEVICE_TYPE_CPU' undeclared (first use in this 
function)
_cpyrit_opencl.c:291: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:292: error: 'CL_DEVICE_TYPE_GPU' undeclared (first use in this 
function)
_cpyrit_opencl.c:294: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:295: error: 'CL_DEVICE_TYPE_ACCELERATOR' undeclared (first use 
in this function)
_cpyrit_opencl.c:297: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:300: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:302: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:308: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:308: error: 'CL_DEVICE_MAX_WORK_GROUP_SIZE' undeclared (first 
use in this function)
_cpyrit_opencl.c:308: error: 'OpenCLDevice' has no member named 
'dev_workgroupsize'
_cpyrit_opencl.c:308: error: 'OpenCLDevice' has no member named 
'dev_workgroupsize'
_cpyrit_opencl.c:311: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:315: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:315: error: 'CL_DEVICE_MAX_WORK_ITEM_DIMENSIONS' undeclared 
(first use in this function)
_cpyrit_opencl.c:318: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:328: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:328: error: 'CL_DEVICE_MAX_WORK_ITEM_SIZES' undeclared (first 
use in this function)
_cpyrit_opencl.c:332: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:335: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:336: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:343: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c: In function 'ocldevice_compile':
_cpyrit_opencl.c:353: error: 'cl_int' undeclared (first use in this function)
_cpyrit_opencl.c:353: error: expected ';' before 'err'
_cpyrit_opencl.c:355: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:357: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:357: warning: implicit declaration of function 
'clCreateContext'
_cpyrit_opencl.c:357: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:357: error: 'err' undeclared (first use in this function)
_cpyrit_opencl.c:358: error: 'CL_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:360: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:365: error: 'OpenCLDevice' has no member named 'dev_queue'
_cpyrit_opencl.c:367: error: 'OpenCLDevice' has no member named 'dev_queue'
_cpyrit_opencl.c:367: warning: implicit declaration of function 
'clCreateCommandQueue'
_cpyrit_opencl.c:367: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:367: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:370: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:375: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:377: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:377: warning: implicit declaration of function 
'clCreateProgramWithSource'
_cpyrit_opencl.c:377: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:380: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:385: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:387: warning: implicit declaration of function 'clBuildProgram'
_cpyrit_opencl.c:387: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:390: warning: implicit declaration of function 
'clGetProgramBuildInfo'
_cpyrit_opencl.c:390: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:390: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:390: error: 'CL_PROGRAM_BUILD_LOG' undeclared (first use in 
this function)
_cpyrit_opencl.c:391: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:395: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:395: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:395: error: 'CL_PROGRAM_BUILD_STATUS' undeclared (first use in 
this function)
_cpyrit_opencl.c:395: error: 'status' undeclared (first use in this function)
_cpyrit_opencl.c:396: error: 'CL_BUILD_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:398: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:398: error: 'OpenCLDevice' has no member named 'device'
_cpyrit_opencl.c:399: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:403: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:403: warning: implicit declaration of function 'clCreateKernel'
_cpyrit_opencl.c:403: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:406: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c: In function 'ocldevice_dealloc':
_cpyrit_opencl.c:418: error: 'OpenCLDevice' has no member named 'dev_queue'
_cpyrit_opencl.c:419: warning: implicit declaration of function 
'clReleaseCommandQueue'
_cpyrit_opencl.c:419: error: 'OpenCLDevice' has no member named 'dev_queue'
_cpyrit_opencl.c:420: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:421: warning: implicit declaration of function 
'clReleaseKernel'
_cpyrit_opencl.c:421: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:422: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:423: warning: implicit declaration of function 
'clReleaseProgram'
_cpyrit_opencl.c:423: error: 'OpenCLDevice' has no member named 'dev_prog'
_cpyrit_opencl.c:424: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:425: warning: implicit declaration of function 
'clReleaseContext'
_cpyrit_opencl.c:425: error: 'OpenCLDevice' has no member named 'dev_ctx'
_cpyrit_opencl.c:426: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:426: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:426: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:426: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:427: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:427: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:427: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:427: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:428: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:428: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:428: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c:428: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c: At top level:
_cpyrit_opencl.c:433: error: expected '=', ',', ';', 'asm' or '__attribute__' 
before 'calc_pmklist'
_cpyrit_opencl.c: In function 'cpyrit_solve':
_cpyrit_opencl.c:517: error: 'OpenCLDevice' has no member named 'dev_kernel'
_cpyrit_opencl.c:612: warning: implicit declaration of function 'calc_pmklist'
_cpyrit_opencl.c:616: error: 'CL_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:619: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c: At top level:
_cpyrit_opencl.c:693: error: 'OpenCLDevice' has no member named 'dev_name'
_cpyrit_opencl.c:694: error: 'OpenCLDevice' has no member named 'dev_type'
_cpyrit_opencl.c:695: error: 'OpenCLDevice' has no member named 
'dev_maxworksize'
_cpyrit_opencl.c: In function 'init_cpyrit_opencl':
_cpyrit_opencl.c:760: error: 'cl_int' undeclared (first use in this function)
_cpyrit_opencl.c:760: warning: statement with no effect
_cpyrit_opencl.c:760: error: expected ';' before 'err'
_cpyrit_opencl.c:762: error: 'err' undeclared (first use in this function)
_cpyrit_opencl.c:762: warning: implicit declaration of function 
'clGetPlatformIDs'
_cpyrit_opencl.c:762: error: 'num_platforms' undeclared (first use in this 
function)
_cpyrit_opencl.c:762: warning: statement with no effect
_cpyrit_opencl.c:763: error: 'CL_SUCCESS' undeclared (first use in this 
function)
_cpyrit_opencl.c:765: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
_cpyrit_opencl.c:769: error: 'platforms' undeclared (first use in this function)
_cpyrit_opencl.c:769: error: 'cl_platform_id' undeclared (first use in this 
function)
_cpyrit_opencl.c:769: error: invalid operands to binary / (have 'int' and 
'struct PyMemberDef *')
_cpyrit_opencl.c:769: error: expected expression before ')' token
_cpyrit_opencl.c:769: error: invalid operands to binary * (have 'struct 
PyMemberDef *' and 'struct PyMemberDef *')
_cpyrit_opencl.c:769: warning: statement with no effect
_cpyrit_opencl.c:776: warning: statement with no effect
_cpyrit_opencl.c:779: warning: format '%s' expects type 'char *', but argument 
3 has type 'int'
error: command 'gcc' failed with exit status 1

pls help me to get the answer on the error

tks

Original issue reported on code.google.com by luckyary...@gmail.com on 30 Mar 2011 at 10:19

GoogleCodeExporter commented 8 years ago
As it says:

"The headers required to build the OpenCL-kernel were not found. Trying to 
continue anyway..."

and later:

"_cpyrit_opencl.c:45:23: error: CL/cl.h: No such file or directory"

You need to install the OpenCL-Toolkit e.g. from 
http://developer.nvidia.com/object/opencl-download.html

Original comment by lukas.l...@gmail.com on 5 Apr 2011 at 7:51

GoogleCodeExporter commented 8 years ago
tks

Original comment by luckyary...@gmail.com on 6 Apr 2011 at 12:53