diff options
author | Aaron Seigo <aseigo@kde.org> | 2014-11-30 13:05:19 +0100 |
---|---|---|
committer | Aaron Seigo <aseigo@kde.org> | 2014-11-30 13:05:19 +0100 |
commit | 97b79eeb86eedee57630b8d29f6eeab08ccb02b0 (patch) | |
tree | f1944c54ac2ab4650221974e81dc14809550cc7c /CMakeLists.txt | |
parent | 0bcfc57f24adf8ce8dfb2fad33b294b5f0110a89 (diff) | |
download | sink-97b79eeb86eedee57630b8d29f6eeab08ccb02b0.tar.gz sink-97b79eeb86eedee57630b8d29f6eeab08ccb02b0.zip |
add flatbuffer support and use that for the handshake
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index e0e3796..91c4568 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -1,5 +1,6 @@ | |||
1 | cmake_minimum_required(VERSION 2.8) | 1 | cmake_minimum_required(VERSION 2.8) |
2 | 2 | ||
3 | |||
3 | # ECM setup | 4 | # ECM setup |
4 | find_package(ECM 0.0.10 REQUIRED NO_MODULE) | 5 | find_package(ECM 0.0.10 REQUIRED NO_MODULE) |
5 | set(CMAKE_MODULE_PATH | 6 | set(CMAKE_MODULE_PATH |
@@ -18,11 +19,21 @@ include(ECMPackageConfigHelpers) | |||
18 | # include(KDECMakeSettings) | 19 | # include(KDECMakeSettings) |
19 | 20 | ||
20 | find_package(Qt5Core REQUIRED) | 21 | find_package(Qt5Core REQUIRED) |
22 | find_package(FlatBuffers REQUIRED) | ||
23 | function(generate_flatbuffers dest) | ||
24 | # TODO: move the file from ${fbs}_generated.h to just ${fbs}? | ||
25 | foreach(fbs ${ARGN}) | ||
26 | execute_process(COMMAND ${FLATBUFFERS_FLATC_EXECUTABLE} -c -b --gen-includes -o ${dest} ${CMAKE_CURRENT_SOURCE_DIR}/${fbs}) | ||
27 | endforeach(fbs) | ||
28 | endfunction(generate_flatbuffers) | ||
21 | 29 | ||
22 | set(CMAKE_AUTOMOC ON) | 30 | set(CMAKE_AUTOMOC ON) |
23 | add_definitions("-Wall -std=c++0x") | 31 | add_definitions("-Wall -std=c++0x") |
24 | include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR}) | 32 | include_directories(${CMAKE_SOURCE_DIR} ${CMAKE_BINARY_DIR}) |
25 | 33 | ||
34 | # common, eventually a lib but right now just the command buffers | ||
35 | add_subdirectory(common) | ||
36 | |||
26 | # the client | 37 | # the client |
27 | add_subdirectory(client) | 38 | add_subdirectory(client) |
28 | 39 | ||