Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Installing Eclipse C++ IDE(Technical problems with the installer)
Installing Eclipse C++ IDE [message #1811175] Wed, 28 August 2019 07:46 Go to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
I am working on IOT projects and it has been suggested that Eclipse may be a suitable alternative IDE to Arduino IDE. Rather than installing the ancient version from the Ubuntu repository, I navigated to the Eclipse website to try an download the software. I downloaded and extracted the installer package.

Firstly, it is unclear to me whether I need to install the Eclipse IDE for Java Developers AND Eclipse IDE for C/C++ Developers, or just the latter. At this time I am interested only in C++ development. I may consider Java and maybe Javascript etc later.

Secondly, none of the packages seem to install. I am accepting the default address in my home directory and I get an error:

Quote:
Internal error
No more handles


The 'Update' bit gives me and 'Emergency Update dialog and then the same error. As a result I cannot install anything. I really don't want to install the old verion from the Ubuntu repo if I can avoid it. I am running on Linux Mint 19.2 Cinnamon.

The error details are as follows:

org.eclipse.swt.SWTError: No more handles
	at org.eclipse.swt.SWT.error(SWT.java:4725)
	at org.eclipse.swt.SWT.error(SWT.java:4614)
	at org.eclipse.swt.SWT.error(SWT.java:4585)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:532)
	at org.eclipse.swt.widgets.Control.drawBackground(Control.java:235)
	at org.eclipse.swt.widgets.Control.windowProc(Control.java:6800)
	at org.eclipse.swt.widgets.Display.windowProc(Display.java:6132)
	at org.eclipse.swt.internal.gtk.GTK._gtk_main_do_event(Native Method)
	at org.eclipse.swt.internal.gtk.GTK.gtk_main_do_event(GTK.java:4166)
	at org.eclipse.swt.widgets.Display.eventProc(Display.java:1429)
	at org.eclipse.swt.internal.gtk.OS._g_main_context_iteration(Native Method)
	at org.eclipse.swt.internal.gtk.OS.g_main_context_iteration(OS.java:1585)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4661)
	at org.eclipse.oomph.setup.internal.installer.AbstractSimpleDialog.show(AbstractSimpleDialog.java:155)
	at org.eclipse.oomph.setup.internal.installer.InstallerApplication.run(InstallerApplication.java:250)
	at org.eclipse.oomph.setup.internal.installer.InstallerApplication.start(InstallerApplication.java:408)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:203)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:137)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:107)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:255)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:660)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:597)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1468)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1441)


java --version returns:

openjdk 11.0.4 2019-07-16
OpenJDK Runtime Environment (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3)
OpenJDK 64-Bit Server VM (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3, mixed mode, sharing)

Re: Installing Eclipse C++ IDE [message #1811215 is a reply to message #1811175] Wed, 28 August 2019 17:40 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4501
Registered: July 2009
Senior Member

James Doohan wrote on Wed, 28 August 2019 03:46

Firstly, it is unclear to me whether I need to install the Eclipse IDE for Java Developers AND Eclipse IDE for C/C++ Developers, or just the latter. At this time I am interested only in C++ development. I may consider Java and maybe Javascript etc later.

You can start with what you need now and add more to it later. If you're having problems with the installer, try downloading the package directly from https://www.eclipse.org/downloads/packages/release/2019-06/r/eclipse-ide-cc-developers and unpacking it in a location where your user has write access, like somewhere under the home directory.


_
Nitin Dahyabhai
Eclipse Web Tools Platform

[Updated on: Wed, 28 August 2019 17:42]

Report message to a moderator

Re: Installing Eclipse C++ IDE [message #1811342 is a reply to message #1811215] Sat, 31 August 2019 16:20 Go to previous messageGo to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
Thank you. I have tried the direct link you gave me above. I have unpacked the download package ls
to a directory with user privileges (and clicked on the executable to run it but unfortunately it crashes.

These are the steps:
- select the default workspace directory and click 'Lanuch'. This ,brings up the IDE.
- select 'Create a new C/C++ project
- select Arduino C++ sketch, click 'Next'
- give the project a name, click 'Finish'

A dialogue pops up with the title 'Multiple Problems have ocurred'. It lists two:

Unhandled event loop exception
Unhandled event loop exception

Unfortunately I can't copy the information under Show Error Log. Neither can I expand the box to show all of it or scroll down. I can't drag the top of the box upwards to expand it ether. I can only say at this point that the error relates to Plug-in org-eclipse.ui. There is more as I can see the top half of the next line in the log, but I can't scroll further down to view it - and I am using a pretty large monitor.

If I click Ok, the first time, the dialog just disappears momentarily and then comes back. The second time, the application crashes.

I appreciate that this is a freely available open source application, but I have already seen enough to make me rather concerned. Since it has a fatal problem right at launch so that I can't even get to test it. I was even more concerned to discover that if I ran it from the terminal with sudo ./eclipse then it would seem to run fine. I definitely do not want to run the application with system privileges. I am hoping that there is a simple solution that will allow me to run Eclipse as user?

I am guessing that the developers perhaps test exclusively on Ubuntu Linux when testing for the Linux platform. Linux Mint is Ubuntu under the hood, and most Ubuntu packages run without problems on Mint. However, there are differences and I am using the Cinnamon desktop, not Gnome, so perhaps there is some sort of unforeseen problem. I am willing to help and debug the issue if someone is willing to guide me and give me some idea where to look.

[Updated on: Sat, 31 August 2019 16:29]

Report message to a moderator

Re: Installing Eclipse C++ IDE [message #1814008 is a reply to message #1811342] Sun, 01 September 2019 04:56 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33252
Registered: July 2009
Senior Member
Generally for single user use, you would unpack it into your home folder somewhere; somewhere with read-write access for the user. For multi-user use, you could unpack it anywhere, but that location must be read-only for the users.

The Error Log view is helpful for looking at stack traces. That information is stored persistently in <workspace-location>/.metadata/.log so you can view it with a text editor; you can delete that file and launch Eclipse again to create a new clean log. I assume your system has GTK 3 installed because the current releases of Eclipse only support GTK 3 and not GTK 2.


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Installing Eclipse C++ IDE [message #1814012 is a reply to message #1814008] Sun, 01 September 2019 09:54 Go to previous messageGo to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
It is installed in a directory in my user home so should have read/write privileges. I checked and also have GTK3 installed.

I cleared the workspace and started again and have attached my error log. I expect that the error messages have meaning in the context of the application but they are not clear enough for me to be able to understand where the problem is. I hope that someone can help me understand what these means:

!ENTRY org.eclipse.launchbar.core 2 0 2019-09-01 10:47:04.559
!MESSAGE Enablement expression is missing for descriptor type org.eclipse.cdt.dsf.gdb.gdbRemotedescriptorType

!ENTRY org.eclipse.launchbar.core 2 0 2019-09-01 10:47:04.559
!MESSAGE Enablement expression is missing for config provider for org.eclipse.cdt.dsf.gdb.gdbRemotedescriptorType

!ENTRY org.eclipse.cdt.core 1 0 2019-09-01 10:47:21.879
!MESSAGE Indexed 'Test1' (1 sources, 0 headers) in 0.3 sec: 2 declarations; 0 references; 1 unresolved inclusions; 0 syntax errors; 0 unresolved names (0%)

!ENTRY org.eclipse.ui 4 0 2019-09-01 10:47:22.995
!MESSAGE Unhandled event loop exception
!STACK 0

It seems that something is missing (or perhaps inaccessible), but I have no idea what?
  • Attachment: log
    (Size: 88.64KB, Downloaded 152 times)

[Updated on: Sun, 01 September 2019 09:55]

Report message to a moderator

Re: Installing Eclipse C++ IDE [message #1814047 is a reply to message #1814012] Mon, 02 September 2019 10:07 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33252
Registered: July 2009
Senior Member
I see,

!MESSAGE Error occurred during status handling
!STACK 0
org.eclipse.swt.SWTError: No more handles
at org.eclipse.swt.SWT.error(SWT.java:4725)
at org.eclipse.swt.SWT.error(SWT.java:4614)
at org.eclipse.swt.SWT.error(SWT.java:4585)

I wonder if somehow your process is not being allocated enough handle resources by your operating system.

It sounds a bit like this:

https://unix.stackexchange.com/questions/94497/org-eclipse-swt-swterror-no-more-handles-gtk-init-check-failed-while-runnin


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Installing Eclipse C++ IDE [message #1814058 is a reply to message #1814047] Mon, 02 September 2019 12:52 Go to previous messageGo to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
Ed, thanks I had a look at that thread. It might have been helpful on the part of the Eclipse project to have provided some information on the dependencies required. I can find absolutely nothing on the website, and although I do see some information, predominantly about Java in the readme, there seems to be no mention of GTK anywhere. The thread seems to suggest that it is possible to run Eclipse on GTK2.0 or GTK3.0. GTK3 seems to be composed of a lot of different modules and I'm not sure really what is required.

Here is a list of GTK3 "stuff" on my Linux system:

$ dpkg -l |grep libgtk-3
ii  libgtk-3-0:amd64                                            3.22.30-1ubuntu4                                    amd64        GTK+ graphical user interface library
ii  libgtk-3-bin                                                3.22.30-1ubuntu4                                    amd64        programs for the GTK+ graphical user interface library
ii  libgtk-3-common                                             3.22.30-1ubuntu4                                    all          common files for the GTK+ graphical user interface library
ii  libgtk-3-dev:amd64                                          3.22.30-1ubuntu4                                    amd64        development files for the GTK+ library

Here is the Java version information:

$ java --version
openjdk 11.0.4 2019-07-16
OpenJDK Runtime Environment (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3)
OpenJDK 64-Bit Server VM (build 11.0.4+11-post-Ubuntu-1ubuntu218.04.3, mixed mode, sharing)

There was some discussion in the Readme about Java 9, but I presume 11 should be fine?

I'm trying to run Eclipse locally on the desktop so the SSH information on the thread should not even come into it. The machine I have has decent specs, 500Gb SSD + 1Tb SSD, 8Gb RAM, i7 processor, NVIDIA graphics. Its a second generation processor so a bit old by todays standards, but still very adequate and usually does everything I throw at it without any lag.

I tried forcing GTK3 as shown here:

https://coffeeorientedprogramming.wordpress.com/2014/10/27/how-to-tell-if-you-are-running-eclipse-on-gtk2-or-on-gtk3/

i.e.,

export SWT_GTK3=0
./eclipse

Sadly I got exactly the same problem.
Its a bit disheartening not to even be able to get "off the ground" so to speak.

UPDATE: I have test VM running Mint 19. It was running 19.1 so I upgraded it to 19.2 and tried installing Eclipse using the installer from their website on that VM. The good news is that the installer did run and I was able to install Eclipse on the VM. It seems to launch just fine so at least I can now have a look at it. Evidently then, it will run on Linux Mint 19.2 although being on a VM it will run somewhat slower, but curious that it will not run on the host machine.

UPDATE2: I have found a solution. I tried the installer again, but this time launching it from a terminal. There was a message relating to the setting of the GTK_IM_MODULE environment variable. It was set to GTK_IM_MODULE=xim, and the message was informing me that this is not supported and that it should changed it to GTK_IM_MODULE=ibus. I changed it using export 'GTK_IM_MODULE=ibus' and ran the installer again and this time it worked! Ditto for the eclipse launcher.

Upon further investigation on the VM this variable is not set at all. I have no idea what effect this change might have on other installed applications so I made a simple wrapper shell script and named it eclipse.sh like this:

 #!/bin/sh
export GTK_IM_MODULE=ibus
~/bin/eclipse/cpp-2019-062/eclipse/eclipse

This first sets the variable to the value that is required to run Eclipse and then launches Eclipse. I can launch Eclipse using the script and it now starts and runs fine. However, for the life of me I can't find where to change this variable to test un-setting it or to make the change permanent. Its not in ~/.profile, ~/.bashrc or /etc/profile. Anyway, at least I have a workaround.

[Updated on: Mon, 02 September 2019 16:25]

Report message to a moderator

Re: Installing Eclipse C++ IDE [message #1814069 is a reply to message #1814058] Mon, 02 September 2019 20:20 Go to previous messageGo to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
Not sure that I can use this for building Arduino project after all. I seem to be struggling. To be fair I have only had maybe 30 minutes to look around it, and every new application takes a bit of time to get familiar with, but my overwhelming impression is one of confusion. It is far more complex product so I didn't expect it to be as simple and straightforward as the Arduino IDE, but I didn't expect it to be quite so unintuitive. I did find an online video via the Arduino | Instruction videos menu, but unfortunately this didn't really answer any of my questions about selecting boards and uploading sketches. I was initially perplexed by the fact that there is no 'Open Project' option until I eventually realised that the opening "Welcome" dialogue could simply be closed and the IDE environment was hiding behind it! I installed the Sloeber Arduino plugin and imported an Arduino project which compiles cleanly in both Arduino IDE (with highest the warning level) and QT, but Eclipse shows 69 errors! Incidentally regarding that plugin, which version should one install? In another example of confusion, there are two versions with same description, version number but significantly different file sizes. Although I can select a group of boards by version number via Arduino | Preferences | Platforms and Boards, I see no options to build or deploy to a specific board, e.g. Uno or Mega. On top of that, Eclipse does not recognize my imported project as an Arduino project despite the .ino extension of the main project file! Now which file does the IDE recognize as the "main" project file? I couldn't find any means to determine that. Maybe the problem is the included .h and .cpp library files. Managing an expanding project was the reason for my looking for a more developed IDE and if file inclusions is the issue, then that would preclude my being able to use it until the issue is resolved.

There do seem to be some useful features like the list of class objects and project files and I am sure a lot of work went into development. Perhaps Eclipse is better at managing Java and C++ projects and perhaps the Sloeber plugin is at an early development stage. Equally, perhaps I still have a lot to learn about the IDE, but my overall impression of the IDE is one of confusion and lack of intuitiveness that I suspect will add up to a rather steep learning curve. On the plus side it is available free of charge and continues to be developed, so I am sure this will improve over time. I may persevere a bit longer, but I regret to say that this is not looking very promising and I may have to use something else in the meantime and wait for further developments.

Thank you to those who provided some feedback to my request.

[Updated on: Mon, 02 September 2019 20:50]

Report message to a moderator

Re: Installing Eclipse C++ IDE [message #1814072 is a reply to message #1814069] Tue, 03 September 2019 05:01 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33252
Registered: July 2009
Senior Member
It's best to post detailed questions about C/C++ tools to the CDT forum:

https://www.eclipse.org/forums/index.php?t=thread&frm_id=80

You'll see there are number of threads about Arduino. A close friend of mine very recently started playing around with Arduino using CDT and has been successful with that. He did mention that initial configuration was quite challenging.


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Installing Eclipse C++ IDE [message #1814192 is a reply to message #1814072] Thu, 05 September 2019 12:53 Go to previous messageGo to next message
James Doohan is currently offline James DoohanFriend
Messages: 10
Registered: August 2019
Junior Member
Ok, thanks. Will post a request on there.
Re: Installing Eclipse C++ IDE [message #1816150 is a reply to message #1811175] Tue, 22 October 2019 14:56 Go to previous messageGo to next message
Dag Rende is currently offline Dag RendeFriend
Messages: 1
Registered: July 2009
Junior Member
I suggest you take a look at PlatformIO. It is a multi platform/architecture/library development environment. You can use it from the command line, and from a lot of tools - eclipse for example. It can automatically download tools and libraries for a huge number of processors. Ardiono is one of them.
The default integration is to VSCode. I have used it with Atom for a long time and it is wonderful.
IT works also with the new ARM based arduinos that are so fast they run loops around an old arduino.
Re: Installing Eclipse C++ IDE [message #1816151 is a reply to message #1816150] Tue, 22 October 2019 15:05 Go to previous message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4501
Registered: July 2009
Senior Member

It also integrates with Eclipse.

https://docs.platformio.org/en/latest/ide/eclipse.html


_
Nitin Dahyabhai
Eclipse Web Tools Platform
Previous Topic:Eclipse JAVA EE for Linux 32bit
Next Topic:JRE Oracle Corporation/13.0.1 is not supported, advanced source lookup disabled
Goto Forum:
  


Current Time: Sat Nov 09 03:56:01 GMT 2024

Powered by FUDForum. Page generated in 0.08668 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top