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

Javadoc error if unnamed module depends on named module

    XMLWordPrintable

    Details

      Description

      ADDITIONAL SYSTEM INFORMATION :
      Windows 10.0.18363.720
      openjdk 14 2020-03-17
      OpenJDK Runtime Environment (build 14+36-1461)
      OpenJDK 64-Bit Server VM (build 14+36-1461, mixed mode, sharing)

      A DESCRIPTION OF THE PROBLEM :
      1. Extract testcase from https://issues.apache.org/jira/browse/MJAVADOC-645
      2. Run "mvn clean package"
      3. Build fails with:

      Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:3.2.0:jar (attach-javadocs) on project module2: MavenReportException: Error while generating Javadoc:
      Exit code: 1 - javadoc: error - The code being documented uses packages in the unnamed module, but the packages defined in http://nexus.sonatype.org/oss-repository-hosting.html/root/module1/apidocs/ are in named modules.

      Command line was: cmd.exe /X /C ""C:\Program Files\Java\jdk-14+36-1461\bin\javadoc.exe" @options @packages"

      Refer to the generated Javadoc files in 'C:\Users\Gili\Documents\3rdparty\javadoc-jar-mixing-named-and-unnamed-extending-sonatype\module2\target\apidocs' dir.

      4. In spite of the error, the Javadoc tool outputs files.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      1. The Javadoc tool should output files and succeed, or fail without writing any files.
      2. The Javadoc tool should allow mixing named and unnamed modules, especially if the unnamed module contains an Automatic-Module-Name MANIFEST.MF entry.
      3. The Javadoc tool should suggest adding Automatic-Module-Name MANIFEST.MF entries to unnamed modules if they are not present.

      FREQUENCY : always


        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: