Add LIBGITDEVEL support to CMakeLists.txt

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2015-02-23 09:04:52 -08:00
parent cd545e1075
commit 62999c866f

View file

@ -22,7 +22,17 @@ ENDMACRO()
pkg_config_library(LIBXML libxml-2.0)
pkg_config_library(LIBSQLITE3 sqlite3)
pkg_config_library(LIBGIT2 libgit2)
if(LIBGIT2DEVEL STREQUAL "")
pkg_config_library(LIBGIT2 libgit2)
ELSE()
include_directories(${LIBGIT2DEVEL}/include)
link_directories(${LIBGIT2DEVEL}/build)
if(LIBGIT2STATIC STREQUAL "")
set(SUBSURFACE_LINK_LIBRARIES ${SUBSURFACE_LINK_LIBRARIES} libgit2.so libssl.so libcrypto.so)
ELSE()
set(SUBSURFACE_LINK_LIBRARIES ${SUBSURFACE_LINK_LIBRARIES} libgit2.a libssl.so libcrypto.so)
ENDIF()
ENDIF()
pkg_config_library(LIBXSLT libxslt)
SET(LIBDCDEVEL "" CACHE STRING "libraries")