Implement researched Guix package outcome for #44: [Guix packaging] larsbrinkhoff/forth-mode #607
Labels
No labels
accessibility
bug
category:ai-tool
category:browser
category:command-line-tool
category:compiler-toolchain
category:desktop-application
category:developer-tool
category:editor-extension
category:emulator
category:font
category:game
category:input-accessibility
category:library-framework
category:mud-client
category:multimedia
category:networking-client
category:programming-language
category:roguelike
category:storage-media-tool
category:system-tool
category:terminal-application
complexity:high
complexity:low
complexity:medium
difficulty:blocked
difficulty:easy
difficulty:hard
difficulty:moderate
documentation
duplicate
enhancement
good first issue
gooflow:guix-package-high
gooflow:guix-package-moderate
gooflow:guix-package-quality-gates
gooflow:guix-research-disposition
gooflow:guix-runtime-evidence-refresh
help wanted
invalid
kind:disposition
kind:packaging
needs:license-investigation
priority:quick
question
ready-for-agent
state:available-elsewhere
state:blocked
state:deferred
state:out-of-scope
state:ready
state:research
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
tay/guix-channel#607
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
This delivery ticket was created from research issue #44 ([Guix packaging] larsbrinkhoff/forth-mode).
The host-validated research finding follows:
Canonical source and fixed revision: use https://github.com/larsbrinkhoff/forth-mode at commit 4450a3a5629b579f5d2045d0d8aec84193e9a31f. GitHub identifies that commit as the 0.3 release bump (there is no 0.3 tag), and the upstream forth-mode.el header declares Version: 0.3. The local channel already records the codeload source as larsbrinkhoff-forth-mode-source with Guix Nix-base32 hash 0w0amqi1hrmfz99h0fbyr4mypl3jy3aky8jhpiydp794j21ld71n; use its channel version 0-4450a3a and source rather than an unpinned fetch. The source is pure Elisp plus one SwiftForth .fth helper, has no native compilation, and is directly suitable for emacs-build-system. LICENSE is the standard GPL version 3 text and GitHub reports GPL-3.0; use license:gpl3 (SPDX GPL-3.0-only). No non-free or unlicensed bundled dependency was found. Equivalent coverage exists and must be accounted for: authoritative Guix defines emacs-forth-mode@0.2 in gnu/packages/emacs-xyz.scm from the same project homepage but an older NonGNU ELPA 0.2 archive with tests disabled; current NonGNU ELPA publishes forth-mode 0.3, whose installed files match the common files in this pinned commit. The workspace channel has only the larsbrinkhoff-forth-mode-source preservation package and no built mode package. Therefore add/update the emacs-forth-mode identity in tay/packages/forth-mode.scm from the pinned source, intentionally replacing/overriding the older 0.2 package when this channel package is selected rather than inventing a different upstream package identity. Import guix build-system emacs, guix gexp, guix packages, gnu packages forth, and tay packages larsbrinkhoff-a-f; set build-system to emacs-build-system, reuse package-source/package-version from larsbrinkhoff-forth-mode-source, and add (inputs (list gforth)) because run-forth starts Gforth at runtime and the ERT completion test starts the same process. cl-lib, comint, smie, url, and Gnus mm-url are Emacs libraries, so no separate Elisp input is required and Emacs is supplied automatically by emacs-build-system. The default include set installs top-level .el files but omits nested backends; extend it with ^backend/.$ so forth-mode.el, forth-block-mode.el, forth-interaction-mode.el, forth-parse.el, forth-smie.el, forth-spec.el, forth-syntax.el, all backend .el files, and backend/swiftforth.fth are installed. Exclude the build helper build.el and the test-generated autoloads.el from the installed payload while retaining Guix-generated package autoloads. In an unpack phase use emacs-substitute-variables on forth-interaction-mode.el to set the default forth-executable to search-input-file inputs /bin/gforth. This is the required runtime behavior: no shell wrapper is needed because run-forth calls make-comint-in-buffer with that absolute store path; the Gforth backend is then dynamically loaded from the installed backend directory and sends its existing ' drop is Attr! initialization probe. Adapt the obsolete Makefile test pin without changing upstream files: before check, mark only the ERT test forth-spec-parsing as skipped because it calls url-retrieve-synchronously against the live forth-standard.org/lars.nocrew.org indexes and cannot be part of an offline Guix build; retain all other ERT tests. Set HOME to the build TMPDIR and run the test command as make check FORTH=<the exact /bin/gforth input path>, which exercises build.el batch byte-compilation and ERT, including forth-completion-at-point's Gforth assertion that completion of 2c yields 2Constant. Specific acceptance proof: run guix lint -L. emacs-forth-mode and guix build -L. emacs-forth-mode; in a network-disabled temporary environment, keep the unpacked source's test/.fth fixtures as the fixture working directory while -L points to the installed output directory share/emacs/site-lisp/forth-mode-0-4450a3a, require forth-mode, forth-block-mode, and forth-interaction-mode, visit test/noblock.fth, test/block1.fth, and test/block2.fth to assert forth-mode and the expected block-mode state, require the Gforth backend through an actual run-forth process, and assert the process is killed cleanly. These checks establish the requested mode/backend installation and packaged-Gforth runtime behavior without claiming those package proofs have already run.
Acceptance criteria
Imported from GitHub issue/PR. Originally posted by htayj on 2026-08-25T13:31:37Z.
Delivered after the Gooflow package implementation, audit, and isolated safe proof passed. The two phase commits were host-signed and verified before fast-forward integration; resumed command-phase sandbox context is tracked separately in htayj/goocastle#301.
Imported from GitHub comment. Originally posted by htayj on 2026-08-26T03:07:52Z.