unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Cc: 65860@debbugs.gnu.org
Subject: [bug#65860] [PATCH 0/4] Resolve a circular module dependencies in embedded modules
Date: Thu, 14 Sep 2023 11:10:44 +0200	[thread overview]
Message-ID: <87o7i5glwr.fsf@gnu.org> (raw)
In-Reply-To: <8734zhv49z.fsf@gmail.com> (Maxim Cournoyer's message of "Wed, 13 Sep 2023 23:10:16 -0400")

Hi,

Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis:

> Ludovic Courtès <ludo@gnu.org> writes:

[...]

>> People will lose the ability to install those toolchains, for instance
>> with ‘guix install propeller-toolchain’, or to upgrade profiles that
>> contain them (though ‘guix install axoloti-runtime’ is still good, for
>> instance).
>>
>> I’m not sure whether that’s acceptable, but we should check with known
>> users of this, such as Ricardo.
>
> It's a pity to loose that ability (it's also a pity to not be able to
> simply 'guix install gcc-cross-some-target', for the same reason) but
> the statu quo where pulling (gnu packages avr) causes hard to grasp
> failures is worst, in my opinion.  I wasn't able to work on adding
> packages dependent on (gnu packages avr) for that reason.  Debugging was
> a pain.

Oh yes, I’ve been there, so I can tell you I sympathize.  :-)

I agree that this needs to be addressed.  I wondered whether/how hard we
should search for a different solution.

>> I’ve always felt that these toolchains should be provided as part of the
>> “regular” cross-compilation framework in cross-base.scm.  Packages that
>> always need to be cross-compiled (to AVR microcontrollers, etc.) would
>> have a hardcoded #:target in their ‘arguments’ field.  I forgot why this
>> was rejected.
>
> That'd be an improvement, I think.  Right now we have to call a
> procedure in the input fields everywhere, it's not very elegant.

BTW, another issue with the package-returning procedures: they return a
fresh package object at each call, which defeats caching.  I think you
should be able to observe it with:

  GUIX_PROFILING=object-cache guix build axoloti-runtime -d  --no-grafts

The effect will be more acute on the build farms since they compute
derivations for everything that depends on these toolchains.

The solution would be to make those procedures memoizing, with ‘mlambda’
or similar.

Ludo’.




  reply	other threads:[~2023-09-14  9:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1694406359.git.maxim.cournoyer@gmail.com>
2023-09-11  4:25 ` [bug#65860] [PATCH 1/4] gnu: avr: Delay all cross compilation packages Maxim Cournoyer
2023-09-13 20:27   ` [bug#65860] [PATCH 0/4] Resolve a circular module dependencies in embedded modules Ludovic Courtès
2023-09-14  3:10     ` Maxim Cournoyer
2023-09-14  9:10       ` Ludovic Courtès [this message]
2023-09-18  0:52         ` Maxim Cournoyer
2023-09-25 17:58           ` [bug#66063] [PATCH v2 0/3] " Maxim Cournoyer
2023-09-11  4:25 ` [bug#65860] [PATCH 2/4] gnu: embedded: Turn packages using top-level variables into procedures Maxim Cournoyer
2023-09-11  4:25 ` [bug#65860] [PATCH 3/4] gnu: Remove extraneous imports Maxim Cournoyer
2023-09-13 20:06   ` Ludovic Courtès
2023-09-17 20:27     ` Maxim Cournoyer
2023-09-11  4:26 ` [bug#65860] [PATCH 4/4] doc: Add new 'Circular Module Dependencies' section Maxim Cournoyer
2023-09-11  4:19 [bug#65860] [PATCH 0/4] Resolve a circular module dependencies in embedded modules Maxim Cournoyer

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=87o7i5glwr.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=65860@debbugs.gnu.org \
    --cc=maxim.cournoyer@gmail.com \
    /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).