GNU bug report logs - #51655
[PATCH] build-system: haskell: Add ‘package-with-explicit-haskell’ procedure.

Previous Next

Package: guix-patches;

Reported by: Xinglu Chen <public <at> yoctocell.xyz>

Date: Sun, 7 Nov 2021 10:56:01 UTC

Severity: normal

Tags: patch

Full log


View this message in rfc822 format

From: zimoun <zimon.toutoune <at> gmail.com>
To: Xinglu Chen <public <at> yoctocell.xyz>, 51655 <at> debbugs.gnu.org
Cc: Lars-Dominik Braun <lars <at> 6xq.net>
Subject: [bug#51655] [PATCH] build-system: haskell: Add ‘package-with-explicit-haskell’ procedure.
Date: Sun, 19 Dec 2021 10:23:05 +0100
Hi,

On Sun, 19 Dec 2021 at 09:47, Xinglu Chen <public <at> yoctocell.xyz> wrote:

>>> +@lisp
>>> +(use-modules (guix build-system haskell))
>>> +
>>> +(define (default-haskell-8.8)
>>> +  ;; Lazily resolve the binding to avoid a circular dependency.
>>> +  (let ((haskell (resolve-interface '(gnu packages haskell))))
>>> +    (module-ref haskell 'ghc-8.8)))
>>> +
>>> +(define package-with-haskell-8.8
>>> +  (package-with-explicit-haskell (delay (default-haskell-8.8))
>>> +                                 "ghc-" "ghc-8.8-"
>>> +                                 #:variant-property 'ghc-8.8-variant))
>>> +@end lisp
>>
>> As Lars said, an instance is missing, IMHO.
>
> Not sure what you are referring to here, what exactly do you mean with
> “instance”?

For example, something as:

    (package-with-haskell-8.8 hledger)

Cheers,
simon




This bug report was last modified 3 years and 178 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.