-
Notifications
You must be signed in to change notification settings - Fork 24
/
CMakeLists.txt
38 lines (29 loc) · 1.15 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
cmake_minimum_required(VERSION 3.5)
project(pvr.hdhomerun)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_SOURCE_DIR})
find_package(Kodi REQUIRED)
find_package(JsonCpp REQUIRED)
find_package(hdhomerun REQUIRED)
include_directories(${KODI_INCLUDE_DIR}/.. # Hack way with "/..", need bigger Kodi cmake rework to match right include ways
${JSONCPP_INCLUDE_DIRS}
${HDHOMERUN_INCLUDE_DIRS})
set(DEPLIBS ${JSONCPP_LIBRARIES}
${HDHOMERUN_LIBRARIES})
set(PVRHDHOMERUN_SOURCES src/HDHomeRunTuners.cpp
src/Settings.cpp
src/Utils.cpp)
set(PVRHDHOMERUN_HEADERS src/HDHomeRunTuners.h
src/Settings.h
src/Utils.h)
if(WIN32)
list(APPEND DEPLIBS ws2_32)
list(APPEND DEPLIBS iphlpapi)
add_compile_options(/wd4996)
if(CMAKE_SYSTEM_NAME STREQUAL WindowsStore)
# if _WIN32_WINNT isn't defined before including hdhomerun.h then
# it's defined as _WIN32_WINNT_VISTA which breaks build on UWP
add_definitions(-D_WIN32_WINNT=0x0A00)
endif()
endif()
build_addon(pvr.hdhomerun PVRHDHOMERUN DEPLIBS)
include(CPack)