Fix build under directories with '.cpp' string.

This commit is contained in:
Egor Pugin 2017-03-23 14:42:23 +03:00 committed by GitHub
parent bcac7bd6d2
commit a321cce5e4

View File

@ -9,7 +9,7 @@ if (NOT cl_list)
message(FATAL_ERROR "Can't find OpenCL kernels in directory: ${CL_DIR}")
endif()
string(REPLACE ".cpp" ".hpp" OUTPUT_HPP "${OUTPUT}")
string(REGEX REPLACE "\\.cpp$" ".hpp" OUTPUT_HPP "${OUTPUT}")
get_filename_component(OUTPUT_HPP_NAME "${OUTPUT_HPP}" NAME)
if("${MODULE_NAME}" STREQUAL "ocl")