diff --git a/daemon/CMakeLists.txt b/daemon/CMakeLists.txt index b6fd20917..e2e725d74 100644 --- a/daemon/CMakeLists.txt +++ b/daemon/CMakeLists.txt @@ -1,10 +1,7 @@ add_executable(lokinet-vpn lokinet-vpn.cpp) if(APPLE) - set(LOKINET_SWIFT_SOURCES lokinet.swift) - add_executable(lokinet ${LOKINET_SWIFT_SOURCES}) - configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Lokinet.modulemap.in ${CMAKE_CURRENT_BINARY_DIR}/swift/LokinetExtension/module.modulemap ESCAPE_QUOTES @ONLY) - target_include_directories(lokinet PUBLIC ${CMAKE_CURRENT_BINARY_DIR}/swift) + add_executable(lokinet lokinet.swift) enable_lto(lokinet) else() add_executable(lokinet lokinet.cpp) diff --git a/daemon/Lokinet.modulemap.in b/daemon/Lokinet.modulemap.in deleted file mode 100644 index 607823e38..000000000 --- a/daemon/Lokinet.modulemap.in +++ /dev/null @@ -1,4 +0,0 @@ - -module LokinetExtension { - header "@CMAKE_SOURCE_DIR@/include/lokinet-extension.hpp" -} \ No newline at end of file diff --git a/daemon/lokinet.cpp b/daemon/lokinet.cpp index 52664e897..316d1b856 100644 --- a/daemon/lokinet.cpp +++ b/daemon/lokinet.cpp @@ -11,10 +11,6 @@ #include #endif -#ifdef __APPLE__ -#include -#endif - #include #include @@ -400,10 +396,6 @@ lokinet_main(int argc, char* argv[]) { return result; } -#ifdef __APPLE__ - llarp::LogContext::Instance().logStream.reset(new llarp::NSLogStream{}); -#endif - llarp::RuntimeOptions opts; #ifdef _WIN32 diff --git a/include/lokinet-dnsproxy.hpp b/include/lokinet-dnsproxy.hpp deleted file mode 100644 index 8f0545090..000000000 --- a/include/lokinet-dnsproxy.hpp +++ /dev/null @@ -1,19 +0,0 @@ -#pragma once -#include -#include - -struct DNSImpl; - -@interface DNSProvider : NEDNSProxyProvider -{ - struct DNSImpl* m_Impl; -} -- (void)startProxyWithOptions:(NSDictionary*)options - completionHandler:(void (^)(NSError* error))completionHandler; - -- (void)stopProxyWithReason:(NEProviderStopReason)reason - completionHandler:(void (^)(void))completionHandler; - -- (BOOL)handleNewFlow:(NEAppProxyFlow*)flow; - -@end diff --git a/include/lokinet-extension.hpp b/include/lokinet-extension.hpp deleted file mode 100644 index df436ab4e..000000000 --- a/include/lokinet-extension.hpp +++ /dev/null @@ -1,21 +0,0 @@ -#pragma once -#include -#include - -struct ContextWrapper; - -@interface LLARPPacketTunnel : NEPacketTunnelProvider -{ - struct ContextWrapper* m_Context; -} - -- (void)startTunnelWithOptions:(NSDictionary*)options - completionHandler:(void (^)(NSError* error))completionHandler; - -- (void)stopTunnelWithReason:(NEProviderStopReason)reason - completionHandler:(void (^)(void))completionHandler; - -- (void)handleAppMessage:(NSData*)messageData - completionHandler:(void (^)(NSData* responseData))completionHandler; - -@end diff --git a/llarp/config/config.cpp b/llarp/config/config.cpp index caae01abf..4e1b4c80e 100644 --- a/llarp/config/config.cpp +++ b/llarp/config/config.cpp @@ -1446,17 +1446,4 @@ namespace llarp return config; } -#ifdef __APPLE__ - std::shared_ptr - Config::NetworkExtensionConfig(std::string exit) - { - auto config = std::make_shared(fs::path{}); - config->Load(); - config->logging.m_logLevel = eLogInfo; - config->bootstrap.files.clear(); - config->network.m_LNSExitMap.Insert(IPRange{}, exit); - return config; - } -#endif - } // namespace llarp diff --git a/llarp/config/config.hpp b/llarp/config/config.hpp index 994725e02..03f7a000c 100644 --- a/llarp/config/config.hpp +++ b/llarp/config/config.hpp @@ -260,11 +260,6 @@ namespace llarp static std::shared_ptr EmbeddedConfig(); -#ifdef __APPLE__ - static std::shared_ptr - NetworkExtensionConfig(std::string exit); -#endif - private: /// Load (initialize) a default config. ///