Skip to content

docs: make dirhtml never builds javadoc, $(javadoc) expands to nothing #1122

Description

@nikagra

docs/Makefile:50 is:

dirhtml: setup
	@$(javadoc)
	$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml

javadoc is a target (docs/Makefile:55-57), not a variable, so $(javadoc) expands to
the empty string and the @ silences the resulting empty recipe line:

$ make --eval='proof:; @echo "[$(javadoc)]"' proof
[]

So make -C docs dirhtml has never generated api/, and never reported that it did not. The
only path that runs docs/_utils/javadoc.sh is make -C docs javadoc, directly or via
javadoc-multiversion.sh during a multiversion build.

CI is unaffected — the publish goes through multiversion.sh — but a local dirhtml preview
silently lacks javadoc, and any api/ present is left over from an earlier run.

Fix: make javadoc a prerequisite (dirhtml: setup javadoc) or call the script
explicitly. Worth checking whether dirhtml should depend on it at all, since the javadoc
build is slow and most local previews do not need it — in which case the dead line should just
go.

Found while working on #1118.

Activity

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions