File tree 1 file changed +2
-11
lines changed
1 file changed +2
-11
lines changed Original file line number Diff line number Diff line change 1
1
PROJECT (libgit2-redis C)
2
2
CMAKE_MINIMUM_REQUIRED (VERSION 2.6)
3
3
4
+ INCLUDE (../CMake/FindLibgit2.cmake)
4
5
INCLUDE (../CMake/FindHiredis.cmake)
5
6
6
7
# Build options
7
8
OPTION (BUILD_SHARED_LIBS "Build Shared Library (OFF for Static)" ON )
8
9
OPTION (BUILD_TESTS "Build Tests" ON )
9
- SET (PC_LIBGIT2_LIBRARY_DIRS "" CACHE STRING "libgit2 path" )
10
- SET (PC_LIBGIT2_INCLUDE_DIRS "" CACHE STRING "libgit2 include directories" )
11
-
12
- # Allow overriding to local libgit2. I'm pretty sure I'm doing this wrong.
13
- IF (PC_LIBGIT2_INCLUDE_DIRS STREQUAL "" )
14
- INCLUDE (../CMake/FindLibgit2.cmake)
15
- ELSE ()
16
- SET (LIBGIT2_LIBRARIES ${PC_LIBGIT2_LIBRARY_DIRS} )
17
- SET (LIBGIT2_INCLUDE_DIRS ${PC_LIBGIT2_INCLUDE_DIRS} )
18
- ENDIF ()
19
10
20
11
# Build Release by default
21
12
IF (NOT CMAKE_BUILD_TYPE )
22
13
SET (CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel." FORCE)
23
14
ENDIF ()
24
15
25
16
# Compile and link libgit2
26
- INCLUDE_DIRECTORIES (${LIBGIT2_INCLUDE_DIRS } ${LIBHIREDIS_INCLUDE_DIRS } )
17
+ INCLUDE_DIRECTORIES (${LIBGIT2_INCLUDE_DIR } ${LIBHIREDIS_INCLUDE_DIR } )
27
18
28
19
IF (BUILD_SHARED_LIBS )
29
20
ADD_LIBRARY (git2-redis SHARED hiredis.c)
You can’t perform that action at this time.
0 commit comments