3
votes

I am running ubuntu 15.10. I am trying to execute a java GUI program under eclipse that imports a ton of libraries including javafx and google map libraries.

The java program fails to execute and gives the error:

Gtk-Message: Failed to load module "unity-gtk-module"

I have googled the error message " Gtk-Message: Failed to load module "unity-gtk-module" " - but none of the solutions I have found on stackoverflow or through google appear to work for me.

Any ideas on how to diagnose and fix this error?

3
Does sudo apt-get-install unity-gtk3-module fix the problem? If not, try apt-cache search unity-gtk-module (which suggests that there is also an unity-gtk2-module). What program are you trying to run? From where did you obtain it? And have you satisfied its' dependencies?Elliott Frisch
I tried sudo apt-get install unity-gtk3-module - command response is that unity-gtk3-module is already latest version.Pat Claffey
Do not know what the apt-cache search command does. It returns the following information: unity-gtk-module-common - Common files for GtkMenuShell D-Bus exporter unity-gtk-module-autopilot - GtkMenuShell D-Bus Autopilot testsPat Claffey
I got the java file from a Coursera course. This file is the starter code I need for assignments - so do not have control over java libraries. Its a mapping GUI using google map libraries and also javafx. The course developers do not give information on dependencies or specify any specific OS.Pat Claffey

3 Answers

0
votes

I got this error running java starter code for a Coursera course in Eclipse. I noticed errors in the java code - java error was "Lambda expressions are allowed only at source level 1.8 or above". I am using 1.8 JDK. Problem was that Java Compiler compliance level was set to 1.7 for the project in eclipse. I changed the compliance level to 1.8 and program ran without error.

0
votes
sudo apt-get install unity-gtk2-module:i386

Solved it for me. (Note: I was running x86 app on x64 system.)

0
votes

Below worked for my Ubuntu 16.04

sudo apt install unity-gtk3-module

My case is that even running emacs would trig that warning.