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

[TESTBUG] runtime/jsig/Test8017498.sh incorrectly compiles native code

XMLWordPrintable

    • b42
    • b03

      The gcc command that is used to compile the native code doesn't account for the fact that we might be running a 32-bit JVM on a 64-bit OS. Consequently we need to compile for 32-bits otherwise we will get a runtime failure:

      Exception in thread "main" java.lang.UnsatisfiedLinkError: /export/local/aurora/CommonData/jtreg_8/JT_HS/test/runtime/jsig/libTestJNI.so: /export/local/aurora/CommonData/jtreg_8/JT_HS/test/runtime/jsig/libTestJNI.so: wrong ELF class: ELFCLASS64 (Possible cause: architecture word width mismatch)

      Also note that this native code causes the following VM warning:

      Java HotSpot(TM) Embedded Server VM warning: You have loaded library /export/local/aurora/CommonData/jtreg_8/JT_HS/test/runtime/jsig/libTestJNI.so which might have disabled stack guard. The VM will try to fix the stack guard now.
      It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.

            ccheung Calvin Cheung
            dholmes David Holmes
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: