[Guix packaging] atsb/freelarn #92
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
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
tay/guix-channel#92
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?
Candidate
8cd18cbaef70b9763a9f76cdfa11b78524ebcf5eonmaster(default branch snapshot reviewed 2026-08-14).freelarn)Makefile; g++ C++11 and ncurses)LICENSEcontains Apache-2.0; README documents C++11 and ncurses/pdcurses.-Werrorportability across supported compilers.Scope and blockers
Package the pinned upstream source as the stated deliverable, retaining upstream notices and making runtime services, credentials, downloaded assets, and optional integrations explicit. Provide ncurses and the required source/bin install layout, then address upstream
-Werrorportability across supported compilers.Acceptance checks
guix lint -L. freelarnpasses with no new errors.guix build -L. freelarnsucceeds from the pinned source with tests enabled where practical.freelarnin a pseudo-terminal with a local config/save directory and no network.Imported from GitHub issue/PR. Originally posted by htayj on 2026-08-14T13:17:16Z.
Goocastle recorded disposition: implementation-ready.
Created implementation ticket: #633.
Implementation-ready delivery brief. Canonical upstream is https://github.com/atsb/freelarn at fixed commit 8cd18cbaef70b9763a9f76cdfa11b78524ebcf5e (2022-07-25; no release tag); use Guix version 0-8cd18cb. The local channel already records the exact codeload origin and checksum at tay/packages/starred-a-c.scm:139-143: https://codeload.github.com/atsb/freelarn/tar.gz/8cd18cbaef70b9763a9f76cdfa11b78524ebcf5e with base32 SHA-256 198i2hrcn926rsq3hgz528vr1x0mhjqwsxqn7dmrxk80x0hhsnjv. That existing atsb-freelarn-source package uses copy-build-system to preserve source under share/atsb/projects/freelarn; it does not build or install the requested freelarn game, so no equivalent installed deliverable exists in the local Guix catalog (guix search freelarn and guix search larn returned no package).
License/source assessment: at the fixed revision, the single parent source origin has the complete Apache License 2.0 in LICENSE; docs/LICENSE repeats the grant; all .cpp/.hpp files in the pinned tree carry Apache-2.0 notices. The tree has no .gitmodules entry or gitlink/submodule and no separately fetched dependency, asset, or download hook. The historical note that FLTGoto.cpp was reimplemented from public-domain documentation does not identify a fetched second origin; the current file carries the Apache notice. Redistribution is therefore legally clear as Apache-2.0. README.md specifies C++11 and ncurses/pdcurses. The root Makefile is a GNU Make build: it compiles src/.cpp and src/**/.cpp with g++, -std=c++11, -DNIX_LOCAL and -lncurses, then moves the executable to bin/freelarn; make -n at the pinned checkout emitted the complete compile/link plan. The pinned upstream CI also installs ncurses and runs make, and the tree has no test/check target.
Package brief: add a gnu-build-system package in the channel's tay/packages/freelarn.scm, module (tay packages freelarn), using the fixed codeload origin above, ncurses as the sole compile/runtime library input, and the standard GNU Make/C++ toolchain supplied by gnu-build-system. No pkg-config, network, service, credential, downloaded asset, or optional integration input is needed. Delete configure, invoke make from the repository root so the upstream bin/freelarn layout is produced, and pass CC_FLAGS equal to the upstream flags with -Werror removed while retaining C++11, -Wall, -pedantic-errors, -DNIX_LOCAL and the other portability flags; this is the required warning-portability adaptation for supported GCC/Clang versions. Install the built bin/freelarn as a private $out/libexec/freelarn, install LICENSE, docs/LICENSE, README.md, docs/HISTORY and docs/CHANGELOG below $out/share/doc/freelarn, and do not install bin/stub. Set tests? false because upstream has no automated target, with the manual PTY proof below as the meaningful application check.
Runtime brief: the program has no configuration lookup and all game data is compiled into src/config/FLData.cpp and FLInlineData.hpp, but it writes the cwd-relative files fl_scorefile.dat, fl_savefile.dat and fl_messages.txt. Install $out/bin/freelarn as a Bash launcher using bash-minimal and coreutils-minimal: select ${XDG_STATE_HOME:-$HOME/.local/state}/freelarn, mkdir -p it, cd there, and exec $out/libexec/freelarn with the original arguments. This keeps scores, saves and message logs writable and persistent without writing the Guix store or an arbitrary caller cwd; no other wrapper variables or runtime services are required.
Acceptance proof: after implementation, run guix lint -L. freelarn and require no new errors, then run guix build -L. freelarn from the fixed source with no substitutes/network after the source is present in the store. In a network-disabled isolated PTY environment, create temporary HOME, XDG_STATE_HOME and an empty caller cwd; run the installed launcher through script -qefc with input newline, smoke, newline, S and assert exit 0, state/freelarn/fl_scorefile.dat, fl_messages.txt and fl_savefile.dat exist, and the caller cwd remains empty. Run it a second time in the same isolated state with input Qy; assert exit 0, the saved game is restored and fl_savefile.dat is consumed, proving ncurses initialization, embedded data, wrapper state isolation, save/restore and clean quit without network. This research phase claims no package proof: the attempted Guix toolchain invocation stopped before building because /var/guix/daemon-socket/socket is absent; the deterministic upstream make dry-run and local source-package metadata were the available preflights.
Imported from GitHub comment. Originally posted by htayj on 2026-08-28T07:03:37Z.
Published signed/authenticated commit4f98fefc5e2711b9d622913f7bcb8bb47d943bb5. Main source build, final --check reproducibility, offline lint and integrated event-driven PTY runtime passed for /gnu/store/xjrwvszskxri14zs9f69nmcaz072syah-freelarn-0-8cd18cb. Original pinned Apache game retained; actual name/live status/inventory/save/restoration/quit, explicit XDG and HOME fallback, save consumption and unchanged output checked. PNG633 regenerated from final output and visually inspected actual OMP Smoke map HP10/10. Existing upstream -Waddress and mismatched-new-delete warnings remain disclosed, not suppressed. No host profile changes or Goocastle execution.