Reputation: 16148
#include "somelib/some.h"
int main(){}
I have a 3rd party library that has a pretty messy structure but it uses CMake. How would I add that library to my project so that I could just use it as I have written above?
Do I have to manually build and move every file by myself or is there a shortcut?
something like
mkdir lib
mv path/somelib lib
and in my CMakeLists.txt I could just add something like
ADD_CMAKE_LIB(${CMAKE_BINARY_DIR}/lib/somelib)
And everything would magically work?
Upvotes: 2
Views: 105
Reputation: 5135
You can use one of the following options:
Personally, I prefer second approach combined with git submodule. If git is not used - I'll vote for third.
Upvotes: 2