Tiny fixes
This commit is contained in:
parent
ca233be127
commit
421f665e85
4 changed files with 22 additions and 14 deletions
|
@ -36,11 +36,7 @@ HEADERS += \
|
|||
debug.h \
|
||||
defines.h \
|
||||
managementserver.h \
|
||||
protocols/ikev2_vpn_protocol.h \
|
||||
protocols/openvpnovercloakprotocol.h \
|
||||
protocols/protocols_defs.h \
|
||||
protocols/shadowsocksvpnprotocol.h \
|
||||
protocols/wireguardprotocol.h \
|
||||
settings.h \
|
||||
ui/models/containers_model.h \
|
||||
ui/models/protocols_model.h \
|
||||
|
@ -72,7 +68,6 @@ HEADERS += \
|
|||
utils.h \
|
||||
vpnconnection.h \
|
||||
protocols/vpnprotocol.h \
|
||||
protocols/openvpnprotocol.h \
|
||||
|
||||
SOURCES += \
|
||||
configurators/cloak_configurator.cpp \
|
||||
|
@ -91,11 +86,7 @@ SOURCES += \
|
|||
debug.cpp \
|
||||
main.cpp \
|
||||
managementserver.cpp \
|
||||
protocols/ikev2_vpn_protocol.cpp \
|
||||
protocols/openvpnovercloakprotocol.cpp \
|
||||
protocols/protocols_defs.cpp \
|
||||
protocols/shadowsocksvpnprotocol.cpp \
|
||||
protocols/wireguardprotocol.cpp \
|
||||
settings.cpp \
|
||||
ui/models/containers_model.cpp \
|
||||
ui/models/protocols_model.cpp \
|
||||
|
@ -125,7 +116,6 @@ SOURCES += \
|
|||
utils.cpp \
|
||||
vpnconnection.cpp \
|
||||
protocols/vpnprotocol.cpp \
|
||||
protocols/openvpnprotocol.cpp \
|
||||
|
||||
RESOURCES += \
|
||||
resources.qrc
|
||||
|
@ -185,6 +175,23 @@ linux:!android {
|
|||
LIBS += /usr/lib/x86_64-linux-gnu/libssl.a
|
||||
}
|
||||
|
||||
win32|macx|linux:!android {
|
||||
|
||||
HEADERS += \
|
||||
protocols/openvpnprotocol.h \
|
||||
protocols/ikev2_vpn_protocol.h \
|
||||
protocols/openvpnovercloakprotocol.h \
|
||||
protocols/shadowsocksvpnprotocol.h \
|
||||
protocols/wireguardprotocol.h \
|
||||
|
||||
SOURCES += \
|
||||
protocols/openvpnprotocol.cpp \
|
||||
protocols/ikev2_vpn_protocol.cpp \
|
||||
protocols/openvpnovercloakprotocol.cpp \
|
||||
protocols/shadowsocksvpnprotocol.cpp \
|
||||
protocols/wireguardprotocol.cpp \
|
||||
}
|
||||
|
||||
android {
|
||||
QT += androidextras
|
||||
|
||||
|
|
|
@ -92,6 +92,7 @@ bool AndroidVpnProtocol::initialize()
|
|||
ErrorCode AndroidVpnProtocol::start()
|
||||
{
|
||||
|
||||
//qDebug().noquote() << "AndroidVpnProtocol::start" << QJsonDocument(m_rawConfig).toJson();
|
||||
qDebug() << "Prompting for VPN permission";
|
||||
auto appContext = QtAndroid::androidActivity().callObjectMethod(
|
||||
"getApplicationContext", "()Landroid/content/Context;");
|
||||
|
|
|
@ -4,11 +4,13 @@
|
|||
#include "vpnprotocol.h"
|
||||
#include "core/errorstrings.h"
|
||||
|
||||
#if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID))
|
||||
#include "openvpnprotocol.h"
|
||||
#include "shadowsocksvpnprotocol.h"
|
||||
#include "openvpnovercloakprotocol.h"
|
||||
#include "wireguardprotocol.h"
|
||||
#include "ikev2_vpn_protocol.h"
|
||||
#endif
|
||||
|
||||
|
||||
VpnProtocol::VpnProtocol(const QJsonObject &configuration, QObject* parent)
|
||||
|
@ -98,12 +100,13 @@ QString VpnProtocol::vpnGateway() const
|
|||
VpnProtocol *VpnProtocol::factory(DockerContainer container, const QJsonObject& configuration)
|
||||
{
|
||||
switch (container) {
|
||||
#if defined(Q_OS_WINDOWS) || defined(Q_OS_MACX) || (defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID))
|
||||
case DockerContainer::OpenVpn: return new OpenVpnProtocol(configuration);
|
||||
case DockerContainer::Cloak: return new OpenVpnOverCloakProtocol(configuration);
|
||||
case DockerContainer::ShadowSocks: return new ShadowSocksVpnProtocol(configuration);
|
||||
case DockerContainer::WireGuard: return new WireguardProtocol(configuration);
|
||||
case DockerContainer::Ipsec: return new Ikev2Protocol(configuration);
|
||||
|
||||
#endif
|
||||
default: return nullptr;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,9 +17,6 @@
|
|||
|
||||
#include "ipc.h"
|
||||
#include "core/ipcclient.h"
|
||||
#include "protocols/openvpnprotocol.h"
|
||||
#include "protocols/openvpnovercloakprotocol.h"
|
||||
#include "protocols/shadowsocksvpnprotocol.h"
|
||||
|
||||
#include "utils.h"
|
||||
#include "vpnconnection.h"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue