Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-6672820

jtreg does not work with OpenJDK

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • None
    • tools
    • None
    • sparc
    • solaris_10

      jtreg (3.2.2 and up) does not work if OpenJDK is used as the JDK to run the harness. The following error is emitted:

      Cannot determine version of java to run jtreg

      The following code in jtreg is causing this:

      # Verify java version (1.)5 or newer used to run jtreg
      version=`"$JT_JAVA" -version 2>&1 |
              grep "java version" |
              sed -e 's/^[^"]*"\([^"]*\)".*/\1/' -e 's/^1\.//' -e 's/\([1-9][0-9]*\).*
      /\1/'`


      The pattern ("java version") is not matching because an OpenJDK java -version emits:

      openjdk version "1.7.0-internal"
      OpenJDK Runtime Environment (build 1.7.0-internal-mullan_06_Mar_2008_09_13-b00)
      Java HotSpot(TM) Server VM (build 12.0-b01, mixed mode)

            jjg Jonathan Gibbons
            mullan Sean Mullan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: