title: glassfish 3.1.1 'unique' JNI error
body: <p>A webapp using native code works fine in Glassfish 2.x.</p>
  
  <p>In 3.1.1, it fails with:</p>
  
  <pre><code>[#|2012-04-18T14:43:08.330+0000|SEVERE|glassfish3.1.2|com.sun.jersey.spi.container.ContainerResponse|_ThreadID=21;_ThreadName=Thread-2;|The exception contained within MappableContainerException could not be mapped to a response, re-throwing to the HTTP container
  java.lang.UnsatisfiedLinkError: com.basistech.rnt.jni.initializeEnvironmentSpecificRootDirectory(Ljava/lang/String;)Z
      at com.basistech.rnt.jni.initializeEnvironmentSpecificRootDirectory(Native Method)
  </code></pre>
  
  <p>Note that this is the version of the linkage error that complains about a particular symbol, not about the entire library.</p>
  
  <p>The very same JNI lib works fine run from a sample Java program <em>outside</em> of Glassfish on the very same machine.</p>
  
  <p>Reading the JDK source, this would seem to be possible only if <code>dlsym</code> (we're on Linux) fails to return the symbol. (This is all Java 1.6.x.) I'm stumped as to what Glassfish could possibly be doing that would cause <code>dlsym</code> to fail to see this symbol in the shared lib.</p>
  
  <p>Any ideas out there?</p>