Szenario
After upgrading TuxGuitar to version 1.3.2, it doesn't start and doesn't throw any errors or execptions either, when executed in a shell. I'm using the package called tuxguitar-1.3.2-4 of my distro (Arch Linux), but i got the same issue with every version from the official download page and with the archive from sourceforge.net.
Troubleshooting attempts
First i tried to solve the problem by reinstalling TuxGuitar with no luck. Likewise deleting config files or trying to start it as another user weren't succesfull.
After a little bit of research, i came across an issue discussed at the TuxGuitar Forum and tried to start it, as it is suggested in Julian's first post:
java -cp tuxguitar.jar:lib/swt.jar org.herac.tuxguitar.gui.TGMain
This was getting me an error that the main class cannot be found or loaded. I've replaced gui with app after checking tuxguitar.jar contents. So i got the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: org/herac/tuxguitar/player/base/MidiPlayerException
at org.herac.tuxguitar.app.TGMain.main(TGMain.java:13)
Caused by: java.lang.ClassNotFoundException: org.herac.tuxguitar.player.base.MidiPlayerException
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 1 more
Hi, That was a very old post, older than tuxguitar-1.3.2 release. Current command line is different
Try edit tuxguitar.sh and replace "TGMainSingleton" to "TGMain" and let me know if it works please.
After setting Java environment to Version 8, i changed line 38 back to:
MAINCLASS=org.herac.tuxguitar.app.TGMainSingleton
So this doesn't seem to be necessary any more, but what is right? If TGMainSingleton has to be replaced with TGMain, then it needs to be corrected in the Arch Linux package.
Both are TuxGuitar launchers.
"TGMain" always fires a new application instance
"TGMainSingleton" tries to keep only one running instance
Since 1.3 we have "tab" support, so we created the singleton launcher to be able to double-click a file and open a new tab in current instance instead of create a new one.
To do that, TGMainSingleton opens a local socket to communicate with running instance (if there is one). i suggested you replace "TGMainSingleton" with "TGMain" only to make sure the problem wasn't in that socket.
So now you can back to TGMainSingleton (or no if you want multiple instances).
In official releases we use TGMainSingleton.
This provides the following error message:
Seems to be related to swt version. Installed package is: swt-4.6-1, but there's no upgrade or downgrade opportunity.
Last edit: zwenny 2016-08-26
This is because the java version used to compile the package. I think it was java 8.
So try upgrade java in your dist to 8.
Alternatively you can get it as portable folder:
http://www.oracle.com/technetwork/java/javase/downloads/jre8-downloads-2133155.html
Just download a .tar.gz package and uncompress it.
Then exec:
export JAVA_HOME=/where_you_uncompressed_the_folder
./tuxguitar.sh
Sorry for the late reply.
I've installed Java 8, as you can see:
Name : jre8-openjdk
Version : 8.u102-1
Description : OpenJDK Java 8 full runtime environment
Architecture : x8664
URL : http://openjdk.java.net/
License : custom
as well as OpenJDK Java 7. But Version 8 it wasn't set as default Java environment:
archlinux-java statusAvailable Java environments:
java-7-openjdk/jre (default)
java-8-openjdk
So i had to set java-8-openjdk/jre as default Java Runtime by executing:
archlinux-java set java-8-openjdk/jre(source: Java - ArchWiki)TuxGuitar source code is jdk >= 1.5 (java 5 or later) compat.
But latest releases depends on jdk 1.8 because an error at build scripts (fixed now in development version).
Thank you for your help and troubleshoot guidance! :)
As i can remember, there have been some issues with starting TuxGuitar on Arch before. The changed link entry in my startmenu was a remnant of this. The execution parameter was set to: env SWTGTK3=0 tuxguitar %F -Dorg.eclipse.swt.internal.gtk.cairoGraph instead of tuxguitar %F in order to run it without GTK3. (See: TuxGuitar 1.3.2 stuck at splash due to GTK problems / Newbie Corner / Arch Linux Forums
Last edit: zwenny 2016-08-29