File tree 4 files changed +19
-2
lines changed
4 files changed +19
-2
lines changed Original file line number Diff line number Diff line change 1
1
bench
2
2
vpack-to-json
3
3
json-to-vpack
4
+ taocpp-json
4
5
core
5
6
AsmTest
6
7
* .o
Original file line number Diff line number Diff line change @@ -61,6 +61,7 @@ matrix:
61
61
- build_type=Release
62
62
- SANITIZER=true
63
63
- CXX_STANDARD=17
64
+ - TAO=ON
64
65
65
66
- name : " coverage build"
66
67
if : branch = master
@@ -92,6 +93,7 @@ matrix:
92
93
# build settings
93
94
- build_type=Release
94
95
- CXX_STANDARD=17
96
+ - TAO=ON
95
97
addons :
96
98
apt :
97
99
sources :
@@ -105,12 +107,16 @@ matrix:
105
107
compiler : clang
106
108
env :
107
109
- build_type=Release
110
+ - TAO=ON
108
111
109
112
install :
113
+ - git clone https://github.com/taocpp/json.git taocpp-json
114
+ - ( cd taocpp-json; git checkout 631095f4bfa45c63af5ccc1cb35ea16eb9ead450; )
110
115
- export CXX=$CXX
111
116
- export CC=$CC
112
117
- export CXX_STANDARD=${CXX_STANDARD:-17}
113
118
- export BUILD_TYPE=${build_type}
119
+ - export TAO=${TAO:-OFF}
114
120
- cmake --version
115
121
- $CXX --version
116
122
Original file line number Diff line number Diff line change @@ -11,6 +11,15 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Mo
11
11
12
12
option (BuildVelocyPackExamples "Build examples" ON )
13
13
option (Maintainer "Build maintainer tools" OFF )
14
+ option (TaoJson "Add support for taocpp::json" OFF )
15
+
16
+ if (TaoJson)
17
+ if (NOT TARGET taocpp::json)
18
+ set (TAOCPP_JSON_BUILD_TESTS OFF CACHE BOOL "Build test programs" FORCE)
19
+ set (TAOCPP_JSON_BUILD_EXAMPLES OFF CACHE BOOL "Build example programs" FORCE)
20
+ add_subdirectory (taocpp-json EXCLUDE_FROM_ALL )
21
+ endif ()
22
+ endif ()
14
23
15
24
set (HashType "xxhash" CACHE STRING "Hash type (fasthash, xxhash)" )
16
25
@@ -44,7 +53,7 @@ set(VELOCY_SOURCE
44
53
src/Iterator.cpp
45
54
src/Options .cpp
46
55
src/Parser.cpp
47
- src/TaoParser.cpp
56
+ $<$< BOOL : ${TaoJson} >: src/TaoParser.cpp>
48
57
src/Serializable.cpp
49
58
src/Slice.cpp
50
59
src/SliceStaticData.cpp
@@ -80,6 +89,7 @@ message(STATUS "Building with hash type: ${HashType}")
80
89
add_library (velocypack STATIC ${VELOCY_SOURCE} )
81
90
target_include_directories (velocypack PRIVATE src)
82
91
target_include_directories (velocypack PUBLIC include )
92
+ target_link_libraries (velocypack PUBLIC $<$<BOOL :${TaoJson} >:taocpp::json>)
83
93
84
94
if (Maintainer)
85
95
add_executable (buildVersion scripts/build -version .cpp)
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ mkdir -p build && cd build || ferr "could not create build dir"
21
21
22
22
cmake -DCMAKE_BUILD_TYPE=Release -DHashType=xxhash \
23
23
-DBuildTests=ON -DBuildLargeTests=OFF -DBuildVelocyPackExamples=ON \
24
- -DBuildTools=ON -DEnableSSE=OFF \
24
+ -DBuildTools=ON -DEnableSSE=OFF -DTaoJson= " $TAO " \
25
25
-DCMAKE_CXX_STANDARD=${CXX_STANDARD} \
26
26
.. || ferr " failed to configure"
27
27
You can’t perform that action at this time.
0 commit comments