* CMake: Expose CMake options to includes
This change shuffles the order of several CMake steps to expose CMake
options to included files.
By defining options before inclusion, included files are able to access
the input provided by the build system.
* CMake: Exclude test dependencies when building tests
* CMake: Allow build system to provide protobuf compiler
When building without Hunter, it is desirable to pass the path to protoc and
the protobuf include directory from the build system. Allow these variables
to be overridden.
Fixes the error:
| CMake Error at cmake/functions.cmake:52 (message):
| Protobuf_PROTOC_EXECUTABLE is empty
| Call Stack (most recent call first):
| cmake/functions.cmake:96 (compile_proto_to_cpp)
| src/crypto/protobuf/CMakeLists.txt:6 (add_proto_library)
* Fix build error due to missing include
Error was:
| literals.cpp: In function 'libp2p::common::Hash256 libp2p::common::operator""_hash256(const char*, size_t)':
| literals.cpp:17:36: error: no matching function for call to 'min(size_t&, long unsigned int)'
| 17 | std::copy_n(c, std::min(s, 32ul), hash.rbegin());
| | ^
* Fix build error due to mismatched types
Error was:
| literals.cpp: In function 'libp2p::common::Hash256 libp2p::common::operator""_hash256(const char*, size_t)':
| literals.cpp:19:36: error: no matching function for call to 'min(size_t&, long unsigned int)'
| 19 | std::copy_n(c, std::min(s, 32ul), hash.rbegin());
| | ^
* Fix compiler warning due to sign comparison
When compiling with -Werror, this causes the build to fail.
Warning was:
| yamux_frame.cpp:103:28: error: comparison of integers of different signs: 'gsl::span::index_type' (aka 'int') and 'const uint32_t' (aka 'const unsigned int') [-Werror,-Wsign-compare]
| if (frame_bytes.size() < YamuxFrame::kHeaderLength) {
| ~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~
Change cmake-files for using internal fork of Hunter package manager
Signed-off-by: Dmitriy Khaustov aka xDimon <khaustov.dm@gmail.com>
Co-authored-by: Yura Zarudniy <zarudniy@soramitsu.co.jp>
* gossip: wire protocol
* gossip: peer set and wire protocol utilities revised
* gossip: msg cache w/expiration
* data structures for gossip: fixes and unittest
* changes due to pr 1 feedback
* one more fix due to PR requests
* one more try against ci
* gossip part 2
* gossip: pr1 reflects pr2
* gossip: pr1 reflects pr2
* Fix/gossip pr 1 (#46)
* Fix build for macos
* Improvements
* deprecated logic removed
* gossip: cleanups and renamings
* gossip: renmings
* gossip serialization method signature changed
* gossip: serialization signature changed
* Gossip pr 1 (#37)
* gossip: wire protocol
* gossip: peer set and wire protocol utilities revised
* gossip: msg cache w/expiration
* data structures for gossip: fixes and unittest
* changes due to pr 1 feedback
* one more fix due to PR requests
* one more try against ci
* gossip: pr1 reflects pr2
* gossip: pr1 reflects pr2
* Fix/gossip pr 1 (#46)
* Fix build for macos
* Improvements
* deprecated logic removed
* gossip: cleanups and renamings
* gossip: renmings
* gossip serialization method signature changed
Co-authored-by: kamilsa <kamilsa16@gmail.com>
* refactorings
* typo fixed
* minor fixes
* +gossip-example
* +gossip-example
* fixes and example
* debug things
* gossip: subscriptions test and bugfixes
* dont forward messages back to their origins
* injectors made parametric (to build examples)
* gossip: fixes
* more fixes in pub-sub
* fixes in gossip example
* sublogger can set new instance name
* message cache fix exp times
* chat example
* logs and traces added for debug purposes
* README.md for gossip examples
* small patch for older stdlibs support
* more logs and traces
* more logs and traces
* new inbound protocol streams are allowed for all connections
* streams issues fixed
* gossip injector fixed
* gossip new example
* boost_program_options in dependencies
* scheduler with config param (strong type for injector)
* tests fixed due to recent changes
* cleanup in yamux and dialer-listener hotfixes
* hotfixes to yamux and dialer
* yamux changes
* parametrized netork and host injectors
* streams regression test
* patched mplex connections/streams so that streams get notified about EOF
Co-authored-by: kamilsa <kamilsa16@gmail.com>