From: Jesse Gibbons <jgibbons2357@gmail.com>
To: 43061@debbugs.gnu.org
Subject: bug#43061: freedink package is needlessly complex
Date: Wed, 26 Aug 2020 10:55:10 -0600 [thread overview]
Message-ID: <5dadebde-37e5-ce5e-6107-8e45dfeefa8d@gmail.com> (raw)
TL;DR The freedink package is defined in a complex way that breaks
guix's custom source build features and the GUI wrapper.
The freedink package wraps the freedink-engine and freedink-data
packages so the resulting executable bin/freedink runs the freedink
engine pointed at the output of freedink-data. The wrapped packages are
not exported from gnu/packages/games.scm. Because of these two design
choices,
-> guix build --sources=all freedink does not list the freedink-data source.
-> the only way to get the freedink-data source is to run guix build
--sources=transitive freedink. This is not ideas because it gets the
source for bash as well.
-> "guix build --with-source=freedink-data=..." has no effect on
freedink, so guix cannot be used to facilitate freedoms 1 and 3 with
freedink, unlike most other packages. To be clear, freedoms 1 (to
modify the software) and 3 (to distribute the modified software) are not
violated, but a very nice feature of guix that makes them less complex
does not work with freedink. To achieve a guix install or pack of
freedink as it is currently defined with custom sources and/or data, one
must define new freedink packages, which is more work than one or two
simple command-line flags.
-> freedink-dfarc does not find "dinkedit" or "dink", which are links to
binaries built in freedink-engine. Once again, freedoms 1 and 3 are a
little more difficult to exercise than reasonably expected given what
guix provides, but not violated. To point freedink-dfarc to the correct
binaries, one must copy the store location in the wrapper script
produced by freedink. Obviously, this store location will not
automatically be updated when freedink-engine is upgraded.
-> Because the wrapper hard-codes a location to look for the data, I
suspect (but have yet to confirm) that an attempt to use freedink-dfarc
to build a modified version of freedink will ultimately throw an error.
There must be a way to re-package freedink such that:
1) It works with the custom source build features provided by guix.
2) The guix wrapper freedink-dfarc is neither necessary for running
freedink, nor broken when used to run freedink.
The solution could be as simple as publicly exposing freedink-engine and
freedink-data, and redefining the freedink package to simply take the
two packages as inputs and produce a wrapper script. The script should
probably have a name other than "freedink" or "dink" so all three
packages can optionally co-exist in the same profile without a name
conflict. I will try this solution and send a patch if it passes the
following tests:
-> The sources for all freedink-related packages can be produced with
"guix build --source" or "guix build --sources=all"
-> all freedink-related packages can be installed and packed with
modified local sources specified by --with-source
-> installing freedink does not add anything to the profile other than a
wrapper script.
-> There is no name conflict between the executables provided by
freedink-engine and freedink
If anyone knows why freedink is packaged the way it is and thinks it is
better that way, I want to know your reasons before I begin to attempt
to fix this issue, because those reasons could lead me to a different
approach.
I suspect freedink is not the only package with these issues.
-Jesse
next reply other threads:[~2020-08-26 16:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-26 16:55 Jesse Gibbons [this message]
2020-08-28 14:07 ` bug#43061: freedink package is needlessly complex Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5dadebde-37e5-ce5e-6107-8e45dfeefa8d@gmail.com \
--to=jgibbons2357@gmail.com \
--cc=43061@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).