From 4f2b15679d3e12870ee7db94d72eaea0d3849b28 Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 4 Oct 2022 08:09:44 +0200 Subject: [PATCH] RemoteLinux: Allow remote linux build devices as opt-in ... by setting QTC_ALLOW_REMOTE_LINUX_BUILD_DEVICES=1 Registering compilers and cmake on such devices already works manually. [Note: The remote file dialog is extremely slow when browsing remote directories] After that, opening a CMakeLists.txt on the device works, but not much more. Change-Id: I19025930699f6aec57d26a36b3fb04109fbf03e8 Reviewed-by: Christian Kandeler --- src/plugins/remotelinux/linuxdevice.cpp | 6 ++++++ src/plugins/remotelinux/linuxdevice.h | 1 + 2 files changed, 7 insertions(+) diff --git a/src/plugins/remotelinux/linuxdevice.cpp b/src/plugins/remotelinux/linuxdevice.cpp index 88be06dd539..ce97e2a5a73 100644 --- a/src/plugins/remotelinux/linuxdevice.cpp +++ b/src/plugins/remotelinux/linuxdevice.cpp @@ -1034,6 +1034,12 @@ DeviceEnvironmentFetcher::Ptr LinuxDevice::environmentFetcher() const return DeviceEnvironmentFetcher::Ptr(new LinuxDeviceEnvironmentFetcher(sharedFromThis())); } +bool LinuxDevice::usableAsBuildDevice() const +{ + const bool isUsable = qtcEnvironmentVariableIntValue("QTC_ALLOW_REMOTE_LINUX_BUILD_DEVICES"); + return isUsable; +} + QString LinuxDevice::userAtHost() const { return sshParameters().userAtHost(); diff --git a/src/plugins/remotelinux/linuxdevice.h b/src/plugins/remotelinux/linuxdevice.h index 4897e87e6b4..0d4748cb308 100644 --- a/src/plugins/remotelinux/linuxdevice.h +++ b/src/plugins/remotelinux/linuxdevice.h @@ -30,6 +30,7 @@ public: ProjectExplorer::DeviceTester *createDeviceTester() const override; ProjectExplorer::DeviceProcessSignalOperation::Ptr signalOperation() const override; ProjectExplorer::DeviceEnvironmentFetcher::Ptr environmentFetcher() const override; + bool usableAsBuildDevice() const override; QString userAtHost() const;