-
Notifications
You must be signed in to change notification settings - Fork 176
/
Copy pathCMakeLists.txt
57 lines (48 loc) · 1.99 KB
/
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
cmake_minimum_required(VERSION 2.6)
project(Pastec)
include_directories(include include/orb)
set(SOURCES src/main.cpp
src/imagereranker.cpp
src/imagererankerransac.cpp
src/imageloader.cpp
src/httpserver.cpp
src/jsoncpp.cpp
src/requesthandler.cpp
src/imagedownloader.cpp
src/orb/orbfeatureextractor.cpp
src/orb/orbindex.cpp
src/orb/orbsearcher.cpp
src/orb/orbwordindex.cpp)
set(HEADERS include/thread.h
include/messages.h
include/hit.h
include/searchResult.h
include/imagereranker.h
include/backwardindexreaderaccess.h
include/imageloader.h
include/index.h
include/featureextractor.h
include/imagedownloader.h
include/json/json-forwards.h
include/json/json.h
include/orb/orbfeatureextractor.h
include/orb/orbindex.h
include/orb/orbsearcher.h
include/orb/orbwordindex.h
include/searcher.h
include/httpserver.h
include/requesthandler.h)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build, options are: Debug Release RelWithDebInfo MinSizeRel." FORCE)
endif(NOT CMAKE_BUILD_TYPE)
find_package(Threads REQUIRED)
find_package(OpenCV REQUIRED)
find_package(microhttpd REQUIRED)
find_package(CURL REQUIRED)
add_executable(pastec ${SOURCES} ${HEADERS})
target_link_libraries(pastec ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(pastec ${OpenCV_LIBS})
target_link_libraries(pastec ${LIBMICROHTTPD_LIBRARY})
target_link_libraries(pastec ${CURL_LIBRARIES})