python3Packages.orjson: Disable failing tests on 32 bit
[NixPkgs.git] / pkgs / development / libraries / opencl-clang / opencl-headers-dir.patch
blob70343b8ee19717018e33ed21ed33adb5b5210d6f
1 diff --git a/cl_headers/CMakeLists.txt b/cl_headers/CMakeLists.txt
2 index 3dd2ea4..aeae6e9 100644
3 --- a/cl_headers/CMakeLists.txt
4 +++ b/cl_headers/CMakeLists.txt
5 @@ -11,12 +11,14 @@ add_custom_command(
7 endfunction(copy_file)
9 -if(USE_PREBUILT_LLVM)
10 - set(OPENCL_HEADERS_DIR
11 - "${LLVM_LIBRARY_DIRS}/clang/${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}/include/")
12 -else(USE_PREBUILT_LLVM)
13 - set(OPENCL_HEADERS_DIR "${CLANG_SOURCE_DIR}/lib/Headers")
14 -endif(USE_PREBUILT_LLVM)
15 +if(NOT DEFINED OPENCL_HEADERS_DIR)
16 + if(USE_PREBUILT_LLVM)
17 + set(OPENCL_HEADERS_DIR
18 + "${LLVM_LIBRARY_DIRS}/clang/${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}/include/")
19 + else(USE_PREBUILT_LLVM)
20 + set(OPENCL_HEADERS_DIR "${CLANG_SOURCE_DIR}/lib/Headers")
21 + endif(USE_PREBUILT_LLVM)
22 +endif()
23 copy_file(${OPENCL_HEADERS_DIR}/opencl-c.h opencl-c.h)
25 add_custom_target (