Uploaded image for project: 'Maven Compiler Plugin'
  1. Maven Compiler Plugin
  2. MCOMPILER-581

Create second default execution "default-generate-sources" for APT

    XMLWordPrintableJSON

Details

    • Task
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • 4.0.0
    • None

    Description

      Starting with version 4.0.0 of this plugin for use with Maven 4+, the following changes should be incorporated to align the compilation process with the process designed by the OpenJDK javac team:

      • Modify default-compile to use proc:none by default
      • Create a new goal default-generate-sources and use proc:only

      This will align the compilation process with the default javac use.

      Rationale

      Before JDK 21+, no "proc:full" was available and implicitly used when no proc:* was set.
      However, starting with JDK 21, proc:full was introduced and not specifying proc:* will now trigger a warning.

      Alternatives

      Keep one phase but specify proc:full whenever APTs are in the CP or used as a compiler-plugin dependency/path or when APT classes are explicitly given.

      Drawbacks of this approach

      TODO: document drawbacks of this approach and of the alternatives.

      Attachments

        Activity

          People

            Unassigned Unassigned
            bmarwell Benjamin Marwell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: