~unity-api-team/storage-framework/vivid

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
find_package(Qt5DBus REQUIRED)
find_package(Boost COMPONENTS thread REQUIRED)
add_definitions(-DBOOST_THREAD_VERSION=4)

qt5_add_dbus_adaptor(generated_files ${CMAKE_SOURCE_DIR}/data/provider.xml unity/storage/provider/internal/ProviderInterface.h unity::storage::provider::internal::ProviderInterface)

set_source_files_properties(bus.xml PROPERTIES CLASSNAME BusInterface)
qt5_add_dbus_interface(generated_files bus.xml businterface)

add_library(storage-framework-provider SHARED
  ProviderBase.cpp
  Server.cpp
  internal/ProviderInterface.cpp
  internal/Handler.cpp
  internal/dbusmarshal.cpp
  ${CMAKE_SOURCE_DIR}/include/unity/storage/provider/internal/ProviderInterface.h
  ${CMAKE_SOURCE_DIR}/include/unity/storage/provider/internal/Handler.h
  ${generated_files})

set_target_properties(storage-framework-provider PROPERTIES AUTOMOC TRUE)
qt5_use_modules(storage-framework-provider Core DBus)
target_link_libraries(storage-framework-provider
  Qt5::Core
  Qt5::DBus
  ${Boost_LIBRARIES}
)