URL: <https://savannah.gnu.org/bugs/?68565>
Summary: manage parser generation for Bison/YACC grammars
with `MAINTAINER_MODE`
Group: GNU roff
Submitter: gbranden
Submitted: Sat 25 Jul 2026 07:38:26 PM UTC
Category: General
Severity: 3 - Normal
Item Group: Build/Installation
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Unlocked
Planned Release: None
_______________________________________________________
Follow-up Comments:
-------------------------------------------------------
Date: Sat 25 Jul 2026 07:38:26 PM UTC By: G. Branden Robinson <gbranden>
[https://lists.gnu.org/archive/html/groff/2026-07/msg00017.html I wrote]:
... There may already exist other "informal" maintainer-mode stuff
we should bring under the governance of the `MAINTAINER_MODE` Automake
macro, and further such things may arise in the future.
One existing instance I can think of is the generation of the Bison/YACC
grammars for eqn, pic, and refer.
See a recent commit:
commit baac1d37e9cbf38c786a89e34201bd9cce0ec19f
Author: G. Branden Robinson <[email protected]>
Date: Thu Jul 2 12:12:37 2026 -0500
[eqn,pic,refer]: Clean out-of-source build trees.
...better.
* src/preproc/eqn/eqn.am:
* src/preproc/pic/pic.am:
* src/preproc/refer/refer.am: Improve clean behavior, deleting YACC/
Bison-generated files _only_ from an out-of-source build tree.
Because they are shipped in the distribution archive, only the
"maintainer-clean" target should remove them from the source tree.
Add new macros `GROFF_{EQN,PIC,REFER}_YACC_FILES` to track these
artifacts. Redefine `MAINTAINERCLEANFILES` in terms of these new
macros. Add `mostlyclean-{eqn,pic,refer}` targets to perform the
cleaning. Add these new targets as dependencies of
`mostlyclean-local`.
With this commit, the only files left behind after a command sequence
like this...
rm -r build
mkdir build
cd build
../configure
make
make clean
...are a bunch of ".dirstamp" and/or ".Po" files, which are GNU
Automake's business to deal with.
With `MAINTAINER_MODE`, we might be able to make the foregoing even more
scrupulous.
Setting Severity to "Normal" rather than "Wish", because the fact that we
don't do this already probably is a bug.
I may return to quote an email from Bruno where he lays out how date stamps
are not maintained scrupulously enough across platforms to avoid spurious
rebuilds, which will fail if dependencies that we say distribution archive
users don't need are not present in the host environment.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?68565>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
signature.asc
Description: PGP signature
