Skip to content

Commit

Permalink
Merge pull request #3176 from DanHeidinga/djh/mac_exec
Browse files Browse the repository at this point in the history
Modify the path to libjava to include "../"
  • Loading branch information
pshipton committed Oct 10, 2018
2 parents af35113 + 1ff2b4e commit 2061ce7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion runtime/jcl/common/system.c
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,8 @@ jstring getEncoding(JNIEnv *env, jint encodingType)
{
UDATA handle = 0;
PORT_ACCESS_FROM_ENV(env);
if (0 == j9sl_open_shared_library("java", &handle, J9PORT_SLOPEN_DECORATE)) {
/* libjava.[so|dylib] is in the jdk/lib/ directory, one level up from the default/ & compressedrefs/ directories */
if (0 == j9sl_open_shared_library("../java", &handle, J9PORT_SLOPEN_DECORATE)) {
void (*nativeFuncAddrJNU)(JNIEnv *env, const char *str) = NULL;
if (0 == j9sl_lookup_name(handle, "InitializeEncoding", (UDATA*) &nativeFuncAddrJNU, "VLL")) {
/* invoke JCL native to initialize platform encoding explicitly */
Expand Down

0 comments on commit 2061ce7

Please sign in to comment.