aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
blob: 6536a47bf37acbd97a62d81fa4101358940ca471 (plain) (blame)
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
cmake_minimum_required(VERSION 3.14.0)
project(deduper CXX)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

find_package(OpenCV REQUIRED COMPONENTS core imgproc imgcodecs highgui)
find_package(SQLite3 REQUIRED)
find_package(Threads REQUIRED)
include_directories(${OpenCV_INCLUDE_DIRS})
include_directories(${SQLite3_INCLUDE_DIRS})

INCLUDE (CheckTypeSize)

SET(CMAKE_EXTRA_INCLUDE_FILES "filesystem")
check_type_size("std::filesystem::path::value_type" PATH_VALSIZE LANGUAGE CXX)
SET(CMAKE_EXTRA_INCLUDE_FILES)

add_compile_definitions(PATH_VALSIZE=${PATH_VALSIZE})

include_directories(.)

add_library(xsig STATIC
    imageutil.cpp
    signature.cpp
    subslice_signature.cpp
    signature_db.cpp
    base64.cpp
)

target_compile_options(xsig PRIVATE -Werror=return-type)

add_subdirectory(tests)