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

javac should support new option -XinheritRuntimeEnvironment

    XMLWordPrintable

    Details

      Backports

        Description

        javac should support a new option to configure the javac compilation environment from the current runtime (execution) environment.

        Exact details TBD, but informally, the option has the effect of determining the options specified when starting the enclosing VM, using ProcessHandle.current().info() and applying a subset of those options to javac, such as -addmods, -limitmods, -modulepath, -XaddReads, -XaddExports, -Xpatch, etc.

        It is TBD what happens if any of those options conflict with any given explicitly to javac, either before or after the -XinheritRuntimeEnvironment option. Possibilities are: "last on wins", "merge", or "reject". Of these, "reject" is the simplest, although merge would be reasonable for at least some of the options.

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                jjg Jonathan Gibbons
                Reporter:
                jjg Jonathan Gibbons
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved: