diff --git a/exp/CMakeLists.txt b/exp/CMakeLists.txt index e6360317f..be7cec3d9 100644 --- a/exp/CMakeLists.txt +++ b/exp/CMakeLists.txt @@ -30,6 +30,6 @@ target_link_libraries(${EXECUTABLE} p2p) if (ETHASHCL) target_link_libraries(${EXECUTABLE} ethash-cl) target_link_libraries(${EXECUTABLE} ethash) - target_link_libraries(${EXECUTABLE} ${OpenCL_LIBRARIES}) + target_link_libraries(${EXECUTABLE} OpenCL_ICD) endif() install( TARGETS ${EXECUTABLE} DESTINATION bin) diff --git a/khronos_icd/CMakeLists.txt b/khronos_icd/CMakeLists.txt index f746d0759..9fc7ad2cd 100644 --- a/khronos_icd/CMakeLists.txt +++ b/khronos_icd/CMakeLists.txt @@ -21,14 +21,14 @@ endif () # OR copy OpenCL headers to ./inc/CL/ include_directories (./inc) -add_library (OpenCL SHARED ${OPENCL_ICD_LOADER_SOURCES}) -set_target_properties (OpenCL PROPERTIES VERSION "1.2" SOVERSION "1") +add_library (OpenCL_ICD SHARED ${OPENCL_ICD_LOADER_SOURCES}) +set_target_properties (OpenCL_ICD PROPERTIES VERSION "1.2" SOVERSION "1") if ("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux") - set_target_properties (OpenCL PROPERTIES LINK_FLAGS "-Wl,--version-script -Wl,../../khronos_icd/icd_exports.map") + set_target_properties (OpenCL_ICD PROPERTIES LINK_FLAGS "-Wl,--version-script -Wl,../../khronos_icd/icd_exports.map") endif () -target_link_libraries (OpenCL ${CMAKE_DL_LIBS}) +target_link_libraries (OpenCL_ICD ${CMAKE_DL_LIBS}) enable_testing() add_subdirectory (test) diff --git a/libethash-cl/CMakeLists.txt b/libethash-cl/CMakeLists.txt index 9dc45fcf5..8fa7c97f3 100644 --- a/libethash-cl/CMakeLists.txt +++ b/libethash-cl/CMakeLists.txt @@ -24,7 +24,7 @@ include_directories(${Boost_INCLUDE_DIRS}) include_directories(${OpenCL_INCLUDE_DIRS}) include_directories(..) add_library(${EXECUTABLE} ${SRC_LIST} ${HEADERS}) -TARGET_LINK_LIBRARIES(${EXECUTABLE} ${OpenCL_LIBRARIES} ethash) +TARGET_LINK_LIBRARIES(${EXECUTABLE} OpenCL_ICD ethash) install( TARGETS ${EXECUTABLE} RUNTIME DESTINATION bin ARCHIVE DESTINATION lib LIBRARY DESTINATION lib ) install( FILES ${HEADERS} DESTINATION include/${EXECUTABLE} )