Skip to content

Ship translated catalogs in the release archives and installer - #232

Merged
midwan merged 1 commit into
masterfrom
feat/release-catalogs
Oct 24, 2026
Merged

midwan merged 1 commit into
masterfrom
feat/release-catalogs

Conversation

@midwan

@midwan midwan commented Oct 24, 2026

Copy link
Copy Markdown
Collaborator

Releases have never shipped the translated catalogs, so Opus only shows translations when someone installs catalogs by hand.

Changes

  • Building: catalogs/catalogs.sh build compiles every catalogs/<language>/<name>.ct with FlexCat, using the matching .cd under source/, into catalogs/bin/<language>/, which git ignores. Each catalog is named after its .cd (XADopus.catalog), except font.cd, which gives viewfont.catalog. A catalog is only recompiled when it is missing or older than its .ct or .cd. FlexCat's exit code 5 (warnings about untranslated strings) counts as success. The script replaces the hand-written, Amiga-only catalogs/Makefile.
  • Makefile: make <target> catalogs runs the build. release-package runs it too, then stages the catalogs under their ## language names (ISO-8859-1, e.g. espa\xf1ol, as locale.library spells them) and adds Catalogs/<language>/ at the archive root.
    • Staging happens in the container's /tmp, because macOS volumes, including Docker bind mounts, refuse ISO-8859-1 file names.
    • LHa for UNIX normally converts file names and fails on those bytes. --system-kanji-code=utf8 --archive-kanji-code=utf8 makes it store them unchanged. This also works with the older LHa in the AROS images, which has no latin1 option.
  • Installer: one askoptions question lists the 11 languages. It preselects the Installer's @language and any language that already has LOCALE:Catalogs/<lang>/dopus.catalog, then copies each chosen language to LOCALE:Catalogs/<lang>.
    • The target is LOCALE:, not DOpus5:Catalogs, because dopus5.library opens its catalog when the library is first opened. That is often from DOpus5:C/LoadDB or LoadDOpusLib, whose PROGDIR: is DOpus5:C, so a catalog in DOpus5:Catalogs would often be missed. ViewFont also lives in DOpus5:C.
    • The script stays ISO-8859-1.
  • CI: the AROS images have no FlexCat, so the AROS build jobs first compile the catalogs in the os3 image. release-package then finds them up to date.
  • Test: a new InstallerTests case checks that the installer's two language lists (the choices and P_CATALOG_LANGUAGE) match the shipped ## language names in the same order, and that #cat-count matches their number.
  • Docs: AmigaGuide Installation section (58.22), README, and a ChangeLog [dopus5 next] entry.

Verification

  • All 199 catalogs compile in the os4 image. Reading the STRS chunks back shows the ISO-8859-1 text unchanged (no UTF-8).
  • make os3 release-package builds an archive with Catalogs/ holding 11 languages (211 entries) and the raw ISO-8859-1 names. The packaged Install DOpus5 matches the source byte for byte apart from @BUILD@.
  • In the x86_64-aros image, catalogs.sh build skips the prebuilt catalogs without FlexCat, then staging and lha with the raw-name flags work. When a catalog is out of date, it stops with a clear error.
  • python3 -m unittest archive/tests/test_basedata_default_drawers.py: all 17 tests pass. The new test fails when two languages are swapped in one list. shellcheck reports nothing.

Not yet run on a real Installer. The new step (askoptions, @language, while, makedir of LOCALE:Catalogs/<lang>) still needs one run on OS 3.2 before release. Whether the AROS Installer supports these is also unknown.

Release archives get Catalogs/<language> with every translation compiled
by FlexCat (catalogs/catalogs.sh, 'make <target> catalogs'). The
installer asks which languages to install and copies them to
LOCALE:Catalogs/<language>. CI compiles the catalogs in the os3 image for
the AROS targets, whose images have no FlexCat.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-24T07:12:37.680628Z db3848b PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@midwan
midwan merged commit c8fbeb6 into master Oct 24, 2026
17 checks passed
@midwan
midwan deleted the feat/release-catalogs branch October 24, 2026 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant