Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8026966

Most native libs broken on mac in jdk8/build

XMLWordPrintable

    • b113
    • os_x
    • Not verified

      After JDK-8025715 was pushed, the native libraries on macosx are broken. This is caused by the link command line having changed from (for libjfr.dylib as example):

      -Xlinker -install_name -Xlinker @rpath/libjfr.dylib

      to:

      -Xlinker -install_name -Xlinker /usr/local/lib/libJObjC.dylib

      The reason for this change is a change of order of the compiled libraries. For the library libJObjc, there was a special hack added to keep the new and old build the same:

        # Ugly hack to mimic behaviour in old build where this is built as an xcode project.
        SET_SHARED_LIBRARY_NAME = -Xlinker -install_name -Xlinker /usr/local/lib/libJObjC.dylib

      Before JDK-8025715, this was the last library in the file, so this override of the variable didn't affect other libraries. After the change, it's one of the first libraries to be built, leaving this hack in effect for all the rest.

      I propose we just remove this hack, as it's actually just plain wrong in the first place and let libJObjc get the same automatic rpath-based install_name as all other libs.

            erikj Erik Joelsson
            erikj Erik Joelsson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: