RFR(M): 8216265: [testbug] Introduce Platform.sharedLibraryPathVariableName() and adapt all tests.

Lindenmaier, Goetz goetz.lindenmaier at sap.com
Mon Jan 7 13:07:25 UTC 2019


Hi,

Different operating systems use different names for the environment variable
that contains the search paths for native libraries.  This path is used in
a row of tests. A switch over all OSes is needed to find out the proper variable
name in each test using it.

This change introduces a central function
Platform.sharedLibraryPathVariableName()
that returns "LD_LIBRARY_PATH", "DYLD_LIBRARY_PATH", "PATH" or
"LIBPATH" depending on the current OS.
This change also adapts all usages of these variables in the tests to call
this function.
Because of the change to KDC.java I had to add @library /test/lib
to much more tests than where I had to do the underlying change.

The change also replaces local checking for path separators by
File.pathSeparator in jdk/com/sun/jdi/PrivateTransportTest.java.

The change depends on "8215975: [testbug] Adapt nsk tests to
the PPC, S390 and AIX platforms." which will be moved from jdk12
to jdk soon.

Please review:
http://cr.openjdk.java.net/~goetz/wr19/8216265-PathVar/01/

Best regards,
  Goetz.


More information about the hotspot-dev mailing list