sc/workben/opencl/platform_detect.cxx |   14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

New commits:
commit 1973029229012d5761a070a741f5dd2d7d79b23f
Author: Markus Mohrhard <markus.mohrh...@googlemail.com>
Date:   Fri Oct 31 01:33:02 2014 +0100

    make that file platform independent
    
    Change-Id: I65c056faaa95af3493b73a7403f199c8c826d724

diff --git a/sc/workben/opencl/platform_detect.cxx 
b/sc/workben/opencl/platform_detect.cxx
index b0a9c61..ef45588 100644
--- a/sc/workben/opencl/platform_detect.cxx
+++ b/sc/workben/opencl/platform_detect.cxx
@@ -7,13 +7,17 @@
 
 using namespace std;
 
+#ifdef WIN32
+#define OPENCL_DLL_NAME "OpenCL.dll"
+#elif defined(MACOSX)
+#define OPENCL_DLL_NAME NULL
+#else
+#define OPENCL_DLL_NAME "libOpenCL.so"
+#endif
+
 int main()
 {
-    const char* dllname = "libOpenCL.so"; // on Linux
-//  const char* dllname = "OpenCL.dll"; // from GPU driver.
-//  const char* dllname = "amdocl.dll"; // from AMD SDK
-//  const char* dllname = "intelocl.dll"; // from Intel SDK
-    int status = clewInit(dllname);
+    int status = clewInit(OPENCL_DLL_NAME);
     if (status < 0)
     {
         cout << "failed to load" << endl;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to