Open HerbertKoelman opened 6 years ago
Hello,
You can use add_subdirectory(path/to/cpp_redis/submodule)
NOTE: apparently cpp_redis's CMakeLists.txt does not set the public include paths for the library, so do it yourself:
# (use the correct paths)
add_subdirectory(3rdparty/cpp_redis)
target_include_directories(cpp_redis PUBLIC
"${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/cpp_redis/includes"
"${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/cpp_redis/tacopie/includes"
)
and then link your lib/exe with cpp_redis:
target_link_libraries(my_lib
cpp_redis
)
You could also use ExternalProject_Add.
Hello,
Is there an easy way to use cpp_redis in cmake projects ?
I want to know if there is a way to use this kind of cmake feature:
When I use this macro, cmake complains and returns this:
Any clue ?