handling possible clEnqueueFillBuffer not found in opencl lib

This commit is contained in:
Gabriele 'matrix' Gristina
2016-02-04 21:06:19 +01:00
parent 2381af313d
commit 89e5ed2574
5 changed files with 52 additions and 23 deletions
+9 -7
View File
@@ -62,13 +62,15 @@
#define HC_LOAD_FUNC(ptr,name,type,libname,noerr) \
ptr->name = (type) hc_dlsym (ptr->lib, #name); \
if (!ptr->name) { \
if (noerr == 1) { \
log_error ("ERROR: %s is missing from %s shared library.", #name, #libname); \
exit (-1); \
} else { \
log_info ("WARNING: %s is missing from %s shared library.", #name, #libname); \
return (-1); \
if (noerr != -1) { \
if (!ptr->name) { \
if (noerr == 1) { \
log_error ("ERROR: %s is missing from %s shared library.", #name, #libname); \
exit (-1); \
} else { \
log_info ("WARNING: %s is missing from %s shared library.", #name, #libname); \
return (-1); \
} \
} \
}