Skip to content

Fix missing release notes#2413

Open
yadij wants to merge 4 commits intosquid-cache:masterfrom
yadij:fix-missing-release-notes
Open

Fix missing release notes#2413
yadij wants to merge 4 commits intosquid-cache:masterfrom
yadij:fix-missing-release-notes

Conversation

@yadij
Copy link
Copy Markdown
Contributor

@yadij yadij commented Apr 26, 2026

Vendors typically use autoreconf to rebuild Squid after patching
the Makefile.am or configure.ac sources. That tool performs an
equivalent to 'make distclean' which erases RELEASENOTES.html.

Refactor the RELEASENOTES.html creation using automake rules
with transitive dependency and clean support, and automake
variables for tools detected by ./configure are used for the
build. Ensuring that file is always able to be re-created if
missing via 'make dist' or 'make RELEASENOTES.html' commands.

The need to re-generate RELEASENOTES.html adds the linuxdoc tool
to build dependencies where it was previously only mandatory for
release maintainer to generate the "Bootstrapped sources"
tarball.

yadij added 2 commits April 26, 2026 19:36
The linuxdoc tool used to generate release notes
is not optional.
@yadij yadij added S-could-use-an-approval An approval may speed this PR merger (but is not required) backport-to-v7 maintainer has approved these changes for v7 backporting labels Apr 26, 2026
@yadij
Copy link
Copy Markdown
Contributor Author

yadij commented Apr 26, 2026

This problem has been around for a while, preventing certain types of patching by downstream vendors.
It has come to a head and started causing major pain with the new v7 release process.

@kinkie

This comment was marked as resolved.

@kinkie
Copy link
Copy Markdown
Contributor

kinkie commented Apr 26, 2026

apart from this, LGTM

@kinkie kinkie added the S-waiting-for-author author action is expected (and usually required) label Apr 26, 2026
@yadij
Copy link
Copy Markdown
Contributor Author

yadij commented Apr 26, 2026

The description doesn't fit the actions - on top of what's in it, it also uses variables for tools. Which is a good thing, but it's either its own PR, or at least should be disclosed in the description

That is to ensure that tools identified by ./configure (eg when cross-compiling) are used, not anything located in the shell PATH. Updated the description to say that.

FWIW, I hit the above problem when testing the change to AC_PROG_PATH(LINUXDOC,...) and what $FALSE did without the automake conditional build. The original master code would run local linuxdoc even if the ./configure test detected it unusable, or tried to use a cross-compiler variant binary.

@yadij yadij added S-waiting-for-reviewer ready for review: Set this when requesting a (re)review using GitHub PR Reviewers box and removed S-waiting-for-author author action is expected (and usually required) labels Apr 26, 2026
@yadij yadij requested a review from kinkie April 26, 2026 11:37
@rousskov rousskov self-requested a review April 26, 2026 18:32
@kinkie
Copy link
Copy Markdown
Contributor

kinkie commented Apr 27, 2026

That is to ensure that tools identified by ./configure (eg when cross-compiling) are used, not anything located in the shell PATH. Updated the description to say that.

I agree it's valuable, no question.
My only request is that this PR does two things:

  • change the logic so that integrators have an easier, more reliable workflow
  • add the tool detections

I'm not going to ask you to put in the work to separate them, but I do ask you to highlight there's two changes

Copy link
Copy Markdown
Contributor

@rousskov rousskov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR description: Vendors typically use autoreconf to rebuilds Squid ... That tool performs an equivalent to 'make distclean' which erases RELEASENOTES.html.

That (true) statement feels misleading in this PR context because, AFAICT, even make clean erases RELEASENOTES.html (in both official and PR sources): "Vendors" and "autoreconf" could be the motivation for this PR, of course, but the way they are currently mentioned is a red herring -- regular users rebuilding Squid under regular conditions erase RELEASENOTES.html as well. Please rephrase PR description to address this concern.

PR description: Ensuring that file is always able to be re-created if missing.

It is difficult for me to understand what this PR has changed at the top level (other than introducing a linuxdoc availability as make dist success precondition, and even that conclusion requires some guessing!).

Please rephrase PR title and description to be more specific, highlighting the top-level/primary change to RELEASENOTES.html creation targets. For example, "Prior to this changes, make ... created RELEASENOTES.html. Now, make dist creates it." Same for the primary target that erases that generated file (if that target has changed).

Comment thread doc/release-notes/Makefile.am
Comment thread configure.ac Outdated
-e "s%[@]SQUID_RELEASE[@]%$(SQUID_RELEASE)%g" \
-e "s%[@]SQUID_RELEASE_OLD[@]%$$(( $(SQUID_RELEASE) - 1 ))%g" \
< $< >$@
test `grep -c "@SQUID" $@` -eq 0
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, this target and/or this particular test is broken: This target should fail when $@ does not exist but it actually succeeds. Since this PR removes ENABLE_RELEASE_DOCS protections -- exposing this code to more build cases/environments, it may be a good idea to fix this in this PR, but I do not insist on that.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Works for me". Dropping a rm $@ command after the sed to replicate a failure to produce output I get this:

/usr/bin/sed \
  -e "s%[@]SQUID_VERSION[@]%8.0.0-VCS%g" \
  -e "s%[@]SQUID_RELEASE[@]%8%g" \
  -e "s%[@]SQUID_RELEASE_OLD[@]%$(( 8 - 1 ))%g" \
  < ../../../doc/release-notes/release-8.sgml.in >release-8.sgml ; rm -f release-8.sgml
test `grep -c "@SQUID" release-8.sgml` -eq 0
grep: release-8.sgml: No such file or directory
/bin/bash: line 1: test: -eq: unary operator expected

Comment thread Makefile.am Outdated
yadij added 2 commits May 1, 2026 17:10
Complain about the command, not about
the inability to generate the output.
@yadij yadij added the feature maintainer needs documentation updates for merge label May 1, 2026
@yadij
Copy link
Copy Markdown
Contributor Author

yadij commented May 1, 2026

PR description: Vendors typically use autoreconf to rebuilds Squid ... That tool performs an equivalent to 'make distclean' which erases RELEASENOTES.html.

That (true) statement feels misleading in this PR context because, AFAICT, even make clean erases RELEASENOTES.html (in both official and PR sources): "Vendors" and "autoreconf" could be the motivation for this PR, of course, but the way they are currently mentioned is a red herring -- regular users rebuilding Squid under regular conditions erase RELEASENOTES.html as well. Please rephrase PR description to address this concern.

The move to DISTCLEANFILES += RELEASENOTES.html in commit now prevents make clean removing the file. Only an make distclean, autoreconf or manual rm command removes the RELEASENOTES.html file.

$ ../configure && make && ls -1 *.html
RELEASENOTES.html

$ make clean >/dev/null && ls -1 *.html
RELEASENOTES.html

$ make distclean >/dev/null && ls -1 *.html
ls: cannot access '*.html': No such file or directory

PR description: Ensuring that file is always able to be re-created if missing.

It is difficult for me to understand what this PR has changed at the top level (other than introducing a linuxdoc availability as make dist success precondition, and even that conclusion requires some guessing!).

At the top level the dependency chain for dist target is now explicitly dist -> RELEASENOTES.html -> html -> html-recursive -> -C doc/ { html -> html-recursive } -> -C doc/release-notes/ { html -> html-recursive -> html -> $(DOC).html -> $(DOC).sgml -> $(DOC).sgml.in }.
It is no longer a manual (release maintainer scripted) make -C doc/release-notes/ release-N.html && make dist command.

Please rephrase PR title and description to be more specific, highlighting the top-level/primary change to RELEASENOTES.html creation targets. For example, "Prior to this changes, make ... created RELEASENOTES.html.

Not as easy as that. It is more work than I am willing to invest just for a commit message, to track down all the possible targets that lead to the multiple old cp ... RELEASENOTES.html commands. Many different commands could create it, some of which would fail with an error, most would not (thanks to the @if being removed by this PR).

Now, make dist creates it." Same for the primary target that erases that generated file (if that target has changed).

Done. Only the way to create it has changed now.

@yadij yadij requested a review from rousskov May 1, 2026 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-to-v7 maintainer has approved these changes for v7 backporting feature maintainer needs documentation updates for merge S-could-use-an-approval An approval may speed this PR merger (but is not required) S-waiting-for-reviewer ready for review: Set this when requesting a (re)review using GitHub PR Reviewers box

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants