I've been searching over the internet but I couldn't find anything that would answer my question (or I don't know what to search for).
Anyway here's my issue: I want to use 3rdParty libraries (.dll files) in my CMake project. Library (https://github.com/pitzer/SiftGPU) that I want to include is open source and is also available in binary which I would like to use and also uses CMake as build tool if that's relevant.
I hope I was clear enough.
First, edit your CMakeLists.txt to include your third party library. You'll need two thing: path to header files and library file to link to. For instance:
Next, you can do the same for other libraries and when every libraries are detected, link to the target:
Then you can configure your project with CMake, but as it doesn't have any magic way to find your installed library, it won't find anything, but it'll create two cache variables:
SIFTGPU_INCLUDE_DIR
andSIFTGPU_LIBRARY
.Use the CMake GUI to have
SIFTGPU_INCLUDE_DIR
pointing to the directory containing the header files andSIFTGPU_LIBRARY
to the.lib
file of your third party library.Repeat for every third party library, configure again and compile.