summaryrefslogtreecommitdiff
path: root/Source/Core/Common
diff options
context:
space:
mode:
authorShawn Hoffman <godisgovernment@gmail.com>2009-10-20 02:11:50 +0000
committerShawn Hoffman <godisgovernment@gmail.com>2009-10-20 02:11:50 +0000
commitd40ce3f1e5e09e7ca94b32a16962a88a96c24576 (patch)
treeb42863394ac6b5b6a1652f3d7c05d367728e88e5 /Source/Core/Common
parent094c73a080c18f0fc5d4ed01a136e3298f9b715d (diff)
fix compiling if opencl is not enabled at compile time
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4440 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/Common')
-rw-r--r--Source/Core/Common/Src/OpenCL.cpp2
-rw-r--r--Source/Core/Common/Src/OpenCL.h4
2 files changed, 5 insertions, 1 deletions
diff --git a/Source/Core/Common/Src/OpenCL.cpp b/Source/Core/Common/Src/OpenCL.cpp
index 7ed4c39349..c3ff939ab0 100644
--- a/Source/Core/Common/Src/OpenCL.cpp
+++ b/Source/Core/Common/Src/OpenCL.cpp
@@ -130,6 +130,7 @@ void Destroy() {
#endif
}
+#if defined(HAVE_OPENCL) && HAVE_OPENCL
void HandleCLError(cl_int error, char* str)
{
char* name;
@@ -191,5 +192,6 @@ void HandleCLError(cl_int error, char* str)
PanicAlert("OpenCL error: %s %s (%d)", str, name, error);
}
+#endif
};
diff --git a/Source/Core/Common/Src/OpenCL.h b/Source/Core/Common/Src/OpenCL.h
index 6e63ccb1e6..12baade12c 100644
--- a/Source/Core/Common/Src/OpenCL.h
+++ b/Source/Core/Common/Src/OpenCL.h
@@ -60,8 +60,10 @@ void Destroy();
cl_program CompileProgram(const char *Kernel);
cl_kernel CompileKernel(cl_program program, const char *Function);
-void HandleCLError(cl_int error, char* str = 0);
+#if defined(HAVE_OPENCL) && HAVE_OPENCL
+void HandleCLError(cl_int error, char* str = 0);
+#endif
};
#endif