Tux Guitar

Problems

Subject [ubuntu 64bit] tuxguitar work only with console



Author Message
tareo
Post: Nov 17th 2007 at 6:15 PM

hi!
when I execute:
/opt/tuxguitar-0.9.1/tuxguitar
on console...it works.
I create an element with alacarte
and I have this error:
Exception in thread "main" java.lang.UnsatisfiedLinkError: /opt/tuxguitar-0.9.1/lib/libswt-pi-gtk-3232.so: Can't load IA 32-bit .so on a AMD 64-bit platform
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1751)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1676)
at java.lang.Runtime.loadLibrary0(Runtime.java:822)
at java.lang.System.loadLibrary(System.java:993)
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:123)
at org.eclipse.swt.internal.gtk.OS.(OS.java:22)
at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:63)
at org.eclipse.swt.internal.Converter.wcsToMbcs(Converter.java:54)
at org.eclipse.swt.widgets.Display.(Display.java:126)
at org.herac.tuxguitar.gui.TuxGuitar.displayGUI(Unknown Source)
at org.herac.tuxguitar.gui.TuxGuitar.main(Unknown Source)

so I would like to know why it doesn't take:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/jni/:/opt/tuxguitar-0.9.1/lib/
export CLASSPATH=$CLASSPATH:/usr/lib/java/swt.jar:/opt/tuxguitar-0.9.1/lib/swt

on ~/.bashrc ???
How to execute tuxguitar with gnome menu?
thanks for your help!


Back to Top
 
Julian
Post: Nov 17th 2007 at 6:54 PM

Hi,
libswt-pi-gtk-3232.so is already taked..
the problem, is the library was builder for 32-bit but you have a 64 bit Arch.

You say "on console...it works.", So i think you have 2 swt version installed on your system..

1*
your CLASSPATH say: /usr/lib/java/swt.jar
I'm sure you have "libswt3.2-gtk-java" and "libswt3.2-gtk-jni" packages installed from repositories for you 64 bit.
and libswt3.2-gtk-jni package add native libraries to:
/usr/lib/jni/

2*
tuxguitar, already include SWT library ( see at /opt/tuxguitar-0.9.1/lib ), but you downloaded a 32 bit version of tuxguitar..

So now take a look at your library path:
/usr/lib/jni/:/opt/tuxguitar-0.9.1/lib/
the last "/opt/tuxguitar-0.9.1/lib/" is overriden the first /usr/lib/jni/.. so you are loading the 32 bit *.so files..

The same happend with the CLASSPATH and swt.jar

So you should do this:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/jni/
export CLASSPATH=$CLASSPATH:/usr/lib/java/swt.jar


Well, i'm not sure what "alacarte" is, but i don't think you need edit your .bashrc, i think you only need modify the "/opt/tuxguitar-0.9.1/tuxguitar" script file. and set the paths for your 64 bit version of SWT..
and remove /opt/tuxguitar-0.9.1/lib/swt* because it's only taking disk space


Back to Top
 
tareo
Post: Nov 17th 2007 at 7:13 PM

thanks.
Yes I have remove
#export JAVA=/usr/lib/jvm/java-1.5.0-sun-1.5.0.13/bin/java
#export JAVA_HOME=/usr/lib/jvm/java-1.5.0-sun-1.5.0.13
#export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/jni/:/opt/tuxguitar-0.9.1/lib/
#export CLASSPATH=$CLASSPATH:/usr/lib/java/swt.jar:/opt/tuxguitar-0.9.1/lib/swt$

in .bashrc (like said on doc/README)
and I put:
JAVA=/usr/lib/jvm/java-1.5.0-sun-1.5.0.13/bin/java
JAVA_HOME=/usr/lib/jvm/java-1.5.0-sun-1.5.0.13
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/jni/
CLASSPATH=$CLASSPATH:/usr/lib/java/swt.jar

in /etc/environment and I remove call of tuxguitar lib and it works.


Back to Top