Tux Guitar

Problems

Subject tuxguitar start exception



Author Message
UweK
Post: Jun 21st 2008 at 4:48 PM

Hello,
I installed TuxGuitar 1.0 with under ubuntu 7.10 with .deb package.
When I try to start with the Applications menu, nothing happens. Starting in a console gives folling message:
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Control
at org.herac.tuxguitar.gui.TGMain.main(Unknown Source)
The trick with a start script like in other thread doesn't help.
Thank You for help...
Uwe


Back to Top
 
Julian
Post: Jun 21st 2008 at 5:00 PM

SWT libraries are missing.
did you install the package dependencies ??

what's the result of this line ?:
dpkg -l | grep libswt

if you are complety sure you have swt installed, please
show me the result of:
ls -ll /usr/lib/java/ | grep swt


Back to Top
 
UweK
Post: Jun 23rd 2008 at 3:47 PM

Hallo Julian,
I think swt is installed, no unsolved dependencies were reached at installation.
Here are the results of of your lines:
uwe@uwe-desktop:~$ dpkg -l | grep libswt
ii libswt3.2-gtk-gcj 3.2.2-3ubuntu3 Fast and rich GUI toolkit for Java, gtk2 (GC
ii libswt3.2-gtk-java 3.2.2-3ubuntu3 Fast and rich GUI toolkit for Java, gtk2 ver
ii libswt3.2-gtk-jni 3.2.2-3ubuntu3 Platform dependent files for libswt3.2-gtk-j
uwe@uwe-desktop:~$ ls -ll /usr/lib/java/ | grep swt
lrwxrwxrwx 1 root root 64 2008-05-03 21:43 swt3.2-gtk.jar -> ../eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar
lrwxrwxrwx 1 root root 14 2008-05-03 21:43 swt-gtk.jar -> swt3.2-gtk.jar
lrwxrwxrwx 1 root root 14 2008-05-03 21:43 swt.jar -> swt3.2-gtk.jar
uwe@uwe-desktop:~$
And now ?

Uwe


Back to Top
 
Julian
Post: Jun 23rd 2008 at 3:56 PM

It seems all is Ok.
does this file exists ?
/usr/lib/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar

Paste here the log of:
tuxguitar -i


you can try force the classpath:
export CLASSPATH=/usr/lib/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.2.2.v3236.jar
tuxguitar

Does it works ?


Back to Top
 
UweK
Post: Jun 24th 2008 at 3:42 PM

1. The file doesn't exist, it has another versionnumber:

uwe@uwe-desktop:/usr/lib/eclipse/plugins$ ls *swt*
org.eclipse.swt_3.3.2.v3349d.jar org.eclipse.swt.gtk.linux.x86_3.3.2.v3349.jar

2. the log:
uwe@uwe-desktop:/usr/lib/eclipse/plugins$ tuxguitar -i
Exception in thread "main" java.lang.NoClassDefFoundError: org/eclipse/swt/widgets/Control
at org.herac.tuxguitar.gui.TGMain.main(Unknown Source)
You see, the same...but
3. doing this:
uwe@uwe-desktop:/usr/lib/eclipse/plugins$ export CLASSPATH=/usr/lib/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.3.2.v3349.jar
uwe@uwe-desktop:/usr/lib/eclipse/plugins$ tuxguitar
...txguitar starts well !!!!

4. How can I get the right CLASSPATH into the startscript ? i simply added /usr/lib/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.3.2.v3349.jar to '##CLASSPATH' in the script and it worked also well, but ist this the right way ???

Uwe


Back to Top
 
Julian
Post: Jun 24th 2008 at 3:54 PM

ok,

> uwe@uwe-desktop:/usr/lib/eclipse/plugins$ tuxguitar -i
jeje, my fault.. i don't know how i told you exec that, if tuxguitar didn't start :)

> The file doesn't exist, it has another versionnumber
Well here is the problem.
it's a bug of the .deb package

To solve the problem you can do some things:
1* the best way, is by fixing the broken link.

swt3.2-gtk.jar is pointing to an inexisting file.
So you can re-make that link
First, remove the broken link (as root)
rm /usr/lib/java/swt3.2-gtk.jar -f

Then, make a new link (also as root):
ln -s /usr/lib/eclipse/plugins/org.eclipse.swt.gtk.linux.x86_3.3.2.v3349.jar /usr/lib/java/swt3.2-gtk.jar

Now it should make "swt.jar" link works:
swt.jar -> swt3.2-gtk.jar -> /org.eclipse.swt.gtk.linux.x86_3.3.2.v3349.jar

2* the second option, is by editing with any text editor
/usr/bin/tuxguitar
and replace where you see /usr/lib/java/swt.jar to the real swt path.
but it may work only for tuxguitar..
if you install any other swt application, you'll get the same problem.


Back to Top
 
UweK
Post: Jun 25th 2008 at 10:06 AM

It was also in my opinion, to repair the symlinks to the right swt file. Thank You for describing the link chain, i will set it so that all java applications using swt can work right. The problem is probably, that ubuntu installs an eclipse 3.2. version from its repositories and sets the links to the files of this version. But I needed for my work with eclipse the 3.3 release and had removed the old version and installed the new one from an original eclipse package.
But my primary problem is solved well and I thank a lot Julian for your kindly help !

Uwe


Back to Top
 
Rydwlf
Post: Jul 2nd 2010 at 10:56 PM

Thanks for the info, it shed light leading to the solution!

I got the same error when trying to start TuxGuitar 1.2 under Ubuntu 10.04. In my case the solution was to reinstall the libswt packages, so I'm posting it here in case it helps anyone.

Cheers,


Back to Top
 
just a guest
Post: Jul 17th 2010 at 9:49 PM

thank you very much Rydwlf, it helped me!


Back to Top
 
THX
Post: Aug 24th 2010 at 1:50 PM

Thank you, reinstalling libswt helped me too!


Back to Top
 
Anonymous
Post: Aug 26th 2010 at 1:26 AM

I'm running Ubuntu 10.04 as well and reinstalling libswt through Synaptic fixed tuxguitar for me as well. Thank you!


Back to Top
 
Anonymous
Post: Aug 29th 2010 at 3:03 AM

Reinstalling libswt through Synaptic fixed it here, too.


Back to Top
 
Ralf
Post: Oct 13th 2010 at 8:59 PM

Thanks guys - helped me, too. To be more specific: I've reinstalled "libswt-gtk-3.5-java" and it worked like a charm again (using tuxguitar 1.1 on Ubuntu 10.04)


Back to Top
 
Mathew
Post: Nov 22nd 2010 at 1:57 AM

THANK YOU! Re-installing libswe-gtk fixed my problems!


Back to Top
 
smile
Post: May 12th 2011 at 3:37 PM

+1
Re-installing libswe-gtk fixed my problems! :)
Simply Linux 5.0.2


Back to Top