0

I have some problems with configuring my environment for a Xilinx tool. I have a CMakeLists.txt, which is needed to build host code for OpenCL. There I try to find Xilinx tool (SDAccel) and it's version of OpenCL. However I have my own version of OpenCL installed. I need only Xilinx one, how can I exclude my own version? Or it is not necessary and Xilinx version will be used, if it is found? I don't understand the meaning of may be hidden - is it actually hidden or not?

-- Configuring done
CMake Warning at CMakeLists.txt:19 (add_executable):
Cannot generate a safe linker search path for target time because files in
some directories may conflict with libraries in implicit directories:

link library [libOpenCL.so] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
  /opt/Xilinx/SDx/2017.2/runtime/lib/x86_64

 Some of these libraries may not be found correctly.
Skotti Bendler
  • 753
  • 1
  • 6
  • 17
  • Different toolset, but the same answer: Use [`CMAKE_IGNORE_PATH`](https://cmake.org/cmake/help/latest/variable/CMAKE_IGNORE_PATH.html) to exclude toolchains you don't want CMake to find. – Florian Jun 21 '18 at 19:46
  • @Florian, I don't need to exclude this path /usr/lib/x86_64-linux-gnu, as there are other libraries which I need. I need to only exclude one library. – Skotti Bendler Jun 22 '18 at 06:09
  • Set `CMAKE_LIBRARY_PATH` CMake variable to the `/opt/Xilinx/SDx/2017.2/runtime/lib/x86_64`, so this path will be searched by CMake before others. (However, this is implies search order for all other libraries, so if `Xilinx` have some library, but you want to use another one, this would fail). Alternatively, you may set `OCL_ROOT` **environment variable** to the `/opt/Xilinx/SDx/2017.2/runtime/`, this would affect only on OpenCL searching. – Tsyvarev Jun 22 '18 at 16:37

0 Answers0