From 53795c74aead4e6021bc788b788f8ed5b4a0166d Mon Sep 17 00:00:00 2001 From: Andrej Rode Date: Mon, 3 Apr 2017 18:49:58 -0700 Subject: uhd: add cut-down rpclib source tree and import tool --- ...ace-fmt-with-boost-format-but-leave-it-in.patch | 155 + ...-rpclib-use-the-real-boost-asio-namespace.patch | 229 + ...boost-system-error_code-and-include-rpc-c.patch | 104 + host/lib/deps/CMakeLists.txt | 18 + host/lib/deps/import_rpclib.py | 156 + host/lib/deps/rpc_CMakeLists.txt | 32 + host/lib/deps/rpclib/CHANGELOG.md | 40 + host/lib/deps/rpclib/CMakeLists.txt | 32 + host/lib/deps/rpclib/LICENSE.md | 46 + host/lib/deps/rpclib/README.md | 97 + host/lib/deps/rpclib/include/rpc/client.h | 141 + host/lib/deps/rpclib/include/rpc/client.inl | 65 + host/lib/deps/rpclib/include/rpc/compatibility.h | 20 + host/lib/deps/rpclib/include/rpc/config.h | 34 + host/lib/deps/rpclib/include/rpc/config.h.in | 33 + host/lib/deps/rpclib/include/rpc/detail/all.h | 26 + host/lib/deps/rpclib/include/rpc/detail/any.h | 21 + .../deps/rpclib/include/rpc/detail/async_writer.h | 86 + host/lib/deps/rpclib/include/rpc/detail/bool.h | 21 + host/lib/deps/rpclib/include/rpc/detail/call.h | 92 + .../deps/rpclib/include/rpc/detail/client_error.h | 39 + host/lib/deps/rpclib/include/rpc/detail/constant.h | 17 + .../lib/deps/rpclib/include/rpc/detail/dev_utils.h | 21 + .../deps/rpclib/include/rpc/detail/func_tools.h | 26 + .../deps/rpclib/include/rpc/detail/func_traits.h | 77 + host/lib/deps/rpclib/include/rpc/detail/if.h | 16 + host/lib/deps/rpclib/include/rpc/detail/invoke.h | 15 + .../include/rpc/detail/is_specialization_of.h | 20 + host/lib/deps/rpclib/include/rpc/detail/log.h | 159 + .../deps/rpclib/include/rpc/detail/make_unique.h | 31 + host/lib/deps/rpclib/include/rpc/detail/not.h | 17 + host/lib/deps/rpclib/include/rpc/detail/pimpl.h | 10 + host/lib/deps/rpclib/include/rpc/detail/response.h | 119 + .../rpclib/include/rpc/detail/server_session.h | 48 + .../deps/rpclib/include/rpc/detail/thread_group.h | 40 + host/lib/deps/rpclib/include/rpc/detail/util.h | 19 + host/lib/deps/rpclib/include/rpc/dispatcher.h | 122 + host/lib/deps/rpclib/include/rpc/dispatcher.inl | 74 + host/lib/deps/rpclib/include/rpc/msgpack.hpp | 31 + .../include/rpc/msgpack/adaptor/adaptor_base.hpp | 92 + .../include/rpc/msgpack/adaptor/array_ref.hpp | 182 + .../rpclib/include/rpc/msgpack/adaptor/bool.hpp | 74 + .../include/rpc/msgpack/adaptor/boost/fusion.hpp | 168 + .../rpc/msgpack/adaptor/boost/msgpack_variant.hpp | 438 + .../include/rpc/msgpack/adaptor/boost/optional.hpp | 104 + .../rpc/msgpack/adaptor/boost/string_ref.hpp | 95 + .../include/rpc/msgpack/adaptor/char_ptr.hpp | 165 + .../rpc/msgpack/adaptor/check_container_size.hpp | 75 + .../include/rpc/msgpack/adaptor/cpp11/array.hpp | 146 + .../rpc/msgpack/adaptor/cpp11/array_char.hpp | 97 + .../msgpack/adaptor/cpp11/array_unsigned_char.hpp | 97 + .../rpc/msgpack/adaptor/cpp11/forward_list.hpp | 102 + .../rpc/msgpack/adaptor/cpp11/shared_ptr.hpp | 90 + .../include/rpc/msgpack/adaptor/cpp11/tuple.hpp | 184 + .../rpc/msgpack/adaptor/cpp11/unique_ptr.hpp | 90 + .../rpc/msgpack/adaptor/cpp11/unordered_map.hpp | 190 + .../rpc/msgpack/adaptor/cpp11/unordered_set.hpp | 180 + .../rpclib/include/rpc/msgpack/adaptor/define.hpp | 39 + .../rpclib/include/rpc/msgpack/adaptor/deque.hpp | 116 + .../msgpack/adaptor/detail/cpp03_define_array.hpp | 3498 +++++ .../msgpack/adaptor/detail/cpp03_define_map.hpp | 2799 ++++ .../msgpack/adaptor/detail/cpp03_msgpack_tuple.hpp | 13917 +++++++++++++++++++ .../msgpack/adaptor/detail/cpp11_define_array.hpp | 201 + .../msgpack/adaptor/detail/cpp11_define_map.hpp | 171 + .../msgpack/adaptor/detail/cpp11_msgpack_tuple.hpp | 283 + .../rpclib/include/rpc/msgpack/adaptor/ext.hpp | 245 + .../rpclib/include/rpc/msgpack/adaptor/fixint.hpp | 306 + .../rpclib/include/rpc/msgpack/adaptor/float.hpp | 131 + .../rpclib/include/rpc/msgpack/adaptor/int.hpp | 436 + .../rpclib/include/rpc/msgpack/adaptor/list.hpp | 114 + .../rpclib/include/rpc/msgpack/adaptor/map.hpp | 314 + .../include/rpc/msgpack/adaptor/msgpack_tuple.hpp | 29 + .../rpclib/include/rpc/msgpack/adaptor/nil.hpp | 92 + .../rpclib/include/rpc/msgpack/adaptor/pair.hpp | 91 + .../rpclib/include/rpc/msgpack/adaptor/raw.hpp | 114 + .../rpclib/include/rpc/msgpack/adaptor/set.hpp | 196 + .../rpclib/include/rpc/msgpack/adaptor/string.hpp | 94 + .../rpc/msgpack/adaptor/tr1/unordered_map.hpp | 179 + .../rpc/msgpack/adaptor/tr1/unordered_set.hpp | 173 + .../rpclib/include/rpc/msgpack/adaptor/v4raw.hpp | 114 + .../rpclib/include/rpc/msgpack/adaptor/vector.hpp | 129 + .../include/rpc/msgpack/adaptor/vector_bool.hpp | 96 + .../include/rpc/msgpack/adaptor/vector_char.hpp | 97 + .../rpc/msgpack/adaptor/vector_unsigned_char.hpp | 97 + .../deps/rpclib/include/rpc/msgpack/cpp_config.hpp | 135 + .../include/rpc/msgpack/detail/cpp03_zone.hpp | 676 + .../include/rpc/msgpack/detail/cpp11_zone.hpp | 376 + host/lib/deps/rpclib/include/rpc/msgpack/fbuffer.h | 46 + .../deps/rpclib/include/rpc/msgpack/fbuffer.hpp | 68 + .../deps/rpclib/include/rpc/msgpack/gcc_atomic.h | 33 + .../deps/rpclib/include/rpc/msgpack/iterator.hpp | 46 + host/lib/deps/rpclib/include/rpc/msgpack/meta.hpp | 59 + host/lib/deps/rpclib/include/rpc/msgpack/object.h | 119 + .../lib/deps/rpclib/include/rpc/msgpack/object.hpp | 837 ++ .../deps/rpclib/include/rpc/msgpack/object_fwd.hpp | 203 + host/lib/deps/rpclib/include/rpc/msgpack/pack.h | 155 + host/lib/deps/rpclib/include/rpc/msgpack/pack.hpp | 1098 ++ .../deps/rpclib/include/rpc/msgpack/pack_define.h | 26 + .../rpclib/include/rpc/msgpack/pack_template.h | 917 ++ host/lib/deps/rpclib/include/rpc/msgpack/predef.h | 19 + .../include/rpc/msgpack/predef/architecture.h | 30 + .../rpc/msgpack/predef/architecture/alpha.h | 60 + .../include/rpc/msgpack/predef/architecture/arm.h | 71 + .../rpc/msgpack/predef/architecture/blackfin.h | 47 + .../rpc/msgpack/predef/architecture/convex.h | 67 + .../include/rpc/msgpack/predef/architecture/ia64.h | 49 + .../include/rpc/msgpack/predef/architecture/m68k.h | 83 + .../include/rpc/msgpack/predef/architecture/mips.h | 74 + .../rpc/msgpack/predef/architecture/parisc.h | 65 + .../include/rpc/msgpack/predef/architecture/ppc.h | 73 + .../rpc/msgpack/predef/architecture/pyramid.h | 43 + .../include/rpc/msgpack/predef/architecture/rs6k.h | 56 + .../rpc/msgpack/predef/architecture/sparc.h | 55 + .../rpc/msgpack/predef/architecture/superh.h | 68 + .../rpc/msgpack/predef/architecture/sys370.h | 44 + .../rpc/msgpack/predef/architecture/sys390.h | 44 + .../include/rpc/msgpack/predef/architecture/x86.h | 38 + .../rpc/msgpack/predef/architecture/x86/32.h | 87 + .../rpc/msgpack/predef/architecture/x86/64.h | 50 + .../include/rpc/msgpack/predef/architecture/z.h | 43 + .../rpclib/include/rpc/msgpack/predef/compiler.h | 41 + .../include/rpc/msgpack/predef/compiler/borland.h | 64 + .../include/rpc/msgpack/predef/compiler/clang.h | 57 + .../include/rpc/msgpack/predef/compiler/comeau.h | 62 + .../include/rpc/msgpack/predef/compiler/compaq.h | 67 + .../include/rpc/msgpack/predef/compiler/diab.h | 57 + .../rpc/msgpack/predef/compiler/digitalmars.h | 57 + .../include/rpc/msgpack/predef/compiler/dignus.h | 57 + .../include/rpc/msgpack/predef/compiler/edg.h | 57 + .../include/rpc/msgpack/predef/compiler/ekopath.h | 58 + .../include/rpc/msgpack/predef/compiler/gcc.h | 69 + .../include/rpc/msgpack/predef/compiler/gcc_xml.h | 53 + .../rpc/msgpack/predef/compiler/greenhills.h | 67 + .../include/rpc/msgpack/predef/compiler/hp_acc.h | 62 + .../include/rpc/msgpack/predef/compiler/iar.h | 57 + .../include/rpc/msgpack/predef/compiler/ibm.h | 73 + .../include/rpc/msgpack/predef/compiler/intel.h | 66 + .../include/rpc/msgpack/predef/compiler/kai.h | 57 + .../include/rpc/msgpack/predef/compiler/llvm.h | 58 + .../include/rpc/msgpack/predef/compiler/metaware.h | 54 + .../rpc/msgpack/predef/compiler/metrowerks.h | 78 + .../include/rpc/msgpack/predef/compiler/microtec.h | 54 + .../include/rpc/msgpack/predef/compiler/mpw.h | 64 + .../include/rpc/msgpack/predef/compiler/palm.h | 57 + .../include/rpc/msgpack/predef/compiler/pgi.h | 61 + .../rpc/msgpack/predef/compiler/sgi_mipspro.h | 67 + .../include/rpc/msgpack/predef/compiler/sunpro.h | 67 + .../include/rpc/msgpack/predef/compiler/tendra.h | 54 + .../include/rpc/msgpack/predef/compiler/visualc.h | 92 + .../include/rpc/msgpack/predef/compiler/watcom.h | 57 + .../include/rpc/msgpack/predef/detail/_cassert.h | 17 + .../include/rpc/msgpack/predef/detail/_exception.h | 15 + .../rpc/msgpack/predef/detail/comp_detected.h | 10 + .../rpc/msgpack/predef/detail/endian_compat.h | 26 + .../rpc/msgpack/predef/detail/os_detected.h | 10 + .../rpc/msgpack/predef/detail/platform_detected.h | 10 + .../include/rpc/msgpack/predef/detail/test.h | 17 + .../rpclib/include/rpc/msgpack/predef/language.h | 15 + .../include/rpc/msgpack/predef/language/objc.h | 43 + .../include/rpc/msgpack/predef/language/stdc.h | 54 + .../include/rpc/msgpack/predef/language/stdcpp.h | 124 + .../rpclib/include/rpc/msgpack/predef/library.h | 14 + .../rpclib/include/rpc/msgpack/predef/library/c.h | 18 + .../include/rpc/msgpack/predef/library/c/_prefix.h | 13 + .../include/rpc/msgpack/predef/library/c/gnu.h | 62 + .../include/rpc/msgpack/predef/library/c/uc.h | 48 + .../include/rpc/msgpack/predef/library/c/vms.h | 48 + .../include/rpc/msgpack/predef/library/c/zos.h | 57 + .../include/rpc/msgpack/predef/library/std.h | 23 + .../rpc/msgpack/predef/library/std/_prefix.h | 23 + .../include/rpc/msgpack/predef/library/std/cxx.h | 47 + .../rpc/msgpack/predef/library/std/dinkumware.h | 53 + .../rpc/msgpack/predef/library/std/libcomo.h | 48 + .../rpc/msgpack/predef/library/std/modena.h | 46 + .../include/rpc/msgpack/predef/library/std/msl.h | 54 + .../rpc/msgpack/predef/library/std/roguewave.h | 57 + .../include/rpc/msgpack/predef/library/std/sgi.h | 52 + .../rpc/msgpack/predef/library/std/stdcpp3.h | 54 + .../rpc/msgpack/predef/library/std/stlport.h | 60 + .../include/rpc/msgpack/predef/library/std/vacpp.h | 45 + .../deps/rpclib/include/rpc/msgpack/predef/make.h | 89 + .../deps/rpclib/include/rpc/msgpack/predef/os.h | 31 + .../rpclib/include/rpc/msgpack/predef/os/aix.h | 67 + .../rpclib/include/rpc/msgpack/predef/os/amigaos.h | 47 + .../rpclib/include/rpc/msgpack/predef/os/android.h | 46 + .../rpclib/include/rpc/msgpack/predef/os/beos.h | 46 + .../rpclib/include/rpc/msgpack/predef/os/bsd.h | 95 + .../include/rpc/msgpack/predef/os/bsd/bsdi.h | 48 + .../include/rpc/msgpack/predef/os/bsd/dragonfly.h | 50 + .../include/rpc/msgpack/predef/os/bsd/free.h | 60 + .../rpclib/include/rpc/msgpack/predef/os/bsd/net.h | 84 + .../include/rpc/msgpack/predef/os/bsd/open.h | 171 + .../rpclib/include/rpc/msgpack/predef/os/cygwin.h | 46 + .../rpclib/include/rpc/msgpack/predef/os/haiku.h | 47 + .../rpclib/include/rpc/msgpack/predef/os/hpux.h | 48 + .../rpclib/include/rpc/msgpack/predef/os/ios.h | 51 + .../rpclib/include/rpc/msgpack/predef/os/irix.h | 47 + .../rpclib/include/rpc/msgpack/predef/os/linux.h | 47 + .../rpclib/include/rpc/msgpack/predef/os/macos.h | 66 + .../rpclib/include/rpc/msgpack/predef/os/os400.h | 46 + .../rpclib/include/rpc/msgpack/predef/os/qnxnto.h | 60 + .../rpclib/include/rpc/msgpack/predef/os/solaris.h | 47 + .../rpclib/include/rpc/msgpack/predef/os/unix.h | 76 + .../rpclib/include/rpc/msgpack/predef/os/vms.h | 53 + .../rpclib/include/rpc/msgpack/predef/os/windows.h | 51 + .../deps/rpclib/include/rpc/msgpack/predef/other.h | 14 + .../include/rpc/msgpack/predef/other/endian.h | 205 + .../rpclib/include/rpc/msgpack/predef/platform.h | 19 + .../include/rpc/msgpack/predef/platform/mingw.h | 70 + .../rpc/msgpack/predef/platform/windows_desktop.h | 44 + .../rpc/msgpack/predef/platform/windows_phone.h | 42 + .../rpc/msgpack/predef/platform/windows_runtime.h | 44 + .../rpc/msgpack/predef/platform/windows_store.h | 42 + .../rpclib/include/rpc/msgpack/predef/version.h | 15 + .../include/rpc/msgpack/predef/version_number.h | 54 + .../rpclib/include/rpc/msgpack/preprocessor.hpp | 19 + .../rpc/msgpack/preprocessor/arithmetic.hpp | 25 + .../rpc/msgpack/preprocessor/arithmetic/add.hpp | 51 + .../rpc/msgpack/preprocessor/arithmetic/dec.hpp | 288 + .../preprocessor/arithmetic/detail/div_base.hpp | 61 + .../rpc/msgpack/preprocessor/arithmetic/div.hpp | 39 + .../rpc/msgpack/preprocessor/arithmetic/inc.hpp | 288 + .../rpc/msgpack/preprocessor/arithmetic/mod.hpp | 39 + .../rpc/msgpack/preprocessor/arithmetic/mul.hpp | 53 + .../rpc/msgpack/preprocessor/arithmetic/sub.hpp | 50 + .../include/rpc/msgpack/preprocessor/array.hpp | 32 + .../rpc/msgpack/preprocessor/array/data.hpp | 28 + .../msgpack/preprocessor/array/detail/get_data.hpp | 55 + .../rpc/msgpack/preprocessor/array/elem.hpp | 29 + .../rpc/msgpack/preprocessor/array/enum.hpp | 33 + .../rpc/msgpack/preprocessor/array/insert.hpp | 55 + .../rpc/msgpack/preprocessor/array/pop_back.hpp | 37 + .../rpc/msgpack/preprocessor/array/pop_front.hpp | 38 + .../rpc/msgpack/preprocessor/array/push_back.hpp | 35 + .../rpc/msgpack/preprocessor/array/push_front.hpp | 35 + .../rpc/msgpack/preprocessor/array/remove.hpp | 54 + .../rpc/msgpack/preprocessor/array/replace.hpp | 49 + .../rpc/msgpack/preprocessor/array/reverse.hpp | 29 + .../rpc/msgpack/preprocessor/array/size.hpp | 28 + .../rpc/msgpack/preprocessor/array/to_list.hpp | 47 + .../rpc/msgpack/preprocessor/array/to_seq.hpp | 46 + .../rpc/msgpack/preprocessor/array/to_tuple.hpp | 33 + .../rpc/msgpack/preprocessor/assert_msg.hpp | 17 + .../include/rpc/msgpack/preprocessor/cat.hpp | 35 + .../include/rpc/msgpack/preprocessor/comma.hpp | 17 + .../include/rpc/msgpack/preprocessor/comma_if.hpp | 17 + .../rpc/msgpack/preprocessor/comparison.hpp | 24 + .../rpc/msgpack/preprocessor/comparison/equal.hpp | 34 + .../msgpack/preprocessor/comparison/greater.hpp | 38 + .../preprocessor/comparison/greater_equal.hpp | 38 + .../rpc/msgpack/preprocessor/comparison/less.hpp | 46 + .../msgpack/preprocessor/comparison/less_equal.hpp | 39 + .../msgpack/preprocessor/comparison/not_equal.hpp | 814 ++ .../rpc/msgpack/preprocessor/config/config.hpp | 101 + .../rpc/msgpack/preprocessor/config/limits.hpp | 30 + .../include/rpc/msgpack/preprocessor/control.hpp | 22 + .../rpc/msgpack/preprocessor/control/deduce_d.hpp | 22 + .../preprocessor/control/detail/dmc/while.hpp | 536 + .../preprocessor/control/detail/edg/while.hpp | 534 + .../preprocessor/control/detail/msvc/while.hpp | 277 + .../msgpack/preprocessor/control/detail/while.hpp | 536 + .../rpc/msgpack/preprocessor/control/expr_if.hpp | 30 + .../rpc/msgpack/preprocessor/control/expr_iif.hpp | 31 + .../rpc/msgpack/preprocessor/control/if.hpp | 30 + .../rpc/msgpack/preprocessor/control/iif.hpp | 34 + .../rpc/msgpack/preprocessor/control/while.hpp | 312 + .../include/rpc/msgpack/preprocessor/debug.hpp | 18 + .../rpc/msgpack/preprocessor/debug/assert.hpp | 44 + .../rpc/msgpack/preprocessor/debug/error.hpp | 33 + .../rpc/msgpack/preprocessor/debug/line.hpp | 35 + .../include/rpc/msgpack/preprocessor/dec.hpp | 17 + .../rpc/msgpack/preprocessor/detail/auto_rec.hpp | 293 + .../rpc/msgpack/preprocessor/detail/check.hpp | 48 + .../msgpack/preprocessor/detail/dmc/auto_rec.hpp | 286 + .../rpc/msgpack/preprocessor/detail/is_binary.hpp | 30 + .../rpc/msgpack/preprocessor/detail/is_nullary.hpp | 30 + .../rpc/msgpack/preprocessor/detail/is_unary.hpp | 30 + .../rpc/msgpack/preprocessor/detail/null.hpp | 17 + .../rpc/msgpack/preprocessor/detail/split.hpp | 35 + .../include/rpc/msgpack/preprocessor/empty.hpp | 17 + .../include/rpc/msgpack/preprocessor/enum.hpp | 17 + .../rpc/msgpack/preprocessor/enum_params.hpp | 17 + .../preprocessor/enum_params_with_a_default.hpp | 17 + .../preprocessor/enum_params_with_defaults.hpp | 17 + .../rpc/msgpack/preprocessor/enum_shifted.hpp | 17 + .../msgpack/preprocessor/enum_shifted_params.hpp | 17 + .../include/rpc/msgpack/preprocessor/expand.hpp | 17 + .../include/rpc/msgpack/preprocessor/expr_if.hpp | 17 + .../rpc/msgpack/preprocessor/facilities.hpp | 23 + .../rpc/msgpack/preprocessor/facilities/apply.hpp | 34 + .../preprocessor/facilities/detail/is_empty.hpp | 55 + .../rpc/msgpack/preprocessor/facilities/empty.hpp | 23 + .../rpc/msgpack/preprocessor/facilities/expand.hpp | 28 + .../msgpack/preprocessor/facilities/identity.hpp | 23 + .../msgpack/preprocessor/facilities/intercept.hpp | 277 + .../rpc/msgpack/preprocessor/facilities/is_1.hpp | 23 + .../msgpack/preprocessor/facilities/is_empty.hpp | 56 + .../preprocessor/facilities/is_empty_or_1.hpp | 31 + .../preprocessor/facilities/is_empty_variadic.hpp | 57 + .../msgpack/preprocessor/facilities/overload.hpp | 25 + .../include/rpc/msgpack/preprocessor/for.hpp | 17 + .../include/rpc/msgpack/preprocessor/identity.hpp | 17 + .../rpclib/include/rpc/msgpack/preprocessor/if.hpp | 17 + .../include/rpc/msgpack/preprocessor/inc.hpp | 17 + .../include/rpc/msgpack/preprocessor/iterate.hpp | 17 + .../include/rpc/msgpack/preprocessor/iteration.hpp | 19 + .../iteration/detail/bounds/lower1.hpp | 99 + .../iteration/detail/bounds/lower2.hpp | 99 + .../iteration/detail/bounds/lower3.hpp | 99 + .../iteration/detail/bounds/lower4.hpp | 99 + .../iteration/detail/bounds/lower5.hpp | 99 + .../iteration/detail/bounds/upper1.hpp | 99 + .../iteration/detail/bounds/upper2.hpp | 99 + .../iteration/detail/bounds/upper3.hpp | 99 + .../iteration/detail/bounds/upper4.hpp | 99 + .../iteration/detail/bounds/upper5.hpp | 99 + .../preprocessor/iteration/detail/finish.hpp | 99 + .../iteration/detail/iter/forward1.hpp | 1342 ++ .../iteration/detail/iter/forward2.hpp | 1338 ++ .../iteration/detail/iter/forward3.hpp | 1338 ++ .../iteration/detail/iter/forward4.hpp | 1338 ++ .../iteration/detail/iter/forward5.hpp | 1338 ++ .../iteration/detail/iter/reverse1.hpp | 1296 ++ .../iteration/detail/iter/reverse2.hpp | 1296 ++ .../iteration/detail/iter/reverse3.hpp | 1296 ++ .../iteration/detail/iter/reverse4.hpp | 1296 ++ .../iteration/detail/iter/reverse5.hpp | 1296 ++ .../preprocessor/iteration/detail/local.hpp | 812 ++ .../preprocessor/iteration/detail/rlocal.hpp | 782 ++ .../msgpack/preprocessor/iteration/detail/self.hpp | 21 + .../preprocessor/iteration/detail/start.hpp | 99 + .../rpc/msgpack/preprocessor/iteration/iterate.hpp | 82 + .../rpc/msgpack/preprocessor/iteration/local.hpp | 26 + .../rpc/msgpack/preprocessor/iteration/self.hpp | 19 + .../include/rpc/msgpack/preprocessor/library.hpp | 36 + .../include/rpc/msgpack/preprocessor/limits.hpp | 17 + .../include/rpc/msgpack/preprocessor/list.hpp | 37 + .../include/rpc/msgpack/preprocessor/list/adt.hpp | 73 + .../rpc/msgpack/preprocessor/list/append.hpp | 40 + .../include/rpc/msgpack/preprocessor/list/at.hpp | 39 + .../include/rpc/msgpack/preprocessor/list/cat.hpp | 42 + .../preprocessor/list/detail/dmc/fold_left.hpp | 279 + .../preprocessor/list/detail/edg/fold_left.hpp | 536 + .../preprocessor/list/detail/edg/fold_right.hpp | 794 ++ .../msgpack/preprocessor/list/detail/fold_left.hpp | 279 + .../preprocessor/list/detail/fold_right.hpp | 277 + .../include/rpc/msgpack/preprocessor/list/enum.hpp | 41 + .../rpc/msgpack/preprocessor/list/filter.hpp | 54 + .../rpc/msgpack/preprocessor/list/first_n.hpp | 58 + .../rpc/msgpack/preprocessor/list/fold_left.hpp | 303 + .../rpc/msgpack/preprocessor/list/fold_right.hpp | 40 + .../rpc/msgpack/preprocessor/list/for_each.hpp | 49 + .../rpc/msgpack/preprocessor/list/for_each_i.hpp | 65 + .../msgpack/preprocessor/list/for_each_product.hpp | 141 + .../rpc/msgpack/preprocessor/list/rest_n.hpp | 55 + .../rpc/msgpack/preprocessor/list/reverse.hpp | 40 + .../include/rpc/msgpack/preprocessor/list/size.hpp | 58 + .../rpc/msgpack/preprocessor/list/to_array.hpp | 155 + .../rpc/msgpack/preprocessor/list/to_seq.hpp | 32 + .../rpc/msgpack/preprocessor/list/to_tuple.hpp | 61 + .../rpc/msgpack/preprocessor/list/transform.hpp | 49 + .../include/rpc/msgpack/preprocessor/logical.hpp | 29 + .../rpc/msgpack/preprocessor/logical/and.hpp | 30 + .../rpc/msgpack/preprocessor/logical/bitand.hpp | 38 + .../rpc/msgpack/preprocessor/logical/bitnor.hpp | 38 + .../rpc/msgpack/preprocessor/logical/bitor.hpp | 38 + .../rpc/msgpack/preprocessor/logical/bitxor.hpp | 38 + .../rpc/msgpack/preprocessor/logical/bool.hpp | 288 + .../rpc/msgpack/preprocessor/logical/compl.hpp | 36 + .../rpc/msgpack/preprocessor/logical/nor.hpp | 30 + .../rpc/msgpack/preprocessor/logical/not.hpp | 30 + .../rpc/msgpack/preprocessor/logical/or.hpp | 30 + .../rpc/msgpack/preprocessor/logical/xor.hpp | 30 + .../include/rpc/msgpack/preprocessor/max.hpp | 17 + .../include/rpc/msgpack/preprocessor/min.hpp | 17 + .../rpc/msgpack/preprocessor/punctuation.hpp | 22 + .../rpc/msgpack/preprocessor/punctuation/comma.hpp | 21 + .../msgpack/preprocessor/punctuation/comma_if.hpp | 31 + .../punctuation/detail/is_begin_parens.hpp | 48 + .../preprocessor/punctuation/is_begin_parens.hpp | 51 + .../rpc/msgpack/preprocessor/punctuation/paren.hpp | 23 + .../msgpack/preprocessor/punctuation/paren_if.hpp | 38 + .../preprocessor/punctuation/remove_parens.hpp | 39 + .../include/rpc/msgpack/preprocessor/repeat.hpp | 17 + .../rpc/msgpack/preprocessor/repeat_2nd.hpp | 17 + .../rpc/msgpack/preprocessor/repeat_3rd.hpp | 17 + .../rpc/msgpack/preprocessor/repeat_from_to.hpp | 17 + .../msgpack/preprocessor/repeat_from_to_2nd.hpp | 17 + .../msgpack/preprocessor/repeat_from_to_3rd.hpp | 17 + .../rpc/msgpack/preprocessor/repetition.hpp | 32 + .../msgpack/preprocessor/repetition/deduce_r.hpp | 22 + .../msgpack/preprocessor/repetition/deduce_z.hpp | 22 + .../preprocessor/repetition/detail/dmc/for.hpp | 536 + .../preprocessor/repetition/detail/edg/for.hpp | 534 + .../msgpack/preprocessor/repetition/detail/for.hpp | 536 + .../preprocessor/repetition/detail/msvc/for.hpp | 277 + .../rpc/msgpack/preprocessor/repetition/enum.hpp | 66 + .../preprocessor/repetition/enum_binary_params.hpp | 54 + .../preprocessor/repetition/enum_params.hpp | 41 + .../repetition/enum_params_with_a_default.hpp | 25 + .../repetition/enum_params_with_defaults.hpp | 24 + .../preprocessor/repetition/enum_shifted.hpp | 68 + .../repetition/enum_shifted_binary_params.hpp | 51 + .../repetition/enum_shifted_params.hpp | 44 + .../preprocessor/repetition/enum_trailing.hpp | 63 + .../repetition/enum_trailing_binary_params.hpp | 53 + .../repetition/enum_trailing_params.hpp | 38 + .../rpc/msgpack/preprocessor/repetition/for.hpp | 306 + .../rpc/msgpack/preprocessor/repetition/repeat.hpp | 825 ++ .../preprocessor/repetition/repeat_from_to.hpp | 87 + .../include/rpc/msgpack/preprocessor/selection.hpp | 18 + .../rpc/msgpack/preprocessor/selection/max.hpp | 39 + .../rpc/msgpack/preprocessor/selection/min.hpp | 39 + .../include/rpc/msgpack/preprocessor/seq.hpp | 44 + .../include/rpc/msgpack/preprocessor/seq/cat.hpp | 49 + .../preprocessor/seq/detail/binary_transform.hpp | 48 + .../rpc/msgpack/preprocessor/seq/detail/split.hpp | 284 + .../include/rpc/msgpack/preprocessor/seq/elem.hpp | 304 + .../include/rpc/msgpack/preprocessor/seq/enum.hpp | 288 + .../rpc/msgpack/preprocessor/seq/filter.hpp | 54 + .../rpc/msgpack/preprocessor/seq/first_n.hpp | 30 + .../rpc/msgpack/preprocessor/seq/fold_left.hpp | 1070 ++ .../rpc/msgpack/preprocessor/seq/fold_right.hpp | 288 + .../rpc/msgpack/preprocessor/seq/for_each.hpp | 60 + .../rpc/msgpack/preprocessor/seq/for_each_i.hpp | 61 + .../msgpack/preprocessor/seq/for_each_product.hpp | 126 + .../rpc/msgpack/preprocessor/seq/insert.hpp | 28 + .../rpc/msgpack/preprocessor/seq/pop_back.hpp | 29 + .../rpc/msgpack/preprocessor/seq/pop_front.hpp | 27 + .../rpc/msgpack/preprocessor/seq/push_back.hpp | 19 + .../rpc/msgpack/preprocessor/seq/push_front.hpp | 19 + .../rpc/msgpack/preprocessor/seq/remove.hpp | 29 + .../rpc/msgpack/preprocessor/seq/replace.hpp | 29 + .../rpc/msgpack/preprocessor/seq/rest_n.hpp | 30 + .../rpc/msgpack/preprocessor/seq/reverse.hpp | 39 + .../include/rpc/msgpack/preprocessor/seq/seq.hpp | 44 + .../include/rpc/msgpack/preprocessor/seq/size.hpp | 547 + .../rpc/msgpack/preprocessor/seq/subseq.hpp | 28 + .../rpc/msgpack/preprocessor/seq/to_array.hpp | 28 + .../rpc/msgpack/preprocessor/seq/to_list.hpp | 29 + .../rpc/msgpack/preprocessor/seq/to_tuple.hpp | 27 + .../rpc/msgpack/preprocessor/seq/transform.hpp | 48 + .../preprocessor/seq/variadic_seq_to_seq.hpp | 28 + .../include/rpc/msgpack/preprocessor/slot.hpp | 17 + .../rpc/msgpack/preprocessor/slot/counter.hpp | 25 + .../msgpack/preprocessor/slot/detail/counter.hpp | 269 + .../rpc/msgpack/preprocessor/slot/detail/def.hpp | 49 + .../msgpack/preprocessor/slot/detail/shared.hpp | 247 + .../rpc/msgpack/preprocessor/slot/detail/slot1.hpp | 267 + .../rpc/msgpack/preprocessor/slot/detail/slot2.hpp | 267 + .../rpc/msgpack/preprocessor/slot/detail/slot3.hpp | 267 + .../rpc/msgpack/preprocessor/slot/detail/slot4.hpp | 267 + .../rpc/msgpack/preprocessor/slot/detail/slot5.hpp | 267 + .../include/rpc/msgpack/preprocessor/slot/slot.hpp | 32 + .../include/rpc/msgpack/preprocessor/stringize.hpp | 33 + .../include/rpc/msgpack/preprocessor/tuple.hpp | 35 + .../preprocessor/tuple/detail/is_single_return.hpp | 28 + .../include/rpc/msgpack/preprocessor/tuple/eat.hpp | 106 + .../rpc/msgpack/preprocessor/tuple/elem.hpp | 201 + .../rpc/msgpack/preprocessor/tuple/enum.hpp | 22 + .../rpc/msgpack/preprocessor/tuple/insert.hpp | 37 + .../rpc/msgpack/preprocessor/tuple/pop_back.hpp | 64 + .../rpc/msgpack/preprocessor/tuple/pop_front.hpp | 65 + .../rpc/msgpack/preprocessor/tuple/push_back.hpp | 31 + .../rpc/msgpack/preprocessor/tuple/push_front.hpp | 32 + .../include/rpc/msgpack/preprocessor/tuple/rem.hpp | 149 + .../rpc/msgpack/preprocessor/tuple/remove.hpp | 64 + .../rpc/msgpack/preprocessor/tuple/replace.hpp | 37 + .../rpc/msgpack/preprocessor/tuple/reverse.hpp | 117 + .../rpc/msgpack/preprocessor/tuple/size.hpp | 28 + .../rpc/msgpack/preprocessor/tuple/to_array.hpp | 39 + .../rpc/msgpack/preprocessor/tuple/to_list.hpp | 118 + .../rpc/msgpack/preprocessor/tuple/to_seq.hpp | 119 + .../include/rpc/msgpack/preprocessor/variadic.hpp | 23 + .../variadic/detail/is_single_return.hpp | 28 + .../rpc/msgpack/preprocessor/variadic/elem.hpp | 94 + .../rpc/msgpack/preprocessor/variadic/size.hpp | 30 + .../rpc/msgpack/preprocessor/variadic/to_array.hpp | 32 + .../rpc/msgpack/preprocessor/variadic/to_list.hpp | 25 + .../rpc/msgpack/preprocessor/variadic/to_seq.hpp | 25 + .../rpc/msgpack/preprocessor/variadic/to_tuple.hpp | 24 + .../include/rpc/msgpack/preprocessor/while.hpp | 17 + .../rpc/msgpack/preprocessor/wstringize.hpp | 29 + host/lib/deps/rpclib/include/rpc/msgpack/sbuffer.h | 118 + .../deps/rpclib/include/rpc/msgpack/sbuffer.hpp | 160 + host/lib/deps/rpclib/include/rpc/msgpack/sysdep.h | 195 + host/lib/deps/rpclib/include/rpc/msgpack/type.hpp | 51 + host/lib/deps/rpclib/include/rpc/msgpack/unpack.h | 278 + .../lib/deps/rpclib/include/rpc/msgpack/unpack.hpp | 1719 +++ .../rpclib/include/rpc/msgpack/unpack_define.h | 97 + .../rpclib/include/rpc/msgpack/unpack_template.h | 482 + host/lib/deps/rpclib/include/rpc/msgpack/util.h | 23 + host/lib/deps/rpclib/include/rpc/msgpack/version.h | 46 + .../deps/rpclib/include/rpc/msgpack/version.hpp | 44 + .../rpclib/include/rpc/msgpack/version_master.h | 3 + .../deps/rpclib/include/rpc/msgpack/versioning.hpp | 77 + .../deps/rpclib/include/rpc/msgpack/vrefbuffer.h | 149 + .../deps/rpclib/include/rpc/msgpack/vrefbuffer.hpp | 300 + host/lib/deps/rpclib/include/rpc/msgpack/zbuffer.h | 208 + .../deps/rpclib/include/rpc/msgpack/zbuffer.hpp | 175 + host/lib/deps/rpclib/include/rpc/msgpack/zone.h | 171 + host/lib/deps/rpclib/include/rpc/msgpack/zone.hpp | 29 + host/lib/deps/rpclib/include/rpc/rpc_error.h | 52 + host/lib/deps/rpclib/include/rpc/server.h | 104 + host/lib/deps/rpclib/include/rpc/this_handler.h | 82 + host/lib/deps/rpclib/include/rpc/this_handler.inl | 14 + host/lib/deps/rpclib/include/rpc/this_server.h | 37 + host/lib/deps/rpclib/include/rpc/this_session.h | 44 + host/lib/deps/rpclib/include/rpc/version.h | 14 + host/lib/deps/rpclib/include/rpc/version.h.in | 14 + host/lib/deps/rpclib/lib/rpc/client.cc | 223 + .../lib/deps/rpclib/lib/rpc/detail/client_error.cc | 15 + host/lib/deps/rpclib/lib/rpc/detail/response.cc | 65 + .../deps/rpclib/lib/rpc/detail/server_session.cc | 135 + host/lib/deps/rpclib/lib/rpc/dispatcher.cc | 135 + host/lib/deps/rpclib/lib/rpc/rpc_error.cc | 24 + host/lib/deps/rpclib/lib/rpc/server.cc | 116 + host/lib/deps/rpclib/lib/rpc/this_handler.cc | 27 + host/lib/deps/rpclib/lib/rpc/this_server.cc | 19 + host/lib/deps/rpclib/lib/rpc/this_session.cc | 20 + 520 files changed, 84485 insertions(+) create mode 100644 host/lib/deps/0001-rpclib-replace-fmt-with-boost-format-but-leave-it-in.patch create mode 100644 host/lib/deps/0002-rpclib-use-the-real-boost-asio-namespace.patch create mode 100644 host/lib/deps/0003-rpclib-add-boost-system-error_code-and-include-rpc-c.patch create mode 100644 host/lib/deps/CMakeLists.txt create mode 100755 host/lib/deps/import_rpclib.py create mode 100644 host/lib/deps/rpc_CMakeLists.txt create mode 100644 host/lib/deps/rpclib/CHANGELOG.md create mode 100644 host/lib/deps/rpclib/CMakeLists.txt create mode 100644 host/lib/deps/rpclib/LICENSE.md create mode 100644 host/lib/deps/rpclib/README.md create mode 100644 host/lib/deps/rpclib/include/rpc/client.h create mode 100644 host/lib/deps/rpclib/include/rpc/client.inl create mode 100644 host/lib/deps/rpclib/include/rpc/compatibility.h create mode 100644 host/lib/deps/rpclib/include/rpc/config.h create mode 100644 host/lib/deps/rpclib/include/rpc/config.h.in create mode 100644 host/lib/deps/rpclib/include/rpc/detail/all.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/any.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/async_writer.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/bool.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/call.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/client_error.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/constant.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/dev_utils.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/func_tools.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/func_traits.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/if.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/invoke.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/is_specialization_of.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/log.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/make_unique.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/not.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/pimpl.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/response.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/server_session.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/thread_group.h create mode 100644 host/lib/deps/rpclib/include/rpc/detail/util.h create mode 100644 host/lib/deps/rpclib/include/rpc/dispatcher.h create mode 100644 host/lib/deps/rpclib/include/rpc/dispatcher.inl create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/adaptor_base.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/array_ref.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/bool.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/boost/fusion.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/boost/msgpack_variant.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/boost/optional.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/boost/string_ref.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/char_ptr.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/check_container_size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/array_char.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/array_unsigned_char.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/forward_list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/shared_ptr.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/unique_ptr.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/unordered_map.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/cpp11/unordered_set.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/define.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/deque.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp03_define_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp03_define_map.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp03_msgpack_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp11_define_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp11_define_map.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/detail/cpp11_msgpack_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/ext.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/fixint.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/float.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/int.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/map.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/msgpack_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/nil.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/pair.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/raw.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/set.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/string.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/tr1/unordered_map.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/tr1/unordered_set.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/v4raw.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/vector.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/vector_bool.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/vector_char.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/adaptor/vector_unsigned_char.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/cpp_config.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/detail/cpp03_zone.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/detail/cpp11_zone.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/fbuffer.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/fbuffer.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/gcc_atomic.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/iterator.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/meta.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/object.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/object.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/object_fwd.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/pack.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/pack.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/pack_define.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/pack_template.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/alpha.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/arm.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/blackfin.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/convex.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/ia64.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/m68k.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/mips.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/parisc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/ppc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/pyramid.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/rs6k.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/sparc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/superh.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/sys370.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/sys390.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/x86.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/x86/32.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/x86/64.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/architecture/z.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/borland.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/clang.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/comeau.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/compaq.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/diab.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/digitalmars.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/dignus.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/edg.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/ekopath.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/gcc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/gcc_xml.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/greenhills.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/hp_acc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/iar.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/ibm.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/intel.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/kai.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/llvm.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/metaware.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/metrowerks.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/microtec.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/mpw.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/palm.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/pgi.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/sgi_mipspro.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/sunpro.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/tendra.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/visualc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/compiler/watcom.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/_cassert.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/_exception.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/comp_detected.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/endian_compat.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/os_detected.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/platform_detected.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/detail/test.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/language.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/language/objc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/language/stdc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/language/stdcpp.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c/_prefix.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c/gnu.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c/uc.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c/vms.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/c/zos.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/_prefix.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/cxx.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/dinkumware.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/libcomo.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/modena.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/msl.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/roguewave.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/sgi.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/stdcpp3.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/stlport.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/library/std/vacpp.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/make.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/aix.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/amigaos.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/android.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/beos.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd/bsdi.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd/dragonfly.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd/free.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd/net.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/bsd/open.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/cygwin.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/haiku.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/hpux.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/ios.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/irix.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/linux.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/macos.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/os400.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/qnxnto.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/solaris.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/unix.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/vms.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/os/windows.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/other.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/other/endian.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform/mingw.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform/windows_desktop.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform/windows_phone.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform/windows_runtime.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/platform/windows_store.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/version.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/predef/version_number.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/add.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/dec.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/detail/div_base.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/div.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/inc.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/mod.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/mul.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/arithmetic/sub.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/data.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/detail/get_data.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/elem.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/insert.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/pop_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/pop_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/push_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/push_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/remove.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/replace.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/reverse.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/to_list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/to_seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/array/to_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/assert_msg.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/cat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comma.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comma_if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/equal.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/greater.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/greater_equal.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/less.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/less_equal.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/comparison/not_equal.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/config/config.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/config/limits.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/deduce_d.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/detail/dmc/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/detail/edg/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/detail/msvc/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/detail/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/expr_if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/expr_iif.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/iif.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/control/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/debug.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/debug/assert.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/debug/error.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/debug/line.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/dec.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/auto_rec.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/check.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/dmc/auto_rec.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/is_binary.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/is_nullary.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/is_unary.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/null.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/detail/split.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/empty.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum_params_with_a_default.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum_params_with_defaults.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum_shifted.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/enum_shifted_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/expand.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/expr_if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/apply.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/detail/is_empty.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/empty.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/expand.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/identity.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/intercept.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/is_1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/is_empty.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/is_empty_or_1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/is_empty_variadic.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/facilities/overload.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/identity.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/inc.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iterate.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/lower1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/lower2.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/lower3.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/lower4.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/lower5.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/upper1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/upper2.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/upper3.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/upper4.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/bounds/upper5.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/finish.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/forward1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/forward2.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/forward3.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/forward4.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/forward5.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/reverse1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/reverse2.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/reverse3.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/reverse4.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/iter/reverse5.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/local.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/rlocal.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/self.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/detail/start.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/iterate.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/local.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/iteration/self.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/library.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/limits.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/adt.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/append.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/at.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/cat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/detail/dmc/fold_left.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/detail/edg/fold_left.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/detail/edg/fold_right.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/detail/fold_left.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/detail/fold_right.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/filter.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/first_n.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/fold_left.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/fold_right.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/for_each.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/for_each_i.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/for_each_product.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/rest_n.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/reverse.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/to_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/to_seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/to_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/list/transform.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/and.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/bitand.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/bitnor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/bitor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/bitxor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/bool.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/compl.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/nor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/not.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/or.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/logical/xor.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/max.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/min.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/comma.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/comma_if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/detail/is_begin_parens.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/is_begin_parens.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/paren.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/paren_if.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/punctuation/remove_parens.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat_2nd.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat_3rd.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat_from_to.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat_from_to_2nd.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repeat_from_to_3rd.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/deduce_r.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/deduce_z.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/detail/dmc/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/detail/edg/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/detail/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/detail/msvc/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_binary_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_params_with_a_default.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_params_with_defaults.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_shifted.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_shifted_binary_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_shifted_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_trailing.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_trailing_binary_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/enum_trailing_params.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/for.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/repeat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/repetition/repeat_from_to.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/selection.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/selection/max.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/selection/min.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/cat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/detail/binary_transform.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/detail/split.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/elem.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/filter.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/first_n.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/fold_left.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/fold_right.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/for_each.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/for_each_i.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/for_each_product.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/insert.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/pop_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/pop_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/push_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/push_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/remove.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/replace.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/rest_n.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/reverse.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/subseq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/to_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/to_list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/to_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/transform.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/seq/variadic_seq_to_seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/counter.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/counter.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/def.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/shared.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/slot1.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/slot2.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/slot3.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/slot4.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/detail/slot5.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/slot/slot.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/stringize.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/detail/is_single_return.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/eat.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/elem.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/enum.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/insert.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/pop_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/pop_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/push_back.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/push_front.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/rem.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/remove.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/replace.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/reverse.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/to_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/to_list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/tuple/to_seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/detail/is_single_return.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/elem.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/size.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/to_array.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/to_list.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/to_seq.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/variadic/to_tuple.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/while.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/preprocessor/wstringize.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/sbuffer.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/sbuffer.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/sysdep.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/type.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/unpack.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/unpack.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/unpack_define.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/unpack_template.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/util.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/version.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/version.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/version_master.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/versioning.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/vrefbuffer.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/vrefbuffer.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/zbuffer.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/zbuffer.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/zone.h create mode 100644 host/lib/deps/rpclib/include/rpc/msgpack/zone.hpp create mode 100644 host/lib/deps/rpclib/include/rpc/rpc_error.h create mode 100644 host/lib/deps/rpclib/include/rpc/server.h create mode 100644 host/lib/deps/rpclib/include/rpc/this_handler.h create mode 100644 host/lib/deps/rpclib/include/rpc/this_handler.inl create mode 100644 host/lib/deps/rpclib/include/rpc/this_server.h create mode 100644 host/lib/deps/rpclib/include/rpc/this_session.h create mode 100644 host/lib/deps/rpclib/include/rpc/version.h create mode 100644 host/lib/deps/rpclib/include/rpc/version.h.in create mode 100644 host/lib/deps/rpclib/lib/rpc/client.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/detail/client_error.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/detail/response.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/detail/server_session.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/dispatcher.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/rpc_error.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/server.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/this_handler.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/this_server.cc create mode 100644 host/lib/deps/rpclib/lib/rpc/this_session.cc diff --git a/host/lib/deps/0001-rpclib-replace-fmt-with-boost-format-but-leave-it-in.patch b/host/lib/deps/0001-rpclib-replace-fmt-with-boost-format-but-leave-it-in.patch new file mode 100644 index 000000000..0d3bddc20 --- /dev/null +++ b/host/lib/deps/0001-rpclib-replace-fmt-with-boost-format-but-leave-it-in.patch @@ -0,0 +1,155 @@ +From 74505c84e326f8524a374911fcfe5dc29426a274 Mon Sep 17 00:00:00 2001 +From: Andrej Rode +Date: Thu, 6 Apr 2017 15:53:37 -0700 +Subject: [PATCH 1/3] rpclib: replace fmt with boost::format (but leave it in + logging) + +Signed-off-by: Andrej Rode +--- + lib/rpc/client.cc | 6 +++--- + lib/rpc/detail/client_error.cc | 6 +++--- + lib/rpc/dispatcher.cc | 30 +++++++++++++++--------------- + lib/rpc/rpc_error.cc | 4 ++-- + 4 files changed, 23 insertions(+), 23 deletions(-) + +diff --git a/lib/rpc/client.cc b/lib/rpc/client.cc +index 5ab9780..e5d0117 100644 +--- a/lib/rpc/client.cc ++++ b/lib/rpc/client.cc +@@ -11,7 +11,7 @@ + #include + + #include "asio.hpp" +-#include "format.h" ++#include + + #include "rpc/detail/async_writer.h" + #include "rpc/detail/dev_utils.h" +@@ -212,8 +212,8 @@ void client::wait_all_responses() { + + RPCLIB_NORETURN void client::throw_timeout(std::string const& func_name) { + throw rpc::timeout( +- RPCLIB_FMT::format("Timeout of {}ms while calling RPC function '{}'", +- get_timeout(), func_name)); ++ str(boost::format("Timeout of %dms while calling RPC function '%s'") % ++ get_timeout() % func_name)); + } + + client::~client() { +diff --git a/lib/rpc/detail/client_error.cc b/lib/rpc/detail/client_error.cc +index 263141f..deea2f6 100644 +--- a/lib/rpc/detail/client_error.cc ++++ b/lib/rpc/detail/client_error.cc +@@ -1,4 +1,4 @@ +-#include "format.h" ++#include + + #include "rpc/detail/client_error.h" + +@@ -6,8 +6,8 @@ namespace rpc { + namespace detail { + + client_error::client_error(code c, const std::string &msg) +- : what_(RPCLIB_FMT::format("client error C{0:04x}: {1}", +- static_cast(c), msg)) {} ++ : what_(str(boost::format("client error C%d: %") % ++ static_cast(c) % msg)) {} + + const char *client_error::what() const noexcept { return what_.c_str(); } + } +diff --git a/lib/rpc/dispatcher.cc b/lib/rpc/dispatcher.cc +index e8954b8..c502b80 100644 +--- a/lib/rpc/dispatcher.cc ++++ b/lib/rpc/dispatcher.cc +@@ -1,5 +1,5 @@ + #include "rpc/dispatcher.h" +-#include "format.h" ++#include + #include "rpc/detail/client_error.h" + #include "rpc/this_handler.h" + +@@ -48,18 +48,18 @@ response dispatcher::dispatch_call(RPCLIB_MSGPACK::object const &msg, + return response::make_result(id, std::move(result)); + } catch (rpc::detail::client_error &e) { + return response::make_error( +- id, RPCLIB_FMT::format("rpclib: {}", e.what())); ++ id, str(boost::format("rpclib: %s") % e.what())); + } catch (std::exception &e) { + if (!suppress_exceptions) { + throw; + } + return response::make_error( + id, +- RPCLIB_FMT::format("rpclib: function '{0}' (called with {1} " ++ str(boost::format("rpclib: function '%s' (called with %d " + "arg(s)) " + "threw an exception. The exception " +- "contained this information: {2}.", +- name, args.via.array.size, e.what())); ++ "contained this information: %s.") % ++ name % args.via.array.size % e.what())); + } catch (rpc::detail::handler_error &) { + // doing nothing, the exception was only thrown to + // return immediately +@@ -72,17 +72,17 @@ response dispatcher::dispatch_call(RPCLIB_MSGPACK::object const &msg, + } + return response::make_error( + id, +- RPCLIB_FMT::format("rpclib: function '{0}' (called with {1} " ++ str(boost::format("rpclib: function '%s' (called with %d " + "arg(s)) threw an exception. The exception " + "is not derived from std::exception. No " +- "further information available.", +- name, args.via.array.size)); ++ "further information available.") % ++ name % args.via.array.size)); + } + } + return response::make_error( +- id, RPCLIB_FMT::format("rpclib: server could not find " +- "function '{0}' with argument count {1}.", +- name, args.via.array.size)); ++ id, str(boost::format("rpclib: server could not find " ++ "function '%s' with argument count %d.") % ++ name % args.via.array.size)); + } + + response dispatcher::dispatch_notification(RPCLIB_MSGPACK::object const &msg, +@@ -124,10 +124,10 @@ void dispatcher::enforce_arg_count(std::string const &func, std::size_t found, + if (found != expected) { + throw client_error( + client_error::code::wrong_arity, +- RPCLIB_FMT::format( +- "Function '{0}' was called with an invalid number of " +- "arguments. Expected: {1}, got: {2}", +- func, expected, found)); ++ str(boost::format( ++ "Function '%s' was called with an invalid number of " ++ "arguments. Expected: %d, got: %d") % ++ func % expected % found)); + } + } + +diff --git a/lib/rpc/rpc_error.cc b/lib/rpc/rpc_error.cc +index 8af7006..dcf3c1c 100644 +--- a/lib/rpc/rpc_error.cc ++++ b/lib/rpc/rpc_error.cc +@@ -1,5 +1,5 @@ + #include "rpc/rpc_error.h" +-#include "format.h" ++#include + + namespace rpc { + +@@ -16,7 +16,7 @@ RPCLIB_MSGPACK::object_handle &rpc_error::get_error() { return ob_h_; } + + timeout::timeout(std::string const &what_arg) : std::runtime_error(what_arg) { + formatted = +- RPCLIB_FMT::format("rpc::timeout: {}", std::runtime_error::what()); ++ str(boost::format("rpc::timeout: %s") % std::runtime_error::what()); + } + + const char *timeout::what() const noexcept { return formatted.data(); } +-- +2.10.2 + diff --git a/host/lib/deps/0002-rpclib-use-the-real-boost-asio-namespace.patch b/host/lib/deps/0002-rpclib-use-the-real-boost-asio-namespace.patch new file mode 100644 index 000000000..01577ab99 --- /dev/null +++ b/host/lib/deps/0002-rpclib-use-the-real-boost-asio-namespace.patch @@ -0,0 +1,229 @@ +From d20d06421d11b824a1f250757ad9bb602fcccc35 Mon Sep 17 00:00:00 2001 +From: Andrej Rode +Date: Thu, 6 Apr 2017 15:54:59 -0700 +Subject: [PATCH 2/3] rpclib: use the real boost::asio namespace + +Signed-off-by: Andrej Rode +--- + include/rpc/detail/async_writer.h | 16 ++++++++-------- + include/rpc/detail/server_session.h | 10 +++++----- + lib/rpc/client.cc | 20 ++++++++++---------- + lib/rpc/detail/server_session.cc | 6 +++--- + lib/rpc/server.cc | 7 +++---- + 5 files changed, 29 insertions(+), 30 deletions(-) + +diff --git a/include/rpc/detail/async_writer.h b/include/rpc/detail/async_writer.h +index c3ecb02..a44cd29 100644 +--- a/include/rpc/detail/async_writer.h ++++ b/include/rpc/detail/async_writer.h +@@ -3,7 +3,7 @@ + #ifndef ASYNC_WRITER_H_HQIRH28I + #define ASYNC_WRITER_H_HQIRH28I + +-#include "asio.hpp" ++#include + #include "rpc/msgpack.hpp" + #include + #include +@@ -19,8 +19,8 @@ namespace detail { + //! \brief Common logic for classes that have a write queue with async writing. + class async_writer : public std::enable_shared_from_this { + public: +- async_writer(RPCLIB_ASIO::io_service *io, +- RPCLIB_ASIO::ip::tcp::socket socket) ++ async_writer(boost::asio::io_service *io, ++ boost::asio::ip::tcp::socket socket) + : socket_(std::move(socket)), write_strand_(*io), exit_(false) {} + + void do_write() { +@@ -31,8 +31,8 @@ public: + auto &item = write_queue_.front(); + // the data in item remains valid until the handler is called + // since it will still be in the queue physically until then. +- RPCLIB_ASIO::async_write( +- socket_, RPCLIB_ASIO::buffer(item.data(), item.size()), ++ boost::asio::async_write( ++ socket_, boost::asio::buffer(item.data(), item.size()), + write_strand_.wrap( + [this, self](std::error_code ec, std::size_t transferred) { + (void)transferred; +@@ -50,7 +50,7 @@ public: + if (exit_) { + LOG_INFO("Closing socket"); + socket_.shutdown( +- RPCLIB_ASIO::ip::tcp::socket::shutdown_both); ++ boost::asio::ip::tcp::socket::shutdown_both); + socket_.close(); + } + })); +@@ -68,8 +68,8 @@ public: + friend class rpc::client; + + protected: +- RPCLIB_ASIO::ip::tcp::socket socket_; +- RPCLIB_ASIO::strand write_strand_; ++ boost::asio::ip::tcp::socket socket_; ++ boost::asio::strand write_strand_; + std::atomic_bool exit_{false}; + bool exited_ = false; + std::mutex m_exit_; +diff --git a/include/rpc/detail/server_session.h b/include/rpc/detail/server_session.h +index 3b96d7d..963b082 100644 +--- a/include/rpc/detail/server_session.h ++++ b/include/rpc/detail/server_session.h +@@ -3,7 +3,7 @@ + #ifndef SESSION_H_5KG6ZMAB + #define SESSION_H_5KG6ZMAB + +-#include "asio.hpp" ++#include + #include + #include + +@@ -22,8 +22,8 @@ namespace detail { + + class server_session : public async_writer { + public: +- server_session(server *srv, RPCLIB_ASIO::io_service *io, +- RPCLIB_ASIO::ip::tcp::socket socket, ++ server_session(server *srv, boost::asio::io_service *io, ++ boost::asio::ip::tcp::socket socket, + std::shared_ptr disp, bool suppress_exceptions); + void start(); + +@@ -34,8 +34,8 @@ private: + + private: + server* parent_; +- RPCLIB_ASIO::io_service *io_; +- RPCLIB_ASIO::strand read_strand_; ++ boost::asio::io_service *io_; ++ boost::asio::strand read_strand_; + std::shared_ptr disp_; + RPCLIB_MSGPACK::unpacker pac_; + RPCLIB_MSGPACK::sbuffer output_buf_; +diff --git a/lib/rpc/client.cc b/lib/rpc/client.cc +index e5d0117..ef9048b 100644 +--- a/lib/rpc/client.cc ++++ b/lib/rpc/client.cc +@@ -10,15 +10,15 @@ + #include + #include + +-#include "asio.hpp" ++#include + #include + + #include "rpc/detail/async_writer.h" + #include "rpc/detail/dev_utils.h" + #include "rpc/detail/response.h" + +-using namespace RPCLIB_ASIO; +-using RPCLIB_ASIO::ip::tcp; ++using namespace boost::asio; ++using boost::asio::ip::tcp; + using namespace rpc::detail; + + namespace rpc { +@@ -36,14 +36,14 @@ struct client::impl { + is_connected_(false), + state_(client::connection_state::initial), + writer_(std::make_shared( +- &io_, RPCLIB_ASIO::ip::tcp::socket(io_))), ++ &io_, boost::asio::ip::tcp::socket(io_))), + timeout_(5000) { + pac_.reserve_buffer(default_buffer_size); + } + + void do_connect(tcp::resolver::iterator endpoint_iterator) { + LOG_INFO("Initiating connection."); +- RPCLIB_ASIO::async_connect( ++ boost::asio::async_connect( + writer_->socket_, endpoint_iterator, + [this](std::error_code ec, tcp::resolver::iterator) { + if (!ec) { +@@ -63,7 +63,7 @@ struct client::impl { + LOG_TRACE("do_read"); + constexpr std::size_t max_read_bytes = default_buffer_size; + writer_->socket_.async_read_some( +- RPCLIB_ASIO::buffer(pac_.buffer(), max_read_bytes), ++ boost::asio::buffer(pac_.buffer(), max_read_bytes), + // I don't think max_read_bytes needs to be captured explicitly + // (since it's constexpr), but MSVC insists. + [this, max_read_bytes](std::error_code ec, std::size_t length) { +@@ -103,10 +103,10 @@ struct client::impl { + pac_.reserve_buffer(max_read_bytes); + } + do_read(); +- } else if (ec == RPCLIB_ASIO::error::eof) { ++ } else if (ec == boost::asio::error::eof) { + LOG_WARN("The server closed the connection."); + state_ = client::connection_state::disconnected; +- } else if (ec == RPCLIB_ASIO::error::connection_reset) { ++ } else if (ec == boost::asio::error::connection_reset) { + // Yes, this should be connection_state::reset, + // but on windows, disconnection results in reset. May be + // asio bug, may be a windows socket pecularity. Should be +@@ -132,8 +132,8 @@ struct client::impl { + std::pair>; + + client *parent_; +- RPCLIB_ASIO::io_service io_; +- RPCLIB_ASIO::strand strand_; ++ boost::asio::io_service io_; ++ boost::asio::strand strand_; + std::atomic call_idx_; /// The index of the last call made + std::unordered_map ongoing_calls_; + std::string addr_; +diff --git a/lib/rpc/detail/server_session.cc b/lib/rpc/detail/server_session.cc +index 15239da..79cfd09 100644 +--- a/lib/rpc/detail/server_session.cc ++++ b/lib/rpc/detail/server_session.cc +@@ -13,8 +13,8 @@ namespace detail { + + static constexpr std::size_t default_buffer_size = rpc::constants::DEFAULT_BUFFER_SIZE; + +-server_session::server_session(server *srv, RPCLIB_ASIO::io_service *io, +- RPCLIB_ASIO::ip::tcp::socket socket, ++server_session::server_session(server *srv, boost::asio::io_service *io, ++ boost::asio::ip::tcp::socket socket, + std::shared_ptr disp, + bool suppress_exceptions) + : async_writer(io, std::move(socket)), +@@ -40,7 +40,7 @@ void server_session::do_read() { + auto self(shared_from_this()); + constexpr std::size_t max_read_bytes = default_buffer_size; + socket_.async_read_some( +- RPCLIB_ASIO::buffer(pac_.buffer(), default_buffer_size), ++ boost::asio::buffer(pac_.buffer(), default_buffer_size), + // I don't think max_read_bytes needs to be captured explicitly + // (since it's constexpr), but MSVC insists. + read_strand_.wrap([this, self, max_read_bytes](std::error_code ec, +diff --git a/lib/rpc/server.cc b/lib/rpc/server.cc +index f0b9b05..568da72 100644 +--- a/lib/rpc/server.cc ++++ b/lib/rpc/server.cc +@@ -6,8 +6,7 @@ + #include + #include + +-#include "asio.hpp" +-#include "format.h" ++#include + + #include "rpc/detail/dev_utils.h" + #include "rpc/detail/log.h" +@@ -16,8 +15,8 @@ + #include "rpc/detail/thread_group.h" + + using namespace rpc::detail; +-using RPCLIB_ASIO::ip::tcp; +-using namespace RPCLIB_ASIO; ++using boost::asio::ip::tcp; ++using namespace boost::asio; + + namespace rpc { + +-- +2.10.2 + diff --git a/host/lib/deps/0003-rpclib-add-boost-system-error_code-and-include-rpc-c.patch b/host/lib/deps/0003-rpclib-add-boost-system-error_code-and-include-rpc-c.patch new file mode 100644 index 000000000..f17e12452 --- /dev/null +++ b/host/lib/deps/0003-rpclib-add-boost-system-error_code-and-include-rpc-c.patch @@ -0,0 +1,104 @@ +From 6405741d1daab2a3e540571e1e7f9fd4b15be3d8 Mon Sep 17 00:00:00 2001 +From: Andrej Rode +Date: Thu, 6 Apr 2017 15:56:22 -0700 +Subject: [PATCH 3/3] rpclib: add boost::system::error_code and include + rpc/config.h + +Signed-off-by: Andrej Rode +--- + include/rpc/detail/async_writer.h | 2 +- + include/rpc/detail/response.h | 1 + + include/rpc/rpc_error.h | 1 + + lib/rpc/client.cc | 4 ++-- + lib/rpc/detail/server_session.cc | 2 +- + lib/rpc/server.cc | 2 +- + 6 files changed, 7 insertions(+), 5 deletions(-) + +diff --git a/include/rpc/detail/async_writer.h b/include/rpc/detail/async_writer.h +index a44cd29..941bb1d 100644 +--- a/include/rpc/detail/async_writer.h ++++ b/include/rpc/detail/async_writer.h +@@ -34,7 +34,7 @@ public: + boost::asio::async_write( + socket_, boost::asio::buffer(item.data(), item.size()), + write_strand_.wrap( +- [this, self](std::error_code ec, std::size_t transferred) { ++ [this, self](boost::system::error_code ec, std::size_t transferred) { + (void)transferred; + if (!ec) { + write_queue_.pop_front(); +diff --git a/include/rpc/detail/response.h b/include/rpc/detail/response.h +index 0f69bcb..96131b1 100644 +--- a/include/rpc/detail/response.h ++++ b/include/rpc/detail/response.h +@@ -6,6 +6,7 @@ + #include "rpc/detail/log.h" + #include "rpc/detail/make_unique.h" + #include "rpc/msgpack.hpp" ++#include "rpc/config.h" + + namespace rpc { + namespace detail { +diff --git a/include/rpc/rpc_error.h b/include/rpc/rpc_error.h +index 6ca62e0..81a5b2c 100644 +--- a/include/rpc/rpc_error.h ++++ b/include/rpc/rpc_error.h +@@ -6,6 +6,7 @@ + #include + + #include "rpc/msgpack.hpp" ++#include "rpc/config.h" + + namespace rpc { + +diff --git a/lib/rpc/client.cc b/lib/rpc/client.cc +index ef9048b..f4d6497 100644 +--- a/lib/rpc/client.cc ++++ b/lib/rpc/client.cc +@@ -45,7 +45,7 @@ struct client::impl { + LOG_INFO("Initiating connection."); + boost::asio::async_connect( + writer_->socket_, endpoint_iterator, +- [this](std::error_code ec, tcp::resolver::iterator) { ++ [this](boost::system::error_code ec, tcp::resolver::iterator) { + if (!ec) { + std::unique_lock lock(mut_connection_finished_); + LOG_INFO("Client connected to {}:{}", addr_, port_); +@@ -66,7 +66,7 @@ struct client::impl { + boost::asio::buffer(pac_.buffer(), max_read_bytes), + // I don't think max_read_bytes needs to be captured explicitly + // (since it's constexpr), but MSVC insists. +- [this, max_read_bytes](std::error_code ec, std::size_t length) { ++ [this, max_read_bytes](boost::system::error_code ec, std::size_t length) { + if (!ec) { + LOG_TRACE("Read chunk of size {}", length); + pac_.buffer_consumed(length); +diff --git a/lib/rpc/detail/server_session.cc b/lib/rpc/detail/server_session.cc +index 79cfd09..3f1ed48 100644 +--- a/lib/rpc/detail/server_session.cc ++++ b/lib/rpc/detail/server_session.cc +@@ -43,7 +43,7 @@ void server_session::do_read() { + boost::asio::buffer(pac_.buffer(), default_buffer_size), + // I don't think max_read_bytes needs to be captured explicitly + // (since it's constexpr), but MSVC insists. +- read_strand_.wrap([this, self, max_read_bytes](std::error_code ec, ++ read_strand_.wrap([this, self, max_read_bytes](boost::system::error_code ec, + std::size_t length) { + if (!ec) { + pac_.buffer_consumed(length); +diff --git a/lib/rpc/server.cc b/lib/rpc/server.cc +index 568da72..4facb93 100644 +--- a/lib/rpc/server.cc ++++ b/lib/rpc/server.cc +@@ -37,7 +37,7 @@ struct server::impl { + suppress_exceptions_(false) {} + + void start_accept() { +- acceptor_.async_accept(socket_, [this](std::error_code ec) { ++ acceptor_.async_accept(socket_, [this](boost::system::error_code ec) { + if (!ec) { + LOG_INFO("Accepted connection."); + auto s = std::make_shared( +-- +2.10.2 + diff --git a/host/lib/deps/CMakeLists.txt b/host/lib/deps/CMakeLists.txt new file mode 100644 index 000000000..106f2cd19 --- /dev/null +++ b/host/lib/deps/CMakeLists.txt @@ -0,0 +1,18 @@ +# +# Copyright 2017 Ettus Research (National Instruments) +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +# + +ADD_SUBDIRECTORY(rpclib) diff --git a/host/lib/deps/import_rpclib.py b/host/lib/deps/import_rpclib.py new file mode 100755 index 000000000..2efd29e60 --- /dev/null +++ b/host/lib/deps/import_rpclib.py @@ -0,0 +1,156 @@ +#!/usr/bin/env python +# +# Copyright 2017 Ettus Research (National Instruments) +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . +# +""" +Tool to import external dependency rpclib into UHD tree +""" + +import argparse +from distutils.dir_util import copy_tree +import os +import re +import shutil +import subprocess +import tempfile + +from mako.template import Template + +IMPORTANT_FILES = [ + "lib", + "include", + "LICENSE.md", + "README.md", + "CHANGELOG.md" +] + +REPLACE_EXPR = [ + ("RPCLIB_ASIO", "boost::asio"), + ("\"asio.hpp\"", ""), + ("std::error_code", "boost::system::error_code") +] + + +def fix_naming(workdir): + """ + replace all the things + """ + for root, dirs, files in os.walk(workdir): + for cur_file in files: + if re.match(".*[hc](?:c?|\.in)|inl",cur_file): + new_file = tempfile.NamedTemporaryFile() + with new_file as new: + with open(os.path.join(root,cur_file), "r") as old: + for line in old: + for repl in REPLACE_EXPR: + line = line.replace(*repl) + new.write(line) + new.truncate() + shutil.copyfile(new_file.name, os.path.join(root, cur_file)) + +def extract_rpclib_version(rpclib_root): + """ + match version definition in rpclib cmakelists + """ + with open(os.path.join(rpclib_root, "CMakeLists.txt")) as rpclib_cmake: + version_dict = {} + for line in rpclib_cmake: + version_match =re.match("^.*RPCLIB_VERSION_(?PMAJOR|MINOR|PATCH) (?P[0-9]+).*$", line) + if version_match: + version_dict[version_match.group("which").lower()] = int(version_match.group("number")) + if not set(version_dict.keys()).issuperset(set(["major", "minor", "patch"])): + raise Exception("couldn't find right version definitions in CMakeLists.txt") + return (version_dict["major"], version_dict["minor"], version_dict["patch"]) + + +def copy_important_files(target_root, rpclib_root): + """ + copy files/subdirs we consider important + """ + for rpc_file in os.listdir(rpclib_root): + if rpc_file in IMPORTANT_FILES: + if os.path.isdir(os.path.join(rpclib_root, rpc_file)): + copy_tree( + os.path.join(rpclib_root, rpc_file), + os.path.join(target_root, rpc_file) + ) + else: + shutil.copyfile( + os.path.join(rpclib_root, rpc_file), + os.path.join(target_root, rpc_file) + ) + + +def patch_rpclib(rpclib_root): + """ + applies all *.patch files in the same directory as the script + """ + curr_dir = os.path.dirname(os.path.realpath(__file__)) + for rpc_patch in (patch for patch in sorted(os.listdir(curr_dir)) + if patch.endswith("patch")): + print("patching with: {0}".format(rpc_patch)) + patch = open(os.path.join(curr_dir, rpc_patch), "r") + patch_proc = subprocess.Popen(['patch', '--quiet', '-p1'], stdin=patch, cwd=rpclib_root) + + +def extract_rpclib(args): + """ + THE extraction function + """ + + workdir = tempfile.mkdtemp() + rpclib_root = args.rpclib_root + new_rpclib_root = tempfile.mkdtemp() + copy_tree(rpclib_root, new_rpclib_root) + patch_rpclib(new_rpclib_root) + copy_important_files(workdir, new_rpclib_root) + version = extract_rpclib_version(new_rpclib_root) + shutil.rmtree(new_rpclib_root) + cmake_template = Template( + filename=os.path.join(os.path.dirname(os.path.realpath(__file__)), "rpc_CMakeLists.txt")) + real_cmake_file = cmake_template.render( + rpclib_major_version=version[0], + rpclib_minor_version=version[1], + rpclib_patch_version=version[2] + ) + with open(os.path.join(workdir, "CMakeLists.txt"), "w") as cmake_file: + cmake_file.write(real_cmake_file) + cmake_file.truncate() + fix_naming(workdir) + copy_tree(workdir, args.rpclib_target, update=True) + shutil.rmtree(workdir) + + +def parse_args(): + """ + parse cmdline arguments + """ + parser = argparse.ArgumentParser() + parser.add_argument("rpclib_root") + parser.add_argument('rpclib_target') + return parser.parse_args() + + +def main(): + """ + Execute this tool + """ + args = parse_args() + extract_rpclib(args) + return True + +if __name__ == "__main__": + exit(not main()) diff --git a/host/lib/deps/rpc_CMakeLists.txt b/host/lib/deps/rpc_CMakeLists.txt new file mode 100644 index 000000000..1ebb1b69c --- /dev/null +++ b/host/lib/deps/rpc_CMakeLists.txt @@ -0,0 +1,32 @@ +CMAKE_MINIMUM_REQUIRED(VERSION 3.0.0) +PROJECT(UHD_RPCLIB CXX) + +SET(RPCLIB_DEFAULT_BUFFER_SIZE "1024 << 10" CACHE STRING "Default buffer size") + +SET(RPCLIB_VERISION_MAJOR ${rpclib_major_version}) +SET(RPCLIB_VERSION_MINOR ${rpclib_minor_version}) +SET(RPCLIB_VERSION_PATCH ${rpclib_patch_version}) + +CONFIGURE_FILE( + ${"${CMAKE_CURRENT_SOURCE_DIR}/include/rpc/version.h.in"} + ${"${CMAKE_CURRENT_BINARY_DIR}/version.h"}) + +CONFIGURE_FILE( + ${"${CMAKE_CURRENT_SOURCE_DIR}/include/rpc/config.h.in"} + ${"${CMAKE_CURRENT_BINARY_DIR}/config.h"}) + +INCLUDE_DIRECTORIES(include) +INCLUDE_DIRECTORIES(include/rpc) +ADD_LIBRARY(uhd_rpclib OBJECT + lib/rpc/dispatcher.cc + lib/rpc/server.cc + lib/rpc/client.cc + lib/rpc/this_handler.cc + lib/rpc/this_session.cc + lib/rpc/this_server.cc + lib/rpc/rpc_error.cc + lib/rpc/detail/server_session.cc + lib/rpc/detail/response.cc + lib/rpc/detail/client_error.cc +) +SET_PROPERTY(TARGET uhd_rpclib PROPERTY POSITION_INDEPENDENT_CODE ON) diff --git a/host/lib/deps/rpclib/CHANGELOG.md b/host/lib/deps/rpclib/CHANGELOG.md new file mode 100644 index 000000000..58b137184 --- /dev/null +++ b/host/lib/deps/rpclib/CHANGELOG.md @@ -0,0 +1,40 @@ +# Changelog + +### 2.0.0 + +This is an interface-breaking release (hence the major version number increase). + +Released on 2017-04-02. + +Changes since 1.0.0: + + * **Added C++11 compatibility** (huge thanks to Github user mbr0wn!) + * Added global timeout for blocking calls in the client + * Replaced the internal pimpl_ptr with std::unique_ptr for better stability + * Fixed a build problem with newer clang versions + * Contains some preliminary VS2013 work (but it's very far from ready) + + +### 1.0.0 + +This is the first, complete release of rpclib. + +Released on 2017-03-11. + +Changes since 1.0.0-preview: + + * A buffer overflow bug was fixed in the server + * New unit tests were added + * CMake no longer assumes libc++ when clang is used + * Documentation fixes + * Added the ability to pass extra flags to the build without changing the + CMakeLists.txt + * Fixed requiring RPCLIB\_MSGPACK macro when not using Findrpclib.cmake + * Created [conan](https://conan.io) package + * A [benchmark suite](https://github.com/rpclib/benchmarks) was implemented + +### 1.0.0-preview1 + +This is the first public release of rpclib! This release is a preview which means that the actual 1.0.0 will be similar, but hopefully improved. Any feedback is welcome! + +Released on 2016-08-28. diff --git a/host/lib/deps/rpclib/CMakeLists.txt b/host/lib/deps/rpclib/CMakeLists.txt new file mode 100644 index 000000000..a1298a464 --- /dev/null +++ b/host/lib/deps/rpclib/CMakeLists.txt @@ -0,0 +1,32 @@ +CMAKE_MINIMUM_REQUIRED(VERSION 3.0.0) +PROJECT(UHD_RPCLIB CXX) + +SET(RPCLIB_DEFAULT_BUFFER_SIZE "1024 << 10" CACHE STRING "Default buffer size") + +SET(RPCLIB_VERISION_MAJOR 1) +SET(RPCLIB_VERSION_MINOR 0) +SET(RPCLIB_VERSION_PATCH 0) + +CONFIGURE_FILE( + ${CMAKE_CURRENT_SOURCE_DIR}/include/rpc/version.h.in + ${CMAKE_CURRENT_BINARY_DIR}/version.h) + +CONFIGURE_FILE( + ${CMAKE_CURRENT_SOURCE_DIR}/include/rpc/config.h.in + ${CMAKE_CURRENT_BINARY_DIR}/config.h) + +INCLUDE_DIRECTORIES(include) +INCLUDE_DIRECTORIES(include/rpc) +ADD_LIBRARY(uhd_rpclib OBJECT + lib/rpc/dispatcher.cc + lib/rpc/server.cc + lib/rpc/client.cc + lib/rpc/this_handler.cc + lib/rpc/this_session.cc + lib/rpc/this_server.cc + lib/rpc/rpc_error.cc + lib/rpc/detail/server_session.cc + lib/rpc/detail/response.cc + lib/rpc/detail/client_error.cc +) +SET_PROPERTY(TARGET uhd_rpclib PROPERTY POSITION_INDEPENDENT_CODE ON) diff --git a/host/lib/deps/rpclib/LICENSE.md b/host/lib/deps/rpclib/LICENSE.md new file mode 100644 index 000000000..870bae90c --- /dev/null +++ b/host/lib/deps/rpclib/LICENSE.md @@ -0,0 +1,46 @@ +# License terms for humans + +The following is a friendly explanation of the license. For legal purposes, the license below is +what matters, not this explanation. + +This library is licensed under the *MIT license*. What this means for you: + + * You can use it freely in any form you want + * You can sell software that uses it + * You can sell modified versions of it + * You **do not** need to apply the same license to software you develop with it + * You **do not** need to apply the same license for modified versions + * You **do not** have to attribute usage. + +## But + + * There is no guarantee. None. At all. I'm also not obligated to work on a particular issue, or + even respond to them (though I'll do my best, I promise). + +## Also + +This is not part of the license, but if you want to be nice and give back, please let me know +if you are using the library for anything serious. You can also let the world know that you are using it. + + +# The MIT License + +Copyright (c) 2015-2017, Tamás Szelei + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/host/lib/deps/rpclib/README.md b/host/lib/deps/rpclib/README.md new file mode 100644 index 000000000..2404a18f9 --- /dev/null +++ b/host/lib/deps/rpclib/README.md @@ -0,0 +1,97 @@ + +# rpclib ![MIT](https://img.shields.io/badge/license-MIT-blue.svg) [![Build Status](https://travis-ci.org/rpclib/rpclib.svg?branch=master)](https://travis-ci.org/rpclib/rpclib) [![Build status](https://ci.appveyor.com/api/projects/status/9lft2tlamcox8epq?svg=true)](https://ci.appveyor.com/project/sztomi/callme) [![Coverage Status](https://coveralls.io/repos/github/rpclib/rpclib/badge.svg)](https://coveralls.io/github/rpclib/rpclib?branch=dev) ![Coverity](https://scan.coverity.com/projects/7259/badge.svg?flat=1) [![Gitter](https://img.shields.io/gitter/room/nwjs/nw.js.svg?maxAge=2592000)](https://gitter.im/rpclib/Lobby) + +`rpclib` is a RPC library for C++, providing both a client and server implementation. It is built using modern C++14, and as such, requires a recent compiler. Main highlights: + + * Expose functions of your program to be called via RPC (from any language + implementing msgpack-rpc) + * Call functions through RPC (of programs written in any language) + * No IDL to learn + * No code generation step to integrate in your build, just C++ + +# Look&feel + +## Server + +```cpp +#include +#include "rpc/server.h" + +void foo() { + std::cout << "foo was called!" << std::endl; +} + +int main(int argc, char *argv[]) { + // Creating a server that listens on port 8080 + rpc::server srv(8080); + + // Binding the name "foo" to free function foo. + // note: the signature is automatically captured + srv.bind("foo", &foo); + + // Binding a lambda function to the name "add". + srv.bind("add", [](int a, int b) { + return a + b; + }); + + // Run the server loop. + srv.run(); + + return 0; +} +``` + +When `srv.run()` is called, `rpclib` starts the server loop which listens to incoming connections +and tries to dispatch calls to the bound functions. The functions are called from the thread where +`run` was called from. There is also `async_run` that spawns worker threads and returns +immediately. + +## Client + +```cpp +#include +#include "rpc/client.h" + +int main() { + // Creating a client that connects to the localhost on port 8080 + rpc::client client("127.0.0.1", 8080); + + // Calling a function with paramters and converting the result to int + auto result = client.call("add", 2, 3).as(); + std::cout << "The result is: " << result << std::endl; + return 0; +} +``` + +# Status + +All planned 1.0.0 features are done and tested; the current state is production-ready. + +# Who uses rpclib? + +This list is updated as I learn about more people using the library; let me +know if you don't want your project listed here. + + * [Microsoft AirSim](https://github.com/Microsoft/AirSim) + +# Thanks + +`rpclib` builds on the efforts of fantastic C++ projects. In no particular order: + + * [MessagePack implementation for C and C++](https://github.com/msgpack/msgpack-c) by Takatoshi Kondo ([website](http://msgpack.org/)) + * [asio](https://github.com/chriskohlhoff/asio) by Christopher Kohlhoff ([website](http://think-async.com/Asio)) + * [cppformat](https://github.com/fmtlib/fmt) (now renamed `fmtlib`, by Victor Zverovich ([website](http://fmtlib.net)) + * [googletest](https://github.com/google/googletest) by Google + * [wheels](https://github.com/rmartinho/wheels) by Martinho Fernandes + +Shoutouts to + + * [Appveyor](https://www.appveyor.com/) + * [Travis CI](https://travis-ci.org) + * [Coveralls.io](https://coveralls.io/) + * [Coverity](http://www.coverity.com) + * [ASan & TSan](https://github.com/google/sanitizers) helped spotting and resolving many bugs. + + + + diff --git a/host/lib/deps/rpclib/include/rpc/client.h b/host/lib/deps/rpclib/include/rpc/client.h new file mode 100644 index 000000000..624607641 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/client.h @@ -0,0 +1,141 @@ +#pragma once + +#include +#include + +#include "rpc/config.h" +#include "rpc/detail/log.h" +#include "rpc/detail/pimpl.h" +#include "rpc/msgpack.hpp" + +namespace rpc { + +//! \brief Implements a client that connects to a msgpack-rpc server and is +//! able to call functions synchronously or asynchronously. This is the main +//! interfacing point for implementing client applications. +//! +//! Use this class to connect to msgpack-rpc servers and call their exposed +//! functions. This class supports calling functions synchronously and +//! asynchronously. When the client object is created, it initiates connecting +//! to the given server asynchronically and disconnects when it is destroyed. +class client { +public: + //! \brief Constructs a client. + //! + //! When a client is constructed, it initiates a connection + //! asynchronically. This means that it will not block while the connection + //! is established. However, when the first call is performed, it *might* + //! block if the connection was not already established. + //! + //! \param addr The address of the server to connect to. This might be an + //! IP address or a host name, too. + //! \param port The port on the server to connect to. + client(std::string const &addr, uint16_t port); + + //! \cond DOXYGEN_SKIP + client(client const &) = delete; + //! \endcond + + //! \brief Destructor. + //! + //! During destruction, the connection to the server is gracefully closed. + //! This means that any outstanding reads and writes are completed first. + ~client(); + + //! \brief Calls a function with the given name and arguments (if any). + //! + //! \param func_name The name of the function to call on the server. + //! \param args A variable number of arguments to pass to the called + //! function. + //! + //! \tparam Args The types of the arguments. Each type in this parameter + //! pack have to be serializable by msgpack. + //! + //! \returns A RPCLIB_MSGPACK::object containing the result of the function (if + //! any). To obtain a typed value, use the msgpack API. + //! + //! \throws rpc::rpc_error if the server responds with an error. + template + RPCLIB_MSGPACK::object_handle call(std::string const &func_name, Args... args); + + //! \brief Calls a function asynchronously with the given name and + //! arguments. + //! + //! A call is performed asynchronously in the context of the client, i.e. + //! this is not to be confused with parallel execution on the server. + //! This function differs from `call` in that it does not wait for the + //! result of the function. Instead, it returns a std::future that + //! can be used to retrieve the result later. + //! + //! \param func_name The name of the function to call. + //! \param args The arguments to pass to the function. + //! + //! \tparam Args The types of the arguments. + //! + //! \returns A std::future, possibly holding a future result + //! (which is a RPCLIB_MSGPACK::object). + template + std::future async_call(std::string const &func_name, + Args... args); + + //! \brief Sends a notification with the given name and arguments (if any). + //! + //! Notifications are a special kind of calls. They can be used to notify + //! the server, while not expecting a response. In `rpclib` terminology, + //! a notification is like an `async_call` without a return value. + //! + //! \param func_name The name of the notification to call. + //! \param args The arguments to pass to the function. + //! \tparam Args THe types of the arguments. + //! + //! \note This function returns immediately (possibly before the + //! notification is written to the socket). + template + void send(std::string const &func_name, Args... args); + + //! \brief Returns the timeout setting of this client in milliseconds. + //! + //! The timeout is applied to synchronous calls. If the timeout expires + //! without receiving a response from the server, rpc::timeout exceptio + //! will be thrown. + //! + //! \note The timeout has no effect on async calls. For those, + //! the preferred timeout mechanism remains using std::future. + //! + //! The default value for timeout is 5000ms (5 seconds). + uint64_t get_timeout() const; + + //! \brief Sets the timeout for global calls. For more information, + //! see client::get_timeout(). + void set_timeout(uint64_t value); + + //! \brief Enum representing the connection states of the client. + enum class connection_state { initial, connected, disconnected, reset }; + + //! \brief Returns the current connection state. + connection_state get_connection_state() const; + + //! \brief Waits for the completion of all ongoing calls. + void wait_all_responses(); + +private: + //! \brief Type of a promise holding a future response. + using rsp_promise = std::promise; + + enum class request_type { call = 0, notification = 2 }; + + void wait_conn(); + void post(std::shared_ptr buffer, int idx, + std::string const& func_name, + std::shared_ptr p); + void post(RPCLIB_MSGPACK::sbuffer *buffer); + int get_next_call_idx(); + RPCLIB_NORETURN void throw_timeout(std::string const& func_name); + +private: + static constexpr double buffer_grow_factor = 1.8; + RPCLIB_DECLARE_PIMPL() +}; +} + +#include "rpc/client.inl" diff --git a/host/lib/deps/rpclib/include/rpc/client.inl b/host/lib/deps/rpclib/include/rpc/client.inl new file mode 100644 index 000000000..4ff33294d --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/client.inl @@ -0,0 +1,65 @@ +namespace rpc { + +template +RPCLIB_MSGPACK::object_handle client::call(std::string const &func_name, + Args... args) { + RPCLIB_CREATE_LOG_CHANNEL(client) + auto future = async_call(func_name, std::forward(args)...); + auto wait_result = future.wait_for(std::chrono::milliseconds(get_timeout())); + + if (wait_result == std::future_status::timeout) { + throw_timeout(func_name); + } + + return future.get(); +} + +template +std::future +client::async_call(std::string const &func_name, Args... args) { + RPCLIB_CREATE_LOG_CHANNEL(client) + wait_conn(); + using RPCLIB_MSGPACK::object; + LOG_DEBUG("Calling {}", func_name); + + auto args_obj = std::make_tuple(args...); + const int idx = get_next_call_idx(); + auto call_obj = + std::make_tuple(static_cast(client::request_type::call), idx, + func_name, args_obj); + + auto buffer = std::make_shared(); + RPCLIB_MSGPACK::pack(*buffer, call_obj); + + // TODO: Change to move semantics when asio starts supporting move-only + // handlers in post(). [sztomi, 2016-02-14] + auto p = std::make_shared>(); + auto ft = p->get_future(); + + post(buffer, idx, func_name, p); + + return ft; +} + +//! \brief Sends a notification with the given name and arguments (if any). +//! \param func_name The name of the notification to call. +//! \param args The arguments to pass to the function. +//! \note This function returns when the notification is written to the +//! socket. +//! \tparam Args THe types of the arguments. +template +void client::send(std::string const &func_name, Args... args) { + RPCLIB_CREATE_LOG_CHANNEL(client) + LOG_DEBUG("Sending notification {}", func_name); + + auto args_obj = std::make_tuple(args...); + auto call_obj = std::make_tuple( + static_cast(client::request_type::notification), func_name, + args_obj); + + auto buffer = new RPCLIB_MSGPACK::sbuffer; + RPCLIB_MSGPACK::pack(*buffer, call_obj); + + post(buffer); +} +} diff --git a/host/lib/deps/rpclib/include/rpc/compatibility.h b/host/lib/deps/rpclib/include/rpc/compatibility.h new file mode 100644 index 000000000..19baa201c --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/compatibility.h @@ -0,0 +1,20 @@ +#pragma once + +#ifndef COMPATIBILITY_H_PODKJ3 +#define COMPATIBILITY_H_PODKJ3 + +#ifndef _MSC_VER + +#define RPCLIB_NORETURN [[noreturn]] +#define RPCLIB_CONSTEXPR constexpr +#define RPCLIB_FINAL final + +#else + +#define RPCLIB_NORETURN __declspec(noreturn) +#define RPCLIB_CONSTEXPR const // bad replacement, but gets the job done +#define RPCLIB_FINAL + +#endif // !_MSC_VER + +#endif // COMPATIBILITY_H_PODKJ3 diff --git a/host/lib/deps/rpclib/include/rpc/config.h b/host/lib/deps/rpclib/include/rpc/config.h new file mode 100644 index 000000000..738ab3956 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/config.h @@ -0,0 +1,34 @@ +#pragma once + +#ifndef CONFIG_H_L7IVDSPZ +#define CONFIG_H_L7IVDSPZ + +#include +#include + +#include "rpc/compatibility.h" + +namespace rpc +{ + +//! \brief +struct constants RPCLIB_FINAL { + static RPCLIB_CONSTEXPR std::size_t DEFAULT_BUFFER_SIZE = 1024 << 10; + static RPCLIB_CONSTEXPR std::uint16_t DEFAULT_PORT = 8080; +}; + +} /* rpc */ + +// This define allows the end user to replace the msgpack dependency. +// To do so, one has to delete the msgpack headers that are +// in the rpclib directory. The other messagepack headers don't +// need to be stored in place of the others. Finally, the RPCLIB_MSGPACK +// macro has to be changed to the namespace name that this new +// msgpack uses (usually "msgpack", unless it is changed manually) +#ifndef RPCLIB_MSGPACK +#define RPCLIB_MSGPACK clmdep_msgpack +#endif /* ifndef RPCLIB_MSGPACK */ + +#define RPCLIB_CXX_STANDARD 11 + +#endif /* end of include guard: CONFIG_H_L7IVDSPZ */ diff --git a/host/lib/deps/rpclib/include/rpc/config.h.in b/host/lib/deps/rpclib/include/rpc/config.h.in new file mode 100644 index 000000000..fc36dfde3 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/config.h.in @@ -0,0 +1,33 @@ +#pragma once + +#ifndef CONFIG_H_L7IVDSPZ +#define CONFIG_H_L7IVDSPZ + +#include + +#include "rpc/compatibility.h" + +namespace rpc +{ + +//! \brief +struct constants RPCLIB_FINAL { + static RPCLIB_CONSTEXPR std::size_t DEFAULT_BUFFER_SIZE = @RPCLIB_DEFAULT_BUFFER_SIZE@; + static RPCLIB_CONSTEXPR std::uint16_t DEFAULT_PORT = @RPCLIB_DEFAULT_PORT@; +}; + +} /* rpc */ + +// This define allows the end user to replace the msgpack dependency. +// To do so, one has to delete the msgpack headers that are +// in the rpclib directory. The other messagepack headers don't +// need to be stored in place of the others. Finally, the RPCLIB_MSGPACK +// macro has to be changed to the namespace name that this new +// msgpack uses (usually "msgpack", unless it is changed manually) +#ifndef RPCLIB_MSGPACK +#define RPCLIB_MSGPACK clmdep_msgpack +#endif /* ifndef RPCLIB_MSGPACK */ + +#define RPCLIB_CXX_STANDARD @RPCLIB_CXX_STANDARD@ + +#endif /* end of include guard: CONFIG_H_L7IVDSPZ */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/all.h b/host/lib/deps/rpclib/include/rpc/detail/all.h new file mode 100644 index 000000000..5a060bfb0 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/all.h @@ -0,0 +1,26 @@ +#pragma once + +#ifndef ALL_H_H8MAAYCG +#define ALL_H_H8MAAYCG + +#include "rpc/detail/invoke.h" +#include "rpc/detail/if.h" +#include "rpc/detail/bool.h" + +namespace rpc { +namespace detail { + +//! \brief This type can be used to check multiple conditions. +//! It will be true_type if all its arguments are true. +template struct all : true_ {}; + +template +struct all + : if_, false_> {}; + +} +} + + + +#endif /* end of include guard: ALL_H_H8MAAYCG */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/any.h b/host/lib/deps/rpclib/include/rpc/detail/any.h new file mode 100644 index 000000000..09ffb81cf --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/any.h @@ -0,0 +1,21 @@ +#pragma once + +#ifndef ANY_H_4G3QUOAN +#define ANY_H_4G3QUOAN + +#include "rpc/detail/invoke.h" +#include "rpc/detail/if.h" +#include "rpc/detail/bool.h" + +namespace rpc { +namespace detail { + +//! \brief Evaluates to true_type if any of its arguments is true_type. +template struct any : false_ {}; + +template +struct any : if_> {}; +} +} + +#endif /* end of include guard: ANY_H_4G3QUOAN */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/async_writer.h b/host/lib/deps/rpclib/include/rpc/detail/async_writer.h new file mode 100644 index 000000000..941bb1d8f --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/async_writer.h @@ -0,0 +1,86 @@ +#pragma once + +#ifndef ASYNC_WRITER_H_HQIRH28I +#define ASYNC_WRITER_H_HQIRH28I + +#include +#include "rpc/msgpack.hpp" +#include +#include +#include +#include + +namespace rpc { + +class client; + +namespace detail { + +//! \brief Common logic for classes that have a write queue with async writing. +class async_writer : public std::enable_shared_from_this { +public: + async_writer(boost::asio::io_service *io, + boost::asio::ip::tcp::socket socket) + : socket_(std::move(socket)), write_strand_(*io), exit_(false) {} + + void do_write() { + if (exit_) { + return; + } + auto self(shared_from_this()); + auto &item = write_queue_.front(); + // the data in item remains valid until the handler is called + // since it will still be in the queue physically until then. + boost::asio::async_write( + socket_, boost::asio::buffer(item.data(), item.size()), + write_strand_.wrap( + [this, self](boost::system::error_code ec, std::size_t transferred) { + (void)transferred; + if (!ec) { + write_queue_.pop_front(); + if (write_queue_.size() > 0) { + if (!exit_) { + do_write(); + } + } + } else { + LOG_ERROR("Error while writing to socket: {}", ec); + } + + if (exit_) { + LOG_INFO("Closing socket"); + socket_.shutdown( + boost::asio::ip::tcp::socket::shutdown_both); + socket_.close(); + } + })); + } + + void write(RPCLIB_MSGPACK::sbuffer &&data) { + write_queue_.push_back(std::move(data)); + if (write_queue_.size() > 1) { + return; // there is an ongoing write chain so don't start another + } + + do_write(); + } + + friend class rpc::client; + +protected: + boost::asio::ip::tcp::socket socket_; + boost::asio::strand write_strand_; + std::atomic_bool exit_{false}; + bool exited_ = false; + std::mutex m_exit_; + std::condition_variable cv_exit_; + +private: + std::deque write_queue_; + RPCLIB_CREATE_LOG_CHANNEL(async_writer) +}; + +} /* detail */ +} /* rpc */ + +#endif /* end of include guard: ASYNC_WRITER_H_HQIRH28I */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/bool.h b/host/lib/deps/rpclib/include/rpc/detail/bool.h new file mode 100644 index 000000000..65f37d371 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/bool.h @@ -0,0 +1,21 @@ +#pragma once + +#ifndef BOOL_H_QLG6S5XZ +#define BOOL_H_QLG6S5XZ + +#include "rpc/detail/constant.h" + +namespace rpc { +namespace detail { + +template +using bool_ = constant; + +using true_ = bool_; + +using false_ = bool_; + +} +} + +#endif /* end of include guard: BOOL_H_QLG6S5XZ */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/call.h b/host/lib/deps/rpclib/include/rpc/detail/call.h new file mode 100644 index 000000000..b5c9bdce0 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/call.h @@ -0,0 +1,92 @@ +#pragma once + +#ifndef CALL_H_ZXFACADH +#define CALL_H_ZXFACADH + +#include +#include "rpc/detail/func_tools.h" +#include "rpc/detail/invoke.h" +#include "rpc/detail/is_specialization_of.h" + +namespace rpc { +namespace detail { + +//! \brief Calls a functor with argument provided directly +template +auto call(Functor f, Arg &&arg) + -> decltype(f(std::forward(arg))) +{ + return f(std::forward(arg)); +} + + +// Default behaviour is to assume C++11, overriding RPCLIB_CXX_STANDARD can use +// newer standards: +#if RPCLIB_CXX_STANDARD >= 14 + +template +decltype(auto) call_helper(Functor func, std::tuple &¶ms, + std::index_sequence) { + return func(std::get(params)...); +} + +//! \brief Calls a functor with arguments provided as a tuple +template +decltype(auto) call(Functor f, std::tuple &args) { + return call_helper(f, std::forward>(args), + std::index_sequence_for{}); +} + +#else + +// N is number of arguments left in tuple to unpack + +template +struct call_helper +{ + template + static auto call( + Functor f, + std::tuple& args_t, + ArgsF&&... args_f) + -> decltype(call_helper::call( + f, args_t, std::get(args_t), + std::forward(args_f)...)) + { + return call_helper::call( + f, + args_t, + std::get(args_t), + std::forward(args_f)... + ); + } +}; + +template <> +struct call_helper<0> +{ + template + static auto call( + Functor f, + std::tuple&, + ArgsF&&... args_f) + -> decltype(f(std::forward(args_f)...)) + { + return f(std::forward(args_f)...); + } +}; + +//! \brief Calls a functor with arguments provided as a tuple +template +auto call(Functor f, std::tuple& args_t) + -> decltype(call_helper::call(f, args_t)) +{ + return call_helper::call(f, args_t); +} + +#endif + +} +} + +#endif /* end of include guard: CALL_H_ZXFACADH */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/client_error.h b/host/lib/deps/rpclib/include/rpc/detail/client_error.h new file mode 100644 index 000000000..73edd2ebe --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/client_error.h @@ -0,0 +1,39 @@ +#pragma once + +#ifndef RPC_CLIENT_ERROR_H +#define RPC_CLIENT_ERROR_H + +#include +#include + +namespace rpc { +namespace detail { + +//! \brief Describes an error that is the result of a connected client +//! doing something unexpected (e.g. calling a function that does not exist, +//! wrong number of arguments, etc.) +class client_error : public std::exception { +public: + //! \brief Error codes used for signaling back to clients. These are used + //! to produce google-able error messages (since the msgpack-rpc protocol + //! does not define error handling in any more detail than sending an + //! object). + //! \note Care must be taken to keep these codes stable even between major + //! versions. + enum class code : uint16_t { + no_such_function = 1, + wrong_arity = 2, + protocol_error = 4 + }; + + client_error(code c, const std::string &msg); + + const char *what() const noexcept; + +private: + std::string what_; +}; +} +} + +#endif // RPC_CLIENT_ERROR_H diff --git a/host/lib/deps/rpclib/include/rpc/detail/constant.h b/host/lib/deps/rpclib/include/rpc/detail/constant.h new file mode 100644 index 000000000..1c373b3a2 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/constant.h @@ -0,0 +1,17 @@ +#pragma once + +#ifndef CONSTANT_H_5CXUYJEW +#define CONSTANT_H_5CXUYJEW + +#include + +namespace rpc { +namespace detail { + +template +struct constant : std::integral_constant {}; + +} +} + +#endif /* end of include guard: CONSTANT_H_5CXUYJEW */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/dev_utils.h b/host/lib/deps/rpclib/include/rpc/detail/dev_utils.h new file mode 100644 index 000000000..325320970 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/dev_utils.h @@ -0,0 +1,21 @@ +#pragma once + +#ifndef DEV_UTILS_H_JQSWE2OS +#define DEV_UTILS_H_JQSWE2OS + +#ifdef RPCLIB_LINUX +#include "pthread.h" +#endif + +namespace rpc { +namespace detail { +inline void name_thread(std::string const &name) { + (void)name; +#ifdef RPCLIB_LINUX + pthread_setname_np(pthread_self(), name.c_str()); +#endif +} +} /* detail */ +} /* rpc */ + +#endif /* end of include guard: DEV_UTILS_H_JQSWE2OS */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/func_tools.h b/host/lib/deps/rpclib/include/rpc/detail/func_tools.h new file mode 100644 index 000000000..4f18e482d --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/func_tools.h @@ -0,0 +1,26 @@ +#pragma once + +#ifndef FUNC_TOOLS_H_9FNRD4G2 +#define FUNC_TOOLS_H_9FNRD4G2 + +#include "rpc/detail/invoke.h" +#include "rpc/detail/all.h" +#include "rpc/detail/any.h" + +namespace rpc { +namespace detail { + + +enum class enabled {}; + +template +using enable_if = invoke::value, enabled>>; + +template +using disable_if = invoke::value, enabled>>; + + +} +} + +#endif /* end of include guard: FUNC_TOOLS_H_9FNRD4G2 */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/func_traits.h b/host/lib/deps/rpclib/include/rpc/detail/func_traits.h new file mode 100644 index 000000000..1847d99dc --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/func_traits.h @@ -0,0 +1,77 @@ +#pragma once + +#ifndef FUNC_TRAITS_H_HWIWA6G0 +#define FUNC_TRAITS_H_HWIWA6G0 + +#include "rpc/detail/bool.h" + +namespace rpc { +namespace detail { + +template +using is_zero = invoke>; + +template +using nth_type = invoke>>; + +namespace tags { + +// tags for the function traits, used for tag dispatching +struct zero_arg {}; +struct nonzero_arg {}; +struct void_result {}; +struct nonvoid_result {}; + +template struct arg_count_trait { typedef nonzero_arg type; }; + +template <> struct arg_count_trait<0> { typedef zero_arg type; }; + +template struct result_trait { typedef nonvoid_result type; }; + +template <> struct result_trait { typedef void_result type; }; +} + +//! \brief Provides a small function traits implementation that +//! works with a reasonably large set of functors. +template +struct func_traits : func_traits {}; + +template +struct func_traits : func_traits {}; + +template +struct func_traits : func_traits {}; + +template struct func_traits { + using result_type = R; + using arg_count = std::integral_constant; + using args_type = std::tuple::type...>; +}; + +template +struct func_kind_info : func_kind_info {}; + +template +struct func_kind_info : func_kind_info {}; + +template +struct func_kind_info + : func_kind_info {}; + +template struct func_kind_info { + typedef typename tags::arg_count_trait::type args_kind; + typedef typename tags::result_trait::type result_kind; +}; + +template using is_zero_arg = is_zero::arg_count>; + +template +using is_single_arg = + invoke::arg_count == 1, true_, false_>>; + +template +using is_void_result = std::is_void::result_type>; +} +} + +#endif /* end of include guard: FUNC_TRAITS_H_HWIWA6G0 */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/if.h b/host/lib/deps/rpclib/include/rpc/detail/if.h new file mode 100644 index 000000000..7e4cab4f1 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/if.h @@ -0,0 +1,16 @@ +#pragma once + +#ifndef IF_H_1OW9DR7G +#define IF_H_1OW9DR7G + +#include "rpc/detail/invoke.h" + +namespace rpc { +namespace detail { + +template +using if_ = invoke>; +} +} + +#endif /* end of include guard: IF_H_1OW9DR7G */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/invoke.h b/host/lib/deps/rpclib/include/rpc/detail/invoke.h new file mode 100644 index 000000000..4a4915829 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/invoke.h @@ -0,0 +1,15 @@ +#pragma once + +#ifndef INVOKE_H_0CWMPLUE +#define INVOKE_H_0CWMPLUE + +namespace rpc { +namespace detail { + +template +using invoke = typename T::type; + +}} + + +#endif /* end of include guard: INVOKE_H_0CWMPLUE */ diff --git a/host/lib/deps/rpclib/include/rpc/detail/is_specialization_of.h b/host/lib/deps/rpclib/include/rpc/detail/is_specialization_of.h new file mode 100644 index 000000000..c4003cee9 --- /dev/null +++ b/host/lib/deps/rpclib/include/rpc/detail/is_specialization_of.h @@ -0,0 +1,20 @@ +#pragma once + +#ifndef IS_SPECIALIZATION_OF_H_OPZTARVG +#define IS_SPECIALIZATION_OF_H_OPZTARVG + +#include "rpc/detail/bool.h" + +namespace rpc { +namespace detail { + +template