title: What is causing UnsatisfiedLinkError for jniwrap64.dll?
body: <p>We've got a GWT web app that uses JNI to call a dll. We build the dll as well. It works fine on my developer machine, which is a 64-bit Windows 7 machine, running Java 6 and running the webapps in Tomcat 6. But when we run it on the tester's VM which is running 32-bit WinXP, it errors with</p>
  
  <pre><code>java.lang.UnsatisfiedLinkError: Cannot load native JNIWrapper library (jniwrap64.dll)
  at com.jniwrapper.Library.loadNativeCode(SourceFile:78)
  at com.jniwrapper.Library.loadNativeCode(SourceFile:103)
  at com.jniwrapper.Library.ensureNativeCode(SourceFile:113)
  at com.jniwrapper.Library.load(SourceFile:189)
  </code></pre>
  
  <p>My JRE_HOME is set to a 32-bit version of Java 6, because I wanted the build to be able to work on a 32-bit machine, but clearly I'm mis-understanding something about how the 32 or 64-bit versions of java work in compiling the web app.</p>
  
  <p>And yes, the dll that we call is built in to the .war, since it works on my machine.</p>
  
  <p>I also googled the jniwrap64.dll but didn't find much that was relevant.</p>
  
  <p>Added for clarification : jniwrap64.dll is not the dll that I've built, and my code is not explicitly loading this library. That's part of my confusion, is what is this library, why is it being loaded, etc. I have assumed that jniwrap64.dll is some kind of system library that needs to be installed. My code that loads our library is as follows:</p>
  
  <pre><code>Library myLib = Library(path);
  myLib.load(this.getClass().getClassLoader());
  </code></pre>