Tux Guitar

Problems

Subject undefined symbol: jack_client_open



Author Message
jarjar
Post: Nov 11th 2009 at 11:41 AM

Hi all :)

I've got problem with running Tuxguitar on Archlinux.

TG installed from repos

$ tuxguitar
/opt/java/jre/bin/java: symbol lookup error: /usr/lib/tuxguitar/libtuxguitar-jack-jni.so: undefined symbol: jack_client_open


I don't use jack - but alsa.

Any ideas where may be the source of the problem?


Back to Top
 
Julian
Post: Nov 11th 2009 at 12:53 PM

It seems that you don't have jack installed, that is a requirement of tuxguitar-jack plugin

In official releases we didn't distribute this plugin enabled to just don't force users to install dependencies.

but i'm not sure how this archlinux package was made.
isn't tuxguitar-jack a different package than tuxguitar ?


Back to Top
 
jarjar
Post: Nov 12th 2009 at 7:55 AM

Hi

Thanks for reply.

unfortunately there is no such package in Arch.
http://www.archlinux.org/packages/?q=jack

There is the package "jack-audio-connection-kit"
which is installed on my system. I also have jackd installed - I suppose it was a dependency for some gnome packages.

Do you think, that changing from alsa to jack would do the trick?
Or maybe installing the official package could solve the problem cause I woudn't like to play with jack.


Back to Top
 
Julian
Post: Nov 12th 2009 at 10:56 AM

So,
It you have "jack-audio-connection-kit" installed, i think you have the jack libraries.

And now i'm thinking that if you wouldn't have libjack.so installed.. the error should say something like "UnsatisfiedLinkError", that is not your case..

But i think that the tuxguitar-jack native library ( libtuxguitar-jack-jni.so ) could be built without link to jack..

I'm testing here, build this library without the param: `pkg-config --libs jack`

As Jack's faq recommends:
http://jackaudio.org/faq ( see at "What do I need to do to link to JACK?" )

And i get your same error message if i don't link it.

So to be clear, it seems that the library was nof succesfully linked in the build process.

where can i see the makefile used to build this library in archlinux ?


Back to Top
 
jarjar
Post: Nov 12th 2009 at 12:45 PM

I wonder if this may help:

http://repos.archlinux.org/wsvn/community/tuxguitar/repos/community-i686/


Back to Top
 
Julian
Post: Nov 12th 2009 at 12:57 PM

I'm not really familiarized with PKGBUILD files,
but if you see in the content:
http://repos.archlinux.org/wsvn/community/tuxguitar/repos/community-i686/PKGBUILD

I see that libtuxguitar-jack-jni.so is never linked with libjack.

At this line:
gcc -shared -o libtuxguitar-jack-jni.so org_herac_tuxguitar_jack_JackClient.o -L/usr/lib -lasound

"-lasound" is telling the linker, to link libtuxguitar-jack-jni.so with asound ? ( alsa sound library )..

it should be -ljack.. or as i told before `pkg-config --libs jack`

I beleive that this line was copied from tuxguitar-alsa build scripts, that yes needs link to asound.
but the jack plugin needs to be linked only with jack, and never with alsa ( you can run jack under OSS, without have ALSA installed )


Back to Top
 
jarjar
Post: Nov 13th 2009 at 11:21 AM

So in easy words package seems to be built in a wrong way?

Installing official version could solve the problem :) Anyway I'll try in the evening as soon as I'm at home with my computer.


Back to Top
 
Julian
Post: Nov 14th 2009 at 2:57 PM

Yes. as i see, these build file is wrong.

in a quick look i see these errors:
* libtuxguitar-jack-jni.so, isn't linked with jack libraries. and it's linked with alsa while it's not a dependency.

* libtuxguitar-oss-jni.so, it's also linked with alsa. but OSS don't depends on alsa ( it's at same level )

* TuxGuitar-fluidsynth.. while the build script is compiling tuxguitar-fluidsynth.jar, it's not compiling the native library libtuxguitar-fluidsynth-jni.so ( that must be linked with libfluidsynth.so )

Are you a member of that community ?? if yes, could you please report this bug ?


Back to Top
 
jarjar
Post: Nov 15th 2009 at 9:15 AM

Hello after 2 days :)

Unfortunately I didn't have time to deal with computer issues lately but after todays upgrade the problem is solved :D.

I didn't report a bug - maybe someone else did :)

Thanks for helping :)


Back to Top
 
koyer
Post: Nov 24th 2009 at 2:27 PM

Rename libtuxguitar-jack-jni.so use to sudo mv /usr/lib/tuxguitar/libtuxguitar-jack-jni.so /usr/lib/tuxguitar/libtuxguitar-jack-jni.so2

Run tuxguitar and you change tuxguitar sequencer, midi port by java sound synthesizer

No more problem with jack!!!


Back to Top
 
Julian
Post: Nov 24th 2009 at 3:02 PM

I don't think that it's the right solution..
you are forcing one error (unsatisfiedlinkerror) to remove other ?..
if you want to uninstall the plugin, you have to remove "plugins/tuxguitar-jack.jar"

So if the plugin don't loads, it will not try to load native libraries. but renaming the .so file you are only forcing an error.

The real error here is that it's not linked right with jack.
but even if it would be right, it shouldn't be installed as default.
The idea of plugin support, was to have pluggeable features, independant of the main application, so users could add/remove plugins without rebuild it
but if the application is redistributed in a single package with all plugins included, then it force users to install dependencies of all plugins.


Back to Top
 
Cristian Gómez Alvarez
Post: Jan 29th 2010 at 2:29 AM

I found a solution for this problem on my Arch Installation by installing Sun's JRE and making what koyer said:
Run tuxguitar and you change tuxguitar sequencer, midi port by java sound synthesizer


Back to Top
 
Julian
Post: Feb 4th 2010 at 12:05 PM

It's same as i said before... it's not a solution, you are hidding the problem but not fixing it.. if some day you want to use Jack features you will not able to do that..

That build script is wrong, and it have to be fixed.. otherwise this problem will continue.


Back to Top