configure.in renamed to configure.ac - #66
Closed
sc0w wants to merge 1 commit into
Closed
Conversation
Fixes GH issue #65
Member
|
Partially committed (except |
ngosang
added a commit
to ngosang/amule
that referenced
this pull request
Jun 11, 2026
Weblate updates docs/man/po/manpages-*.po but cannot run po4a, so the
rendered *.{lang}.1.in files tracked in git always drift and the check
turned every Weblate translation PR red (e.g. PR amule-project#66). Comment the job
out (not delete) until the rendered manpages are removed from the repo
and generated at build time with CMake + po4a; the tracked renders are
deliberately allowed to lag behind the .po files in the meantime.
ngosang
added a commit
to ngosang/amule
that referenced
this pull request
Jun 11, 2026
Co-authored-by: Diego Heras <[email protected]> Co-authored-by: John Doe <[email protected]> Co-authored-by: Marcelo Roberto Jimenez <[email protected]>
ngosang
pushed a commit
to ngosang/amule
that referenced
this pull request
Jun 11, 2026
Stop tracking the ~100 pre-rendered docs/man/*.{lang}.1.in and
src/utils/*/docs/*.{lang}.1.in. Generate them at build time from the
English masters + docs/man/po/manpages-*.po via po4a, then install
them under <prefix>/share/man/<lang>/man1/.
Why this matters:
Weblate edits docs/man/po/manpages-*.po but cannot run po4a, so every
Weblate translation PR left the tracked renders stale and turned the
manpages-sync CI red (PR amule-project#66). The stopgap commented the check out
entirely, which let the tracked renders deliberately lag behind the
translations.
Tracking generated files also forced CI to pin po4a 0.74 from
Debian trixie because po4a's output wrapping changes between versions
and any mismatch surfaced as spurious drift.
Pipeline
- docs/man/po4a.config.in: CMake-templated config; @CMAKE_*_DIR@
references resolve to absolute build-dir output paths at configure
time, so po4a writes straight into the build tree.
- docs/man/CMakeLists.txt:
* cmake_dependent_option(TRANSLATED_MANPAGES ... ON ENABLE_NLS OFF)
* find_program(po4a). If missing, install only English masters and
surface a STATUS message (po4a is an optional build dep).
* add_custom_command runs po4a once with DEPENDS on every
manpages-*.po, then a second custom_command per output runs
cmake/configure_translated_manpage.cmake to substitute @MAN_DATE@
and @PACKAGE_VERSION@ (po4a passes those through verbatim).
* The two-pass split is required because configure_file is
configure-time only; the rendered .1.in inputs don't exist yet
when CMakeLists.txt runs.
- cmake/configure_translated_manpage.cmake: tiny helper that
re-implements configure_file @only semantics via file(READ) +
string(CONFIGURE) + file(WRITE), invoked via cmake -P from the
custom_command at build time.
- scripts/update-manpages-po.sh: counterpart to scripts/update-po.sh
for translators. Runs po4a --no-translations against a temp
docs/man-relative config (so #: source refs land as relative paths,
not the developer's absolute fs path), regenerating manpages.pot
and merging into manpages-*.po.
- .github/workflows/i18n.yml: replace the disabled manpages-sync
with a manpages-pot-sync that re-runs update-manpages-po.sh and
diffs the result, matching the existing pot-sync job for the
application catalogs. Weblate can never break this one — Weblate
only edits .po files.
- .github/workflows/release.yml: new source-bundle job builds
aMule-<TAG>-src.tar.gz containing every tracked file plus the
freshly-rendered translated manpages, so downstream packagers can
consume a tarball that doesn't require po4a at build time. Attached
to the draft Release alongside the binary artifacts.
The mtime gotcha the disabled manpages-sync job documents goes away
once nothing rendered is in git: CMake's DEPENDS on the .po inputs
drives incremental rebuilds rather than po4a's own
"outputs up-to-date" check.
Closes amule-project#69.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes GH issue #65