summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaarten ter Huurne <maarten@treewalker.org>2011-12-05 05:26:28 +0100
committerMaarten ter Huurne <maarten@treewalker.org>2011-12-05 05:26:28 +0100
commitbb182d88b7f7b8f577709bd34811f474237e4355 (patch)
tree20eff26e39345840752f88e7f5054b2b59842995
parent7ebb0e526f96f4889eeb5366fad7a66110573cf3 (diff)
Link against systemwide OpenCL on OS X.
-rw-r--r--CMakeLists.txt4
-rw-r--r--Source/Core/VideoCommon/CMakeLists.txt4
2 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index dcef6157bb..1878897105 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -379,7 +379,9 @@ else()
check_lib(CGGL CgGL Cg/cgGL.h)
endif()
-if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
+if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
+ find_library(CL OpenCL)
+else()
include_directories(Externals/CLRun/include)
add_subdirectory(Externals/CLRun)
endif()
diff --git a/Source/Core/VideoCommon/CMakeLists.txt b/Source/Core/VideoCommon/CMakeLists.txt
index 481ced250a..d0e28f571c 100644
--- a/Source/Core/VideoCommon/CMakeLists.txt
+++ b/Source/Core/VideoCommon/CMakeLists.txt
@@ -40,6 +40,10 @@ set(SRCS Src/BPFunctions.cpp
Src/memcpy_amd.cpp)
set(LIBS core)
+if(NOT ${CL} STREQUAL CL-NOTFOUND)
+ list(APPEND LIBS ${CL})
+endif()
+
if(wxWidgets_FOUND AND WIN32)
set(SRCS ${SRCS} Src/EmuWindow.cpp)
endif()