1

I was trying to use Xuggler ( http://www.xuggle.com/ ) with play! framework. I'm using Mac OSX and also created the ~/.MacOSX/environment.plist file with xuggler path. I also set these in my ~/.bashrc

export XUGGLE_HOME=/usr/local/xuggler
export LD_LIBRARY_PATH=$XUGGLE_HOME/lib

I put all the jars in the /lib folder of my play! application and updated the dependencies.yml like the following -

require:
    - play
    - provided -> xuggle-xuggler

repositories:
    - provided:
        type:       local
        artifact:   "${application.path}/lib/xuggle-xuggler.jar"
        contains:
            - provided -> *

BTW, I also ran play dependencies and it is still giving this error -

UnsatisfiedLinkError occured : no xuggle-xuggler in java.library.path

How can I fix this?

Rifat
  • 7,628
  • 4
  • 32
  • 46

1 Answers1

1

This error points to a problem with linking to a DLL file, so I checked the Xuggler docs for installation, and it had a section specifically to deal with this type of error.

http://wiki.xuggle.com/Frequently_Asked_Questions#Installation_Questions

It has the following, as a set of instructions you should follow to solve the error.

What's up with java.lang.UnsatisfiedLinkError?

It means that Java can't find the Xuggler native library. Check the following:

  • Did you install the Xuggler?
  • Is the environment variable XUGGLE_HOME defined and pointing to your Xuggler install directory (usually C:\Program Files\Xuggle on Windows or /usr/local on Linux/Mac)?
  • If you installed on Windows, did you reboot after you installed?
  • Does your PATH environment variable include %XUGGLE_HOME%\bin on Windows or $XUGGLE_HOME/bin on Linux/Mac?
  • Does your PATH environment variable include %XUGGLE_HOME%\lib on Windows?
  • Does your LD_LIBRARY_PATH environment variable include $XUGGLE_HOME/lib on Linux?
  • Does your DYLD_LIBRARY_PATH environmentvariable include $XUGGLE_HOME/lib on Mac OS-X?
  • Are you using a 32-bit Java JVM, but a 64-bit version of Xuggler? Or a 64-bit version of the Java JVM but a 32-bit version of Xuggler? Unfortunately that won't work. You need to make sure that you match the "bitness" of each release. Sorry.
Codemwnci
  • 54,176
  • 10
  • 96
  • 129
  • Didn't I answer all the questions above? – Rifat Oct 09 '11 at 18:16
  • No. I assume point 1 is true, what about 7 and 8? Have you checked your PATH variable? – Codemwnci Oct 09 '11 at 18:30
  • about 7, please check what I exported in my `~/.bashrc` and about 8, well I didn't mention that but I've already went through the xuggle wiki. Anyway, thanks for your precious time :) – Rifat Oct 09 '11 at 18:45
  • 7 talks about DYLD_LIBRARY_PATH, you have exported LD_LIBRARY_PATH. The YD prefix appears to be specific for Mac OS X. If this is not the answer, then I would suggest trying to run an example outside of Play to determine if it is Play or your Xuggle install/config. – Codemwnci Oct 09 '11 at 18:55
  • Well example outside play! worked because it (eclipse) uses `~/.MacOSX/environment.plist`. Thanks, It was not working because of the DY prefix (not YD) :) – Rifat Oct 09 '11 at 20:02