summaryrefslogtreecommitdiff
path: root/src/plugins/remotelinux
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@nokia.com>2012-05-18 10:49:35 +0200
committerChristian Kandeler <christian.kandeler@nokia.com>2012-05-22 10:51:53 +0200
commit53a1087d1321758ab1dc0a6ad737c135249bd5e6 (patch)
treeab0f9596da64a1907690b324bd05416c585eaf8c /src/plugins/remotelinux
parentb9d9bb7ba85e3b3ea0e06f0876272c0e3bebd144 (diff)
downloadqt-creator-53a1087d1321758ab1dc0a6ad737c135249bd5e6.tar.gz
Move SSH support into a dedicated library.
It does not belong into libUtils, which is a collection of small unrelated utility classes. Task-number: QTCREATORBUG-7218 Change-Id: Id92b9f28678afec93e6f07166adfde6550f38072 Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
Diffstat (limited to 'src/plugins/remotelinux')
-rw-r--r--src/plugins/remotelinux/abstractremotelinuxdeployservice.cpp8
-rw-r--r--src/plugins/remotelinux/abstractremotelinuxdeployservice.h4
-rw-r--r--src/plugins/remotelinux/abstractuploadandinstallpackageservice.cpp2
-rw-r--r--src/plugins/remotelinux/genericdirectuploadservice.cpp14
-rw-r--r--src/plugins/remotelinux/genericdirectuploadservice.h4
-rw-r--r--src/plugins/remotelinux/genericlinuxdeviceconfigurationwidget.cpp5
-rw-r--r--src/plugins/remotelinux/genericlinuxdeviceconfigurationwizard.cpp4
-rw-r--r--src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.cpp1
-rw-r--r--src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.h4
-rw-r--r--src/plugins/remotelinux/linuxdeviceconfiguration.cpp4
-rw-r--r--src/plugins/remotelinux/linuxdeviceconfiguration.h10
-rw-r--r--src/plugins/remotelinux/linuxdevicetester.cpp8
-rw-r--r--src/plugins/remotelinux/linuxdevicetester.h4
-rw-r--r--src/plugins/remotelinux/packageuploader.cpp12
-rw-r--r--src/plugins/remotelinux/packageuploader.h12
-rw-r--r--src/plugins/remotelinux/publickeydeploymentdialog.cpp2
-rw-r--r--src/plugins/remotelinux/remotelinux.qbs2
-rw-r--r--src/plugins/remotelinux/remotelinuxapplicationrunner.cpp17
-rw-r--r--src/plugins/remotelinux/remotelinuxapplicationrunner.h8
-rw-r--r--src/plugins/remotelinux/remotelinuxcustomcommanddeployservice.cpp4
-rw-r--r--src/plugins/remotelinux/remotelinuxdebugsupport.cpp2
-rw-r--r--src/plugins/remotelinux/remotelinuxenvironmentreader.cpp12
-rw-r--r--src/plugins/remotelinux/remotelinuxenvironmentreader.h4
-rw-r--r--src/plugins/remotelinux/remotelinuxpackageinstaller.cpp8
-rw-r--r--src/plugins/remotelinux/remotelinuxprocesslist.cpp4
-rw-r--r--src/plugins/remotelinux/remotelinuxrunconfiguration.cpp1
-rw-r--r--src/plugins/remotelinux/remotelinuxrunconfiguration.h4
-rw-r--r--src/plugins/remotelinux/remotelinuxusedportsgatherer.cpp9
-rw-r--r--src/plugins/remotelinux/sshkeydeployer.cpp4
-rw-r--r--src/plugins/remotelinux/sshkeydeployer.h4
-rw-r--r--src/plugins/remotelinux/startgdbserverdialog.cpp5
31 files changed, 95 insertions, 91 deletions
diff --git a/src/plugins/remotelinux/abstractremotelinuxdeployservice.cpp b/src/plugins/remotelinux/abstractremotelinuxdeployservice.cpp
index 33433d61f8..70d45ff453 100644
--- a/src/plugins/remotelinux/abstractremotelinuxdeployservice.cpp
+++ b/src/plugins/remotelinux/abstractremotelinuxdeployservice.cpp
@@ -36,8 +36,8 @@
#include <qt4projectmanager/qt4buildconfiguration.h>
#include <utils/qtcassert.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshconnectionmanager.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshconnectionmanager.h>
#include <QDateTime>
#include <QFileInfo>
@@ -45,7 +45,7 @@
#include <QString>
using namespace Qt4ProjectManager;
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -263,7 +263,7 @@ void AbstractRemoteLinuxDeployService::handleDeviceSetupDone(bool success)
d->state = Connecting;
d->connection = SshConnectionManager::instance().acquireConnection(d->deviceConfiguration->sshParameters());
- connect(d->connection.data(), SIGNAL(error(Utils::SshError)),
+ connect(d->connection.data(), SIGNAL(error(QSsh::SshError)),
SLOT(handleConnectionFailure()));
if (d->connection->state() == SshConnection::Connected) {
handleConnected();
diff --git a/src/plugins/remotelinux/abstractremotelinuxdeployservice.h b/src/plugins/remotelinux/abstractremotelinuxdeployservice.h
index e0f4fb5d3f..8ea3120c8b 100644
--- a/src/plugins/remotelinux/abstractremotelinuxdeployservice.h
+++ b/src/plugins/remotelinux/abstractremotelinuxdeployservice.h
@@ -39,7 +39,7 @@
#include <QVariantMap>
QT_FORWARD_DECLARE_CLASS(QString)
-namespace Utils { class SshConnection; }
+namespace QSsh { class SshConnection; }
namespace Qt4ProjectManager {
class Qt4BuildConfiguration;
@@ -82,7 +82,7 @@ signals:
protected:
const Qt4ProjectManager::Qt4BuildConfiguration *qt4BuildConfiguration() const;
QSharedPointer<const LinuxDeviceConfiguration> deviceConfiguration() const;
- QSharedPointer<Utils::SshConnection> connection() const;
+ QSharedPointer<QSsh::SshConnection> connection() const;
void saveDeploymentTimeStamp(const DeployableFile &deployableFile);
bool hasChangedSinceLastDeployment(const DeployableFile &deployableFile) const;
diff --git a/src/plugins/remotelinux/abstractuploadandinstallpackageservice.cpp b/src/plugins/remotelinux/abstractuploadandinstallpackageservice.cpp
index cc70ffb79b..a7fc3dc9b4 100644
--- a/src/plugins/remotelinux/abstractuploadandinstallpackageservice.cpp
+++ b/src/plugins/remotelinux/abstractuploadandinstallpackageservice.cpp
@@ -37,7 +37,7 @@
#include "remotelinuxpackageinstaller.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sshconnection.h>
#include <QFileInfo>
#include <QString>
diff --git a/src/plugins/remotelinux/genericdirectuploadservice.cpp b/src/plugins/remotelinux/genericdirectuploadservice.cpp
index 72a0e6aec0..74ada44f94 100644
--- a/src/plugins/remotelinux/genericdirectuploadservice.cpp
+++ b/src/plugins/remotelinux/genericdirectuploadservice.cpp
@@ -34,16 +34,16 @@
#include "deployablefile.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sftpchannel.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshremoteprocess.h>
+#include <ssh/sftpchannel.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshremoteprocess.h>
#include <QDir>
#include <QFileInfo>
#include <QList>
#include <QString>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -131,8 +131,8 @@ void GenericDirectUploadService::handleSftpInitialized()
}
Q_ASSERT(!d->filesToUpload.isEmpty());
- connect(d->uploader.data(), SIGNAL(finished(Utils::SftpJobId,QString)),
- SLOT(handleUploadFinished(Utils::SftpJobId,QString)));
+ connect(d->uploader.data(), SIGNAL(finished(QSsh::SftpJobId,QString)),
+ SLOT(handleUploadFinished(QSsh::SftpJobId,QString)));
d->state = Uploading;
uploadNextFile();
}
@@ -146,7 +146,7 @@ void GenericDirectUploadService::handleSftpInitializationFailed(const QString &m
handleDeploymentDone();
}
-void GenericDirectUploadService::handleUploadFinished(Utils::SftpJobId jobId, const QString &errorMsg)
+void GenericDirectUploadService::handleUploadFinished(QSsh::SftpJobId jobId, const QString &errorMsg)
{
Q_UNUSED(jobId);
diff --git a/src/plugins/remotelinux/genericdirectuploadservice.h b/src/plugins/remotelinux/genericdirectuploadservice.h
index 320afb6a45..1f697ca98a 100644
--- a/src/plugins/remotelinux/genericdirectuploadservice.h
+++ b/src/plugins/remotelinux/genericdirectuploadservice.h
@@ -35,7 +35,7 @@
#include "abstractremotelinuxdeployservice.h"
#include "remotelinux_export.h"
-#include <utils/ssh/sftpdefs.h>
+#include <ssh/sftpdefs.h>
#include <QList>
@@ -66,7 +66,7 @@ public:
private slots:
void handleSftpInitialized();
void handleSftpInitializationFailed(const QString &errorMessage);
- void handleUploadFinished(Utils::SftpJobId jobId, const QString &errorMsg);
+ void handleUploadFinished(QSsh::SftpJobId jobId, const QString &errorMsg);
void handleMkdirFinished(int exitStatus);
void handleLnFinished(int exitStatus);
void handleStdOutData();
diff --git a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwidget.cpp b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwidget.cpp
index 3a270c7490..f7e4850d15 100644
--- a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwidget.cpp
+++ b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwidget.cpp
@@ -33,12 +33,13 @@
#include "ui_genericlinuxdeviceconfigurationwidget.h"
#include <utils/portlist.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshkeycreationdialog.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshkeycreationdialog.h>
#include <QTextStream>
using namespace RemoteLinux;
+using namespace QSsh;
using namespace Utils;
GenericLinuxDeviceConfigurationWidget::GenericLinuxDeviceConfigurationWidget(
diff --git a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizard.cpp b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizard.cpp
index 6d8be5cd03..764a4d5761 100644
--- a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizard.cpp
+++ b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizard.cpp
@@ -38,7 +38,7 @@
#include <utils/portlist.h>
using namespace ProjectExplorer;
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -76,7 +76,7 @@ GenericLinuxDeviceConfigurationWizard::~GenericLinuxDeviceConfigurationWizard()
IDevice::Ptr GenericLinuxDeviceConfigurationWizard::device()
{
- Utils::SshConnectionParameters sshParams;
+ QSsh::SshConnectionParameters sshParams;
sshParams.host = d->setupPage.hostName();
sshParams.userName = d->setupPage.userName();
sshParams.port = 22;
diff --git a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.cpp b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.cpp
index b4ba390c6d..e7ea64e155 100644
--- a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.cpp
+++ b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.cpp
@@ -50,6 +50,7 @@ public:
} // namespace Internal
+using namespace QSsh;
using namespace Utils;
GenericLinuxDeviceConfigurationWizardSetupPage::GenericLinuxDeviceConfigurationWizardSetupPage(QWidget *parent) :
diff --git a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.h b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.h
index e5b22c5feb..71930503c3 100644
--- a/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.h
+++ b/src/plugins/remotelinux/genericlinuxdeviceconfigurationwizardpages.h
@@ -33,7 +33,7 @@
#include "remotelinux_export.h"
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sshconnection.h>
#include <QWizardPage>
@@ -57,7 +57,7 @@ public:
QString configurationName() const;
QString hostName() const;
QString userName() const;
- Utils::SshConnectionParameters::AuthenticationType authenticationType() const;
+ QSsh::SshConnectionParameters::AuthenticationType authenticationType() const;
QString password() const;
QString privateKeyFilePath() const;
diff --git a/src/plugins/remotelinux/linuxdeviceconfiguration.cpp b/src/plugins/remotelinux/linuxdeviceconfiguration.cpp
index a478926755..d05fc3a23a 100644
--- a/src/plugins/remotelinux/linuxdeviceconfiguration.cpp
+++ b/src/plugins/remotelinux/linuxdeviceconfiguration.cpp
@@ -39,13 +39,15 @@
#include "remotelinux_constants.h"
#include <utils/portlist.h>
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sshconnection.h>
#include <utils/qtcassert.h>
#include <QDesktopServices>
#include <QStringList>
+using namespace QSsh;
using namespace Utils;
+
typedef SshConnectionParameters::AuthenticationType AuthType;
namespace RemoteLinux {
diff --git a/src/plugins/remotelinux/linuxdeviceconfiguration.h b/src/plugins/remotelinux/linuxdeviceconfiguration.h
index 6fa22eb9be..ab9bcdceed 100644
--- a/src/plugins/remotelinux/linuxdeviceconfiguration.h
+++ b/src/plugins/remotelinux/linuxdeviceconfiguration.h
@@ -38,10 +38,8 @@
#include <QCoreApplication>
-namespace Utils {
-class SshConnectionParameters;
-class PortList;
-}
+namespace QSsh { class SshConnectionParameters; }
+namespace Utils { class PortList; }
namespace RemoteLinux {
namespace Internal {
@@ -60,10 +58,10 @@ public:
~LinuxDeviceConfiguration();
Utils::PortList freePorts() const;
- Utils::SshConnectionParameters sshParameters() const;
+ QSsh::SshConnectionParameters sshParameters() const;
MachineType machineType() const;
- void setSshParameters(const Utils::SshConnectionParameters &sshParameters);
+ void setSshParameters(const QSsh::SshConnectionParameters &sshParameters);
void setFreePorts(const Utils::PortList &freePorts);
static QString defaultPrivateKeyFilePath();
diff --git a/src/plugins/remotelinux/linuxdevicetester.cpp b/src/plugins/remotelinux/linuxdevicetester.cpp
index e7b32afa51..6a9845e8dc 100644
--- a/src/plugins/remotelinux/linuxdevicetester.cpp
+++ b/src/plugins/remotelinux/linuxdevicetester.cpp
@@ -35,10 +35,10 @@
#include "remotelinuxusedportsgatherer.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sshremoteprocess.h>
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sshremoteprocess.h>
+#include <ssh/sshconnection.h>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -86,7 +86,7 @@ void GenericLinuxDeviceTester::testDevice(const LinuxDeviceConfiguration::ConstP
d->deviceConfiguration = deviceConfiguration;
d->connection = SshConnection::create(deviceConfiguration->sshParameters());
connect(d->connection.data(), SIGNAL(connected()), SLOT(handleConnected()));
- connect(d->connection.data(), SIGNAL(error(Utils::SshError)),
+ connect(d->connection.data(), SIGNAL(error(QSsh::SshError)),
SLOT(handleConnectionFailure()));
emit progressMessage(tr("Connecting to host..."));
diff --git a/src/plugins/remotelinux/linuxdevicetester.h b/src/plugins/remotelinux/linuxdevicetester.h
index 7e2ef787ab..58a3f10ed7 100644
--- a/src/plugins/remotelinux/linuxdevicetester.h
+++ b/src/plugins/remotelinux/linuxdevicetester.h
@@ -39,7 +39,7 @@
QT_FORWARD_DECLARE_CLASS(QString)
-namespace Utils {
+namespace QSsh {
class SshConnection;
}
@@ -80,7 +80,7 @@ public:
void testDevice(const QSharedPointer<const LinuxDeviceConfiguration> &deviceConfiguration);
void stopTest();
- QSharedPointer<Utils::SshConnection> connection() const;
+ QSharedPointer<QSsh::SshConnection> connection() const;
private slots:
void handleConnected();
diff --git a/src/plugins/remotelinux/packageuploader.cpp b/src/plugins/remotelinux/packageuploader.cpp
index 4e17ad1104..fbdb058def 100644
--- a/src/plugins/remotelinux/packageuploader.cpp
+++ b/src/plugins/remotelinux/packageuploader.cpp
@@ -33,10 +33,10 @@
#include "packageuploader.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sftpchannel.h>
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sftpchannel.h>
+#include <ssh/sshconnection.h>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -61,15 +61,15 @@ void PackageUploader::uploadPackage(const SshConnection::Ptr &connection,
m_localFilePath = localFilePath;
m_remoteFilePath = remoteFilePath;
m_connection = connection;
- connect(m_connection.data(), SIGNAL(error(Utils::SshError)),
+ connect(m_connection.data(), SIGNAL(error(QSsh::SshError)),
SLOT(handleConnectionFailure()));
m_uploader = m_connection->createSftpChannel();
connect(m_uploader.data(), SIGNAL(initialized()), this,
SLOT(handleSftpChannelInitialized()));
connect(m_uploader.data(), SIGNAL(initializationFailed(QString)), this,
SLOT(handleSftpChannelInitializationFailed(QString)));
- connect(m_uploader.data(), SIGNAL(finished(Utils::SftpJobId,QString)),
- this, SLOT(handleSftpJobFinished(Utils::SftpJobId,QString)));
+ connect(m_uploader.data(), SIGNAL(finished(QSsh::SftpJobId,QString)),
+ this, SLOT(handleSftpJobFinished(QSsh::SftpJobId,QString)));
m_uploader->initialize();
}
diff --git a/src/plugins/remotelinux/packageuploader.h b/src/plugins/remotelinux/packageuploader.h
index 3c671257bd..d29adf80b5 100644
--- a/src/plugins/remotelinux/packageuploader.h
+++ b/src/plugins/remotelinux/packageuploader.h
@@ -37,9 +37,9 @@
#include <QSharedPointer>
#include <QString>
-#include <utils/ssh/sftpdefs.h>
+#include <ssh/sftpdefs.h>
-namespace Utils {
+namespace QSsh {
class SftpChannel;
class SshConnection;
}
@@ -55,7 +55,7 @@ public:
~PackageUploader();
// Connection has to be established already.
- void uploadPackage(const QSharedPointer<Utils::SshConnection> &connection,
+ void uploadPackage(const QSharedPointer<QSsh::SshConnection> &connection,
const QString &localFilePath, const QString &remoteFilePath);
void cancelUpload();
@@ -67,7 +67,7 @@ private slots:
void handleConnectionFailure();
void handleSftpChannelInitialized();
void handleSftpChannelInitializationFailed(const QString &error);
- void handleSftpJobFinished(Utils::SftpJobId job, const QString &error);
+ void handleSftpJobFinished(QSsh::SftpJobId job, const QString &error);
private:
enum State { InitializingSftp, Uploading, Inactive };
@@ -76,8 +76,8 @@ private:
void setState(State newState);
State m_state;
- QSharedPointer<Utils::SshConnection> m_connection;
- QSharedPointer<Utils::SftpChannel> m_uploader;
+ QSharedPointer<QSsh::SshConnection> m_connection;
+ QSharedPointer<QSsh::SftpChannel> m_uploader;
QString m_localFilePath;
QString m_remoteFilePath;
};
diff --git a/src/plugins/remotelinux/publickeydeploymentdialog.cpp b/src/plugins/remotelinux/publickeydeploymentdialog.cpp
index 605e6a49a4..6b10673884 100644
--- a/src/plugins/remotelinux/publickeydeploymentdialog.cpp
+++ b/src/plugins/remotelinux/publickeydeploymentdialog.cpp
@@ -34,7 +34,7 @@
#include "sshkeydeployer.h"
#include <coreplugin/icore.h>
-#include <utils/ssh/sshconnection.h>
+#include <ssh/sshconnection.h>
#include <QTimer>
#include <QFileDialog>
diff --git a/src/plugins/remotelinux/remotelinux.qbs b/src/plugins/remotelinux/remotelinux.qbs
index e3ae54956c..84e1151e0e 100644
--- a/src/plugins/remotelinux/remotelinux.qbs
+++ b/src/plugins/remotelinux/remotelinux.qbs
@@ -11,6 +11,7 @@ QtcPlugin {
Depends { name: "ProjectExplorer" }
Depends { name: "Qt4ProjectManager" }
Depends { name: "QtSupport" }
+ Depends { name: "QtcSsh" }
Depends { name: "cpp" }
cpp.includePaths: [
@@ -133,6 +134,7 @@ QtcPlugin {
ProductModule {
Depends { name: "Core" }
+ Depends { name: "QtcSsh" }
}
}
diff --git a/src/plugins/remotelinux/remotelinuxapplicationrunner.cpp b/src/plugins/remotelinux/remotelinuxapplicationrunner.cpp
index 1485db51c5..95101ec82a 100644
--- a/src/plugins/remotelinux/remotelinuxapplicationrunner.cpp
+++ b/src/plugins/remotelinux/remotelinuxapplicationrunner.cpp
@@ -37,13 +37,14 @@
#include <utils/portlist.h>
#include <utils/qtcassert.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshconnectionmanager.h>
-#include <utils/ssh/sshremoteprocess.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshconnectionmanager.h>
+#include <ssh/sshremoteprocess.h>
#include <limits>
using namespace Qt4ProjectManager;
+using namespace QSsh;
using namespace Utils;
namespace RemoteLinux {
@@ -79,9 +80,9 @@ public:
const QString commandPrefix;
const PortList initialFreePorts;
- Utils::SshConnection::Ptr connection;
- Utils::SshRemoteProcess::Ptr runner;
- Utils::SshRemoteProcess::Ptr cleaner;
+ QSsh::SshConnection::Ptr connection;
+ QSsh::SshRemoteProcess::Ptr runner;
+ QSsh::SshRemoteProcess::Ptr cleaner;
PortList freePorts;
int exitStatus;
@@ -400,13 +401,13 @@ void AbstractRemoteLinuxApplicationRunner::handleDeviceSetupDone(bool success)
d->exitStatus = -1;
d->freePorts = d->initialFreePorts;
connect(d->connection.data(), SIGNAL(connected()), SLOT(handleConnected()));
- connect(d->connection.data(), SIGNAL(error(Utils::SshError)),
+ connect(d->connection.data(), SIGNAL(error(QSsh::SshError)),
SLOT(handleConnectionFailure()));
if (d->connection->state() == SshConnection::Connected) {
handleConnected();
} else {
emit reportProgress(tr("Connecting to device..."));
- if (d->connection->state() == Utils::SshConnection::Unconnected)
+ if (d->connection->state() == QSsh::SshConnection::Unconnected)
d->connection->connectToHost();
}
}
diff --git a/src/plugins/remotelinux/remotelinuxapplicationrunner.h b/src/plugins/remotelinux/remotelinuxapplicationrunner.h
index 92f2b053c0..0961b9ab1a 100644
--- a/src/plugins/remotelinux/remotelinuxapplicationrunner.h
+++ b/src/plugins/remotelinux/remotelinuxapplicationrunner.h
@@ -36,10 +36,8 @@
#include <QObject>
#include <QSharedPointer>
-namespace Utils {
-class PortList;
-class SshConnection;
-}
+namespace QSsh { class SshConnection; }
+namespace Utils { class PortList; }
namespace RemoteLinux {
class LinuxDeviceConfiguration;
@@ -64,7 +62,7 @@ public:
void startExecution(const QByteArray &remoteCall);
- QSharedPointer<Utils::SshConnection> connection() const;
+ QSharedPointer<QSsh::SshConnection> connection() const;
QSharedPointer<const LinuxDeviceConfiguration> devConfig() const;
const RemoteLinuxUsedPortsGatherer *usedPortsGatherer() const;
Utils::PortList *freePorts();
diff --git a/src/plugins/remotelinux/remotelinuxcustomcommanddeployservice.cpp b/src/plugins/remotelinux/remotelinuxcustomcommanddeployservice.cpp
index 29653c84bd..11d2bc435b 100644
--- a/src/plugins/remotelinux/remotelinuxcustomcommanddeployservice.cpp
+++ b/src/plugins/remotelinux/remotelinuxcustomcommanddeployservice.cpp
@@ -34,11 +34,11 @@
#include "linuxdeviceconfiguration.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshremoteprocessrunner.h>
#include <QString>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
diff --git a/src/plugins/remotelinux/remotelinuxdebugsupport.cpp b/src/plugins/remotelinux/remotelinuxdebugsupport.cpp
index 73344d11bc..176df268e5 100644
--- a/src/plugins/remotelinux/remotelinuxdebugsupport.cpp
+++ b/src/plugins/remotelinux/remotelinuxdebugsupport.cpp
@@ -47,7 +47,7 @@
#include <QPointer>
#include <QSharedPointer>
-using namespace Utils;
+using namespace QSsh;
using namespace Debugger;
using namespace ProjectExplorer;
diff --git a/src/plugins/remotelinux/remotelinuxenvironmentreader.cpp b/src/plugins/remotelinux/remotelinuxenvironmentreader.cpp
index 0703e97b0c..5fd0213aed 100644
--- a/src/plugins/remotelinux/remotelinuxenvironmentreader.cpp
+++ b/src/plugins/remotelinux/remotelinuxenvironmentreader.cpp
@@ -33,7 +33,7 @@
#include "linuxdeviceconfiguration.h"
#include "remotelinuxrunconfiguration.h"
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshremoteprocessrunner.h>
namespace RemoteLinux {
namespace Internal {
@@ -60,7 +60,7 @@ void RemoteLinuxEnvironmentReader::start(const QString &environmentSetupCommand)
return;
m_stop = false;
if (!m_remoteProcessRunner)
- m_remoteProcessRunner = new Utils::SshRemoteProcessRunner(this);
+ m_remoteProcessRunner = new QSsh::SshRemoteProcessRunner(this);
connect(m_remoteProcessRunner, SIGNAL(connectionError()), SLOT(handleConnectionFailure()));
connect(m_remoteProcessRunner, SIGNAL(processClosed(int)), SLOT(remoteProcessFinished(int)));
connect(m_remoteProcessRunner, SIGNAL(processOutputAvailable(QByteArray)),
@@ -102,16 +102,16 @@ void RemoteLinuxEnvironmentReader::handleCurrentDeviceConfigChanged()
void RemoteLinuxEnvironmentReader::remoteProcessFinished(int exitCode)
{
- Q_ASSERT(exitCode == Utils::SshRemoteProcess::FailedToStart
- || exitCode == Utils::SshRemoteProcess::KilledBySignal
- || exitCode == Utils::SshRemoteProcess::ExitedNormally);
+ Q_ASSERT(exitCode == QSsh::SshRemoteProcess::FailedToStart
+ || exitCode == QSsh::SshRemoteProcess::KilledBySignal
+ || exitCode == QSsh::SshRemoteProcess::ExitedNormally);
if (m_stop)
return;
disconnect(m_remoteProcessRunner, 0, this, 0);
m_env.clear();
- if (exitCode == Utils::SshRemoteProcess::ExitedNormally) {
+ if (exitCode == QSsh::SshRemoteProcess::ExitedNormally) {
if (!m_remoteOutput.isEmpty()) {
m_env = Utils::Environment(m_remoteOutput.split(QLatin1Char('\n'),
QString::SkipEmptyParts));
diff --git a/src/plugins/remotelinux/remotelinuxenvironmentreader.h b/src/plugins/remotelinux/remotelinuxenvironmentreader.h
index 5e80faf697..7f49be8edb 100644
--- a/src/plugins/remotelinux/remotelinuxenvironmentreader.h
+++ b/src/plugins/remotelinux/remotelinuxenvironmentreader.h
@@ -37,7 +37,7 @@
#include <QObject>
#include <QSharedPointer>
-namespace Utils {
+namespace QSsh {
class SshRemoteProcessRunner;
}
@@ -80,7 +80,7 @@ private:
Utils::Environment m_env;
QSharedPointer<const LinuxDeviceConfiguration> m_devConfig;
RemoteLinuxRunConfiguration *m_runConfig;
- Utils::SshRemoteProcessRunner *m_remoteProcessRunner;
+ QSsh::SshRemoteProcessRunner *m_remoteProcessRunner;
};
} // namespace Internal
diff --git a/src/plugins/remotelinux/remotelinuxpackageinstaller.cpp b/src/plugins/remotelinux/remotelinuxpackageinstaller.cpp
index b2c7d20c3a..3a060d2185 100644
--- a/src/plugins/remotelinux/remotelinuxpackageinstaller.cpp
+++ b/src/plugins/remotelinux/remotelinuxpackageinstaller.cpp
@@ -34,11 +34,11 @@
#include "linuxdeviceconfiguration.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshremoteprocessrunner.h>
#include <QByteArray>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
@@ -50,8 +50,8 @@ public:
bool isRunning;
LinuxDeviceConfiguration::ConstPtr deviceConfig;
- Utils::SshRemoteProcessRunner *installer;
- Utils::SshRemoteProcessRunner *killProcess;
+ QSsh::SshRemoteProcessRunner *installer;
+ QSsh::SshRemoteProcessRunner *killProcess;
};
} // namespace Internal
diff --git a/src/plugins/remotelinux/remotelinuxprocesslist.cpp b/src/plugins/remotelinux/remotelinuxprocesslist.cpp
index 29c4deb321..347f17d0f8 100644
--- a/src/plugins/remotelinux/remotelinuxprocesslist.cpp
+++ b/src/plugins/remotelinux/remotelinuxprocesslist.cpp
@@ -33,12 +33,12 @@
#include "linuxdeviceconfiguration.h"
#include <utils/qtcassert.h>
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshremoteprocessrunner.h>
#include <QByteArray>
#include <QString>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
diff --git a/src/plugins/remotelinux/remotelinuxrunconfiguration.cpp b/src/plugins/remotelinux/remotelinuxrunconfiguration.cpp
index 03e935c8c4..f39af40b42 100644
--- a/src/plugins/remotelinux/remotelinuxrunconfiguration.cpp
+++ b/src/plugins/remotelinux/remotelinuxrunconfiguration.cpp
@@ -51,6 +51,7 @@
using namespace ProjectExplorer;
using namespace Qt4ProjectManager;
+using namespace QSsh;
using namespace Utils;
namespace RemoteLinux {
diff --git a/src/plugins/remotelinux/remotelinuxrunconfiguration.h b/src/plugins/remotelinux/remotelinuxrunconfiguration.h
index 77ad9b16e3..55ae2a740a 100644
--- a/src/plugins/remotelinux/remotelinuxrunconfiguration.h
+++ b/src/plugins/remotelinux/remotelinuxrunconfiguration.h
@@ -44,9 +44,7 @@ class Qt4BaseTarget;
class Qt4ProFileNode;
} // namespace Qt4ProjectManager
-namespace Utils {
-class PortList;
-}
+namespace Utils { class PortList; }
namespace RemoteLinux {
class LinuxDeviceConfiguration;
diff --git a/src/plugins/remotelinux/remotelinuxusedportsgatherer.cpp b/src/plugins/remotelinux/remotelinuxusedportsgatherer.cpp
index 23c442b52d..5dc94bbc68 100644
--- a/src/plugins/remotelinux/remotelinuxusedportsgatherer.cpp
+++ b/src/plugins/remotelinux/remotelinuxusedportsgatherer.cpp
@@ -34,12 +34,13 @@
#include <utils/portlist.h>
#include <utils/qtcassert.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshconnectionmanager.h>
-#include <utils/ssh/sshremoteprocess.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshconnectionmanager.h>
+#include <ssh/sshremoteprocess.h>
#include <QString>
+using namespace QSsh;
using namespace Utils;
namespace RemoteLinux {
@@ -75,7 +76,7 @@ void RemoteLinuxUsedPortsGatherer::start(const LinuxDeviceConfiguration::ConstPt
QTC_ASSERT(!d->connection, return);
d->portsToCheck = devConf->freePorts();
d->connection = SshConnectionManager::instance().acquireConnection(devConf->sshParameters());
- connect(d->connection.data(), SIGNAL(error(Utils::SshError)), SLOT(handleConnectionError()));
+ connect(d->connection.data(), SIGNAL(error(QSsh::SshError)), SLOT(handleConnectionError()));
if (d->connection->state() == SshConnection::Connected) {
handleConnectionEstablished();
return;
diff --git a/src/plugins/remotelinux/sshkeydeployer.cpp b/src/plugins/remotelinux/sshkeydeployer.cpp
index 955373c266..fcdd31a8dd 100644
--- a/src/plugins/remotelinux/sshkeydeployer.cpp
+++ b/src/plugins/remotelinux/sshkeydeployer.cpp
@@ -30,13 +30,13 @@
**************************************************************************/
#include "sshkeydeployer.h"
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshremoteprocessrunner.h>
#include <utils/fileutils.h>
#include <QFile>
#include <QSharedPointer>
-using namespace Utils;
+using namespace QSsh;
namespace RemoteLinux {
namespace Internal {
diff --git a/src/plugins/remotelinux/sshkeydeployer.h b/src/plugins/remotelinux/sshkeydeployer.h
index 5debd0e194..28c9d262eb 100644
--- a/src/plugins/remotelinux/sshkeydeployer.h
+++ b/src/plugins/remotelinux/sshkeydeployer.h
@@ -35,7 +35,7 @@
#include <QObject>
-namespace Utils {
+namespace QSsh {
class SshConnectionParameters;
}
@@ -52,7 +52,7 @@ public:
explicit SshKeyDeployer(QObject *parent = 0);
~SshKeyDeployer();
- void deployPublicKey(const Utils::SshConnectionParameters &sshParams,
+ void deployPublicKey(const QSsh::SshConnectionParameters &sshParams,
const QString &keyFilePath);
void stopDeployment();
diff --git a/src/plugins/remotelinux/startgdbserverdialog.cpp b/src/plugins/remotelinux/startgdbserverdialog.cpp
index 2723658693..9cc6d5d06c 100644
--- a/src/plugins/remotelinux/startgdbserverdialog.cpp
+++ b/src/plugins/remotelinux/startgdbserverdialog.cpp
@@ -43,8 +43,8 @@
#include <utils/pathchooser.h>
#include <utils/portlist.h>
#include <utils/qtcassert.h>
-#include <utils/ssh/sshconnection.h>
-#include <utils/ssh/sshremoteprocessrunner.h>
+#include <ssh/sshconnection.h>
+#include <ssh/sshremoteprocessrunner.h>
#include <QVariant>
#include <QSettings>
@@ -70,6 +70,7 @@
using namespace Core;
using namespace ProjectExplorer;
+using namespace QSsh;
using namespace Utils;
const char LastSysroot[] = "RemoteLinux/LastSysroot";