RFR: 7134701 [macosx] Support legacy native library names

Daniel D. Daugherty daniel.daugherty at oracle.com
Thu Mar 29 14:34:49 UTC 2012



On 3/29/12 4:25 AM, Michael McMahon wrote:
> On 27/03/12 22:23, Michael McMahon wrote:
>> Could I get the following webrev for 7u4 reviewed please?
>>
>> It is the same code change as for jdk 8
>>
>> http://cr.openjdk.java.net/~michaelm/7134701/webrev.7u4.1/
>>
>> Thanks,
>> Michael.
> I've updated the webrev for this 7u4 change, based on the testing 
> yesterday.
> It simplifies the original jdk 8 change (which will be updated via CR 
> 7157665)
> So, if an attempt to load a library whose name is X.dylib fails we 
> retry with the name X.jnilib
>
> The following examples show the main cases:
>
> System.loadLibrary("foo") -> libfoo.dylib, then libfoo.jnilib
> (tried in each directory of the boot library path and user library 
> path respectively)
>
> System.load("/abs/path/libfoo.dylib") -> /abs/path/libfoo.dylib, then 
> /abs/path/libfoo.jnilib
> System.load("/abs/path/libfoo.jnilib") -> /abs/path/libfoo.jnilib
> System.load("/abs/path/libfoo.bar") -> /abs/path/libfoo.bar
>
> System.mapLibraryName("foo") -> "libfoo.dylib"
>
> As before, this change only affects the behavior on Mac OS X.
>
> http://cr.openjdk.java.net/~michaelm/7134701/webrev.7u4.2/

Nicely redone. Thumbs up!

make/java/java/FILES_java.gmk
src/share/classes/java/lang/ClassLoader.java
src/macosx/classes/java/lang/ClassLoaderHelper.java
src/solaris/classes/java/lang/ClassLoaderHelper.java
src/windows/classes/java/lang/ClassLoaderHelper.java
     No comments on the above files.

>
> Thanks,
> Michael
>
>



More information about the core-libs-dev mailing list