lwtarantool 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/README.md +84 -0
- data/ext/lwtarantool/conn.c +314 -0
- data/ext/lwtarantool/depend +23 -0
- data/ext/lwtarantool/errors.c +24 -0
- data/ext/lwtarantool/extconf.rb +8 -0
- data/ext/lwtarantool/lwtarantool.c +12 -0
- data/ext/lwtarantool/lwtarantool.h +38 -0
- data/ext/lwtarantool/request.c +124 -0
- data/ext/lwtarantool/vendor/msgpuck/CMakeLists.txt +73 -0
- data/ext/lwtarantool/vendor/msgpuck/hints.c +674 -0
- data/ext/lwtarantool/vendor/msgpuck/msgpuck.c +375 -0
- data/ext/lwtarantool/vendor/msgpuck/msgpuck.h +2195 -0
- data/ext/lwtarantool/vendor/msgpuck/test/CMakeLists.txt +25 -0
- data/ext/lwtarantool/vendor/msgpuck/test/msgpuck.c +1126 -0
- data/ext/lwtarantool/vendor/msgpuck/test/test.c +105 -0
- data/ext/lwtarantool/vendor/msgpuck/test/test.h +123 -0
- data/ext/lwtarantool/vendor/tarantool-c/CMakeLists.txt +89 -0
- data/ext/lwtarantool/vendor/tarantool-c/cmake/FindMsgPuck.cmake +18 -0
- data/ext/lwtarantool/vendor/tarantool-c/cmake/FindSphinx.cmake +10 -0
- data/ext/lwtarantool/vendor/tarantool-c/doc/CMakeLists.txt +15 -0
- data/ext/lwtarantool/vendor/tarantool-c/doc/source/example.c +340 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/CMakeLists.txt +6 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tarantool.h +67 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_auth.h +72 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_buf.h +88 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_call.h +83 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_delete.h +52 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_execute.h +24 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_insert.h +62 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_io.h +67 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_iob.h +62 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_iter.h +301 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_mem.h +102 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_net.h +242 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_object.h +248 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_opt.h +138 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_ping.h +49 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_proto.h +295 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_reply.h +204 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_request.h +377 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_schema.h +165 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_select.h +59 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_stream.h +79 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tarantool/tnt_update.h +226 -0
- data/ext/lwtarantool/vendor/tarantool-c/include/tp.h +1998 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/CMakeLists.txt +36 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/common.c +233 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/common.h +28 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/plain_test.c +152 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tarantool_call.c +57 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tarantool_disconnect.c +31 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tarantool_tcp.c +840 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tarantool_unix.c +384 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/test.c +72 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/test.h +94 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tnt_assoc.c +6 -0
- data/ext/lwtarantool/vendor/tarantool-c/test/tnt_assoc.h +67 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/PMurHash.c +317 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/PMurHash.h +68 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/base64.c +300 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/base64.h +91 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/mhash.h +589 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/sha1.c +219 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/sha1.h +24 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/uri.c +6528 -0
- data/ext/lwtarantool/vendor/tarantool-c/third_party/uri.h +81 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/CMakeLists.txt +83 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/pmatomic.h +494 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_assoc.c +9 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_assoc.h +172 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_auth.c +118 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_buf.c +171 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_call.c +79 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_delete.c +52 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_execute.c +60 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_insert.c +60 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_io.c +520 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_iob.c +75 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_iter.c +293 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_mem.c +82 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_net.c +336 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_object.c +476 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_opt.c +117 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_ping.c +38 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_proto_internal.h +43 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_reply.c +300 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_request.c +336 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_schema.c +334 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_select.c +58 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_stream.c +71 -0
- data/ext/lwtarantool/vendor/tarantool-c/tnt/tnt_update.c +247 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/CMakeLists.txt +69 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_dir.c +173 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_dir.h +58 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_log.c +329 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_log.h +119 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_rpl.c +189 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_rpl.h +47 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_snapshot.c +163 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_snapshot.h +50 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_xlog.c +163 -0
- data/ext/lwtarantool/vendor/tarantool-c/tntrpl/tnt_xlog.h +50 -0
- data/lib/lwtarantool/connection.rb +84 -0
- data/lib/lwtarantool/request.rb +58 -0
- data/lib/lwtarantool.rb +23 -0
- metadata +164 -0
@@ -0,0 +1,73 @@
|
|
1
|
+
project(msgpuck)
|
2
|
+
cmake_minimum_required(VERSION 2.8.5)
|
3
|
+
|
4
|
+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99 -fPIC -fstrict-aliasing")
|
5
|
+
set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wall -Wextra -Werror")
|
6
|
+
|
7
|
+
if(NOT CMAKE_BUILD_TYPE)
|
8
|
+
set(CMAKE_BUILD_TYPE Debug CACHE STRING
|
9
|
+
"Build type, options are: Debug Release." FORCE)
|
10
|
+
endif()
|
11
|
+
|
12
|
+
include(CheckCCompilerFlag)
|
13
|
+
check_c_compiler_flag("-mno-unaligned-access" CC_HAS_MNO_UNALIGNED_ACCESS)
|
14
|
+
|
15
|
+
add_library(msgpuck STATIC msgpuck.c hints.c)
|
16
|
+
set_target_properties(msgpuck PROPERTIES VERSION 1.0 SOVERSION 1)
|
17
|
+
set_target_properties(msgpuck PROPERTIES OUTPUT_NAME "msgpuck")
|
18
|
+
|
19
|
+
if (NOT ${PROJECT_SOURCE_DIR} STREQUAL ${CMAKE_SOURCE_DIR})
|
20
|
+
# Embedded mode, skip tests, documentation and the install targets
|
21
|
+
return()
|
22
|
+
endif()
|
23
|
+
|
24
|
+
option(ENABLE_GCOV "Enable integration with gcov, a code coverage program" OFF)
|
25
|
+
if (ENABLE_GCOV)
|
26
|
+
set(_flags "-fprofile-arcs -ftest-coverage")
|
27
|
+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${_flags}")
|
28
|
+
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${_flags}")
|
29
|
+
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${_flags}")
|
30
|
+
endif()
|
31
|
+
|
32
|
+
add_subdirectory(test)
|
33
|
+
|
34
|
+
include(GNUInstallDirs)
|
35
|
+
install(TARGETS msgpuck
|
36
|
+
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
37
|
+
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
38
|
+
COMPONENT library)
|
39
|
+
install(FILES msgpuck.h DESTINATION include)
|
40
|
+
|
41
|
+
find_package(Doxygen)
|
42
|
+
if(NOT DOXYGEN_FOUND)
|
43
|
+
return()
|
44
|
+
endif()
|
45
|
+
|
46
|
+
set(GENERATE_HTML "NO")
|
47
|
+
set(GENERATE_MAN "YES")
|
48
|
+
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
|
49
|
+
"${CMAKE_CURRENT_BINARY_DIR}/Doxyfile.man")
|
50
|
+
add_custom_command(OUTPUT doc/man/man3/msgpuck.h.3
|
51
|
+
COMMAND ${CMAKE_COMMAND} -E make_directory doc/man
|
52
|
+
COMMAND ${DOXYGEN_EXECUTABLE} "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile.man"
|
53
|
+
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
|
54
|
+
DEPENDS msgpuck.h
|
55
|
+
COMMENT "Generating man pages" VERBATIM)
|
56
|
+
add_custom_target(man DEPENDS doc/man/man3/msgpuck.h.3)
|
57
|
+
|
58
|
+
set(GENERATE_HTML "YES")
|
59
|
+
set(GENERATE_MAN "NO")
|
60
|
+
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in"
|
61
|
+
"${CMAKE_CURRENT_BINARY_DIR}/Doxyfile.html")
|
62
|
+
add_custom_command(OUTPUT doc/html/index.html
|
63
|
+
COMMAND ${CMAKE_COMMAND} -E make_directory doc/html
|
64
|
+
COMMAND ${DOXYGEN_EXECUTABLE} "${CMAKE_CURRENT_BINARY_DIR}/Doxyfile.html"
|
65
|
+
COMMAND ${CMAKE_COMMAND} -E rename doc/html/msgpuck_8h.html
|
66
|
+
doc/html/index.html
|
67
|
+
COMMAND sed s/msgpuck_8h\\.html/index\\.html/ -i doc/html/index.html
|
68
|
+
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
|
69
|
+
DEPENDS msgpuck.h
|
70
|
+
COMMENT "Generating html documentation" VERBATIM)
|
71
|
+
add_custom_target(html DEPENDS doc/html/index.html)
|
72
|
+
|
73
|
+
add_custom_target(doc DEPENDS man html)
|