Skip to content

Cannot build javadoc using README directions on Java 25 #9644

Closed as not planned

Description

@nathub

Apache NetBeans version

Apache NetBeans 31

What happened

In the README.md file this line explains how to get javadoc to build using ant:

' On JDK 24 or later, building javadoc may require to raise the jaxp entity limit by setting export ANT_OPTS=-Djdk.xml.totalEntitySizeLimit=200000 '

However, this does not work. using this command doesn't seem to increase the limit. I still get the error below:
' JAXP00010004: The accumulated size of entities is "100,001" that exceeded the "100,000" limit set by "jdk.xml.totalEntitySizeLimit". '

I am on Java 25. I can't figure out how to get javadoc to build.

Language / Project Type / NetBeans Component

NetBeans Source build

How to reproduce

Using Java 25, run "sudo ant javadoc" in the source repo's top folder.
Following the README directions, run export ANT_OPTS=-Djdk.xml.totalEntitySizeLimit=200000.
Then attempt to build again using sudo ant javadoc.
The size limit will persist.

Try closing your terminal, logging out, or restarting the computer, before opening a new terminal and attempting to build javadoc again. The issue will persist.

Did this work correctly in an earlier version?

No / Don't know

Operating System

Linux (Debian stable, specifically MX Linux)

JDK

25.0.4.1

Apache NetBeans packaging

Own source build

Anything else

No response

Are you willing to submit a pull request?

No

Activity

  1. added
    kind:bugBug report or fix
    needs:triageRequires attention from one of the committers
    on Sep 28, 2026
  2. neilcsmith-net commented on Sep 28, 2026

    @neilcsmith-net
    Member

    Why are you using sudo to run ant?! That's not going to work.

  3. matthiasblaesing commented on Oct 13, 2026

    @matthiasblaesing
    Contributor

    @nathub with #9701 you should be able to build on JDK25 without modification. But please never build with sudo. A build process that relies on that is broken and should be avoided. NetBeans can be build as a normal user and just needs ant and a JDK.

  4. nathub commented on Oct 13, 2026

    @nathub
    Author

    4. @nathub with #9701 you should be able to build on JDK25 without modification. But please never build with sudo. A build process that relies on that is broken and should be avoided. NetBeans can be build as a normal user and just needs ant and a JDK.

    If I run ant without sudo, I get an error containing:
    ".../nbbuild/build/nbantext.jar is read-only."
    Which is why I was using sudo in my example text. But I always try without sudo first when trying to run build commands.
    Some projects stuff require sudo and some doesnt so thats how I check.

  5. matthiasblaesing commented on Oct 14, 2026

    @matthiasblaesing
    Contributor

    Undeletable files are a common result of trying to run as root. I had that in the past where I accidentally ran a java application server as root while debugging and then starting it as a normal service failed as the root run created files that the deamon-user was not allowed to change. This will be the case here also.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind:bugBug report or fixneeds:triageRequires attention from one of the committers

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions