Remote projects on RT-Druid
Introduction
There are some scenarios in which the board has the processing capabilities for running a full compiler for native building.
This is the case, for example, of powerful multi-core ARM SoCs running a Linux distribution, where we may use a hypervisor like Jailhouse for running ERIKA alongside Linux.
In such circumstances, having a native compilation of ERIKA on the target could be easier than cross-compiling using a host machine.
Unfortunately, the Eclipse IDE requires an x86 platform with a fair amount of resources (in terms of both processing and memory).
This guide, therefore, explains how to set-up Eclipse on a host x86 machine, leaving the compilation process on the target.
Handling a remote project can be done manually, of course, by transferring the built files through ftp/scp/rsync or by mounting locally the target filesystem using nfs/sshfs.
However, this guide explains how to use the remote project feature of Eclipse, which internally relies on the sftp protocol.
Important: the code of ERIKA must be available on the target because it is needed by the build process. Similarly, all the tools and the environment variables needed by the building process must be available/set on the target.
Plugins installation
To add the support for remote projects, it is necessary to install two plugins:
- Remote System Explorer User Actions
- TM Terminal
These plugins can be easily installed through the typical steps for installing a plugin:
-
Menu
→Help
→Install new Software
- Select the update site of Eclipse (e.g., neon)
- Search General Purpose Tools
- Select the following plugins:
- Remote System Explorer User Actions
- Remote System Explorer User Actions
which adds support for remote projects
- TM Terminal
- TM Terminal
which allows opening an SSH shell within Eclipse
- Click in
Next
to finish the installation, and then restart Eclipse
Notes
- Currently, Acceleo is not capable of generating files on top of the Eclipse virtualization. The generation is therefore done in two steps:
- Acceleo generates files in a directory within the local workspace:
.metadata/.plugins/com.eu.evidence.rtdruid3.oil.cdt.ui/oil_gen
- RT-Druid copies the files from the local to the remote directory (using the Eclipse virtualization)
- Acceleo generates files in a directory within the local workspace: