This guide demonstrates how to deploy an Eclipse IDE on a GNU/Linux system and set it up for general-purpose and embedded development.
We do not support host OS other than GNU/Linux; however, the provided instructions might just work for Mac too (no guarantees though). If you're keen on running another OS, please consider using the Bistromathic VM, where the development environment is already pre-configured.
This guide has been verified against Eclipse Oxygen running on a GNU/Linux distribution based on Ubuntu 16.04, but the guide should be applicable to newer versions as well (possibly with minor modifications).
If you have any suggestions, please submit them to the Zubax Forum.
If you're running a Debian-based distribution (such as Ubuntu or Mint), execute the following command:
sudo apt-get install default-jre
If you're using a different distribution, refer to its documentation to find out how to install a Java runtime environment.
Download the self-installer from eclipse.org.
Launch the downloaded installer and select the option for Eclipse IDE for C/C++ Developers.
When prompted, select the installation directory under
/home/pavel/opt/eclipse/cpp-oxygen, where the last part may vary depending on the specific version that is being installed.
Once the installation is finished, close the installer. There is no need to launch Eclipse right away.
Technically, this part is optional, because Eclipse can be directly invoked from the command line. However, that is unlikely to be convenient enough for most people. Therefore, we recommend to configure the application launcher of your desktop environment so that it provides a nice button for the freshly installed Eclipse.
It is recommended to configure the launcher so that the IDE is started from an interactive shell, as that would allow the IDE to reference the environment variables specified in the user's shell profile file (for example,
~/.bashrc). If this recommendation is omitted, the user will have to configure the environment variables that Eclipse needs access to globally, which may be less convenient, and therefore that approach is not recommended.
In order to make the launcher always launch Eclipse from an interactive shell, use the following command (where the path to the executable may be different depending on your installation):
bash -ic "/home/pavel/opt/eclipse/cpp-oxygen/eclipse/eclipse"
If you're not using Bash as your system shell, you know what to do.
The following screenshot demonstrates how to set up the launcher for KDE. Other desktop environments (e.g. Gnome) should provide similar configuration options.
Now you can launch Eclipse and proceed to plugin installation. Eclipse will ask you which workspace to use; for now you can use the default workspace location or any other existing workspace if you prefer so (if you chose to use the default workspace, you can freely delete it at the end of this guide in order to not pollute your file system).
Eclipse Marketplace.... Using the search bar, find and install at least the following plugins:
*.debug.*should be installed as well. It should be safe to install additional components even if they are not going to be used.
If Eclipse complained about its inability to install the GNU MCU Eclipse plugin, proceed with installation of other packages as if nothing happened, then restart the IDE and perform the following steps:
At this point, your Eclipse IDE should be ready for use. Refer to the adjacent guides to find out how to configure your first workspace.