working toward compilation, still has include issue

pull/1184/head
Thomas Winget 4 years ago
parent a4141617d7
commit 8dc5dabe49

@ -208,6 +208,12 @@ if(TESTNET)
endif()
add_library(${STATIC_LIB} STATIC ${LIB_SRC})
if(WITH_HIVE)
set(LIB_SRC ${LIB_SRC} tooling/router_hive.cpp tooling/router_event.cpp)
target_include_directories(${STATIC_LIB} PUBLIC ${CMAKE_SOURCE_DIR}/tooling)
endif()
target_include_directories(${STATIC_LIB} PUBLIC ${CURL_INCLUDE_DIRS})
target_link_libraries(${STATIC_LIB} PUBLIC cxxopts ${ABYSS_LIB} ${PLATFORM_LIB} ${UTIL_LIB} ${CRYPTOGRAPHY_LIB})

@ -18,6 +18,7 @@ struct llarp_threadpool;
namespace tooling
{
struct RouterHive;
struct RouterEvent;
} // namespace tooling
@ -64,6 +65,11 @@ namespace llarp
struct AbstractRouter
{
#ifdef LOKINET_HIVE
tooling::RouterHive* hive;
#endif
virtual ~AbstractRouter() = default;
virtual bool
@ -267,7 +273,7 @@ namespace llarp
GossipRCIfNeeded(const RouterContact rc) = 0;
virtual void
NotifyRouterEvent(RouterEvent event) const = 0;
NotifyRouterEvent(tooling::RouterEvent event) const = 0;
};
} // namespace llarp

@ -23,6 +23,11 @@
#include <util/str.hpp>
#include <ev/ev.hpp>
#ifdef LOKINET_HIVE
#include "tooling/router_event.hpp"
#include "tooling/router_hive.hpp"
#endif
#include <fstream>
#include <cstdlib>
#include <iterator>
@ -126,7 +131,7 @@ namespace llarp
}
void
Router::NotifyRouterEvent(RouterEvent event) const
Router::NotifyRouterEvent(tooling::RouterEvent event) const
{
#ifdef LOKINET_HIVE
hive->NotifyEvent(event);

@ -45,7 +45,6 @@
namespace tooling
{
struct RouterHive;
struct RouterEvent;
} // namespace tooling
@ -288,10 +287,6 @@ namespace llarp
TimePoint_t m_NextExploreAt;
#ifdef LOKINET_HIVE
RouterHive* hive;
#endif
IOutboundMessageHandler &
outboundMessageHandler() override
{
@ -320,7 +315,7 @@ namespace llarp
GossipRCIfNeeded(const RouterContact rc) override;
void
NotifyRouterEvent(RouterEvent event) const override;
NotifyRouterEvent(tooling::RouterEvent event) const override;
Router(std::shared_ptr< llarp::thread::ThreadPool > worker,
llarp_ev_loop_ptr __netloop, std::shared_ptr< Logic > logic);

Loading…
Cancel
Save