cmake_minimum_required(VERSION 2.8.11)

project(domod)

include (libubus)
include (libubox)
include (libubuscpp)
include (libjsoncpp)

include_directories(../../src)

set(CMAKE_CXX_FLAGS "-std=c++11 -Wall -Wextra -pedantic -Werror=strict-aliasing")

file(
	GLOB_RECURSE
	source_files
	../../src/timers/Timers.cpp
	../../src/timers/Event.cpp
	../../src/timers/Clock.cpp
	../../src/devices/Devices.cpp
	../../src/devices/Device.cpp
	../../src/devices/LightDevice.cpp
	../../src/devices/ShutterDevice.cpp
	../../src/devices/SprinklerDevice.cpp
	../../src/devices/Light.cpp
	../../src/devices/Shutter.cpp
	../../src/devices/Sprinkler.cpp
	../../src/ubus/capabilities.cpp
	../../src/ubus/capabilities_lights.cpp
	../../src/ubus/capabilities_shutters.cpp
	../../src/ubus/capabilities_sprinklers.cpp
	../../src/ubus/speach_command.cpp
	../../src/ubus/timers.cpp
	../../src/helpers/Tokenizer.cpp
	../../src/helpers/Strings.cpp
	../../src/main.cpp
)

add_executable (
        domod
        ${source_files}
)

target_link_libraries (domod 
	LINK_PUBLIC
	jsoncpp
	ubuscpp
	rt
)
