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

build using devkit on Linux ppc64le RHEL puts path to devkit into libsplashscreen

    XMLWordPrintable

Details

    • b14
    • ppc
    • linux

    Backports

      Description

        After looking at the build results of a jdk22 build on RHEL 8.4 Linux ppc64le that uses a ppc64le-linux-gnu-to-ppc64le-linux-gnu-fedora27-gcc11.3.0
        devkit we observed those unwanted paths in libsplashscreen.so .
        See those objdump and ldd output :

        objdump -x ./lib/libsplashscreen.so | grep PATH
          RUNPATH /mydevkitsfolder/devkits/ppc64le-linux-gnu-to-ppc64le-linux-gnu-fedora27-gcc11.3.0/ppc64le-linux-gnu/sysroot/usr/lib64:$ORIGIN


        ldd ./lib/libsplashscreen.so
        ldd: warning: you do not have execution permission for `./lib/libsplashscreen.so'
              . . .
                       libX11.so.6 => /mydevkitsfolder/devkits/ppc64le-linux-gnu-to-ppc64le-linux-gnu-fedora27-gcc11.3.0/ppc64le-linux-gnu/sysroot/usr/lib64/libX11.so.6 (0x00007fffa3920000)
                       libXext.so.6 => /mydevkitsfolder/devkits/ppc64le-linux-gnu-to-ppc64le-linux-gnu-fedora27-gcc11.3.0/ppc64le-linux-gnu/sysroot/usr/lib64/libXext.so.6 (0x00007fffa38e0000)
              . . .
                       libz.so.1 => /mydevkitsfolder/devkits/ppc64le-linux-gnu-to-ppc64le-linux-gnu-fedora27-gcc11.3.0/ppc64le-linux-gnu/sysroot/usr/lib64/libz.so.1 (0x00007fffa36f0000)
                       libc.so.6 => /lib64/power9/libc.so.6 (0x00007fffa34e0000)
                       libjvm.so => not found
                       libxcb.so.1 => /lib64/libxcb.so.1 (0x00007fffa3490000)
                       /lib64/ld64.so.2 (0x00007fffa3be0000)
                       libXau.so.6 => /lib64/libXau.so.6 (0x00007fffa3460000)
         
         
        Looks like the devkit reference is coming in via the X_LIBS setting , where the -R is added by AC_PATH_XTRA

        make/autoconf/lib-x11.m4
         
            # Now let autoconf do it's magic
            AC_PATH_X
            AC_PATH_XTRA
         
            # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
            # this doesn't make sense so we remove it.
            if test "x$COMPILE_TYPE" = xcross; then
              X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[[^ ]]*//g'`
            fi
         And X_LIBS is used later on Linux in the build of LIBSPLASHSCREEN .


        Strangely I could not reproduce this when building on RHEL 8.x x86_64 , there might be a difference in the tools compared to ppc64le.
        Probably at least in the devkit build case, the -R setting should be filtered like it is done in the cross build already.

        Attachments

          Issue Links

            Activity

              People

                mbaesken Matthias Baesken
                mbaesken Matthias Baesken
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: