添加远程 Linux 设备

在通用 Linux 设备和Qt Creator 之间创建连接,以便在这些设备上运行、调试和分析应用程序。

设备偏好设置 "设备 "选项卡中的远程 Linux 设备

远程 Linux 设备首选项

使用向导添加设备

要使用向导添加Remote Linux Device

  1. 转到首选项>Devices >Devices
  2. 选择Add >Remote Linux Device >Start Wizard

    连接数据向导

  3. The name to identify this configuration 中,输入连接名称。
  4. The device's host name or IP address 中,输入设备的主机名或 IP 地址。这将成为%{Device:HostAddress} 变量的值。
  5. The device's SSH port number 中,输入 SSH 连接的端口号。这将成为%{Device:SshPort} 变量的值。
  6. The username to log into the device 中,输入登录设备和运行应用程序的用户名。这将成为%{Device:UserName} 变量的值。
  7. 选择Next ,打开Key Deployment 对话框。

    密钥部署对话框

  8. Private key file 中,选择用于身份验证的私钥文件。这将成为%{Device:PrivateKeyFile} 变量的值。
  9. 如果没有公私钥对,请选择Create New Key Pair 。有关更多信息,请参阅生成 SSH 密钥
  10. 选择Deploy Public Key 将公钥复制到设备。
  11. 选择Next 创建连接。

要更改设备首选项,请转至首选项>Devices >Devices ,然后在Device 中选择设备。

手动添加设备

要不使用向导添加设备,请在Add 按钮的下拉菜单中选择Remote Linux Device

另请参阅 如何:为远程 Linux 开发使用 GDB 远程调试为远程 Linux 设备开发远程 Linux 部署配置

Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.