forked from BlackIkeEagle/muttvcardsearch
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
32 lines (22 loc) · 1002 Bytes
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Project name is not mandatory, but you should use it
project(muttvcardsearch)
# States that CMake required version must be greater than 2.6
# no clue if needed, but all tutorials have something similar...
cmake_minimum_required(VERSION 2.6)
# include custom find_package scripts from cmake/Modules
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
# Include the directory itself as a path to include directories
set(CMAKE_INCLUDE_CURRENT_DIR ON)
# add source files
file(GLOB muttvcardsearch_SOURCES *.cpp)
file(GLOB vcard_SOURCES vCard/*.cpp)
# Create executable
add_executable(muttvcardsearch ${vcard_SOURCES} ${muttvcardsearch_SOURCES})
# find curl library
find_package(CURL REQUIRED)
# find sqlite3 library - not yet in cmake
find_package(Sqlite3 REQUIRED)
include_directories(${SQLITE3_INCLUDE_DIR})
# Link the executable
target_link_libraries(muttvcardsearch ${CURL_LIBRARY} ${SQLITE3_LIBRARIES})
install (TARGETS muttvcardsearch DESTINATION "/usr/bin")