Haskell packages retain references to bootstrap variants

  • Open
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Ricardo Wurmus
Owner
unassigned
Submitted by
Ricardo Wurmus
Severity
normal
R
R
Ricardo Wurmus wrote on 22 May 2020 11:17
(address . bug-guix@gnu.org)
87tv08coqo.fsf@elephly.net
Some Haskell packages have a “-bootstrap” variant to cut dependency
cycles. Unfortunately, these bootstrap variants remain in the reference
graph alongside their non-bootstrap counterparts.

An example:

Toggle snippet (15 lines)
$ guix gc -R /gnu/store/1k0dqlyqyvhd3ax60a2y6l2sip0z7b26-ghc-scientific-0.3.6.2 | grep -- -bootstrap
/gnu/store/lvas21ha80yp02lc3z8fgpcaf59n1jp7-ghc-unordered-containers-bootstrap-0.2.10.0-doc
/gnu/store/22309kdxaapz6z3jm6wfy6bk1yybvxg9-ghc-hashable-bootstrap-1.2.7.0-doc
/gnu/store/mhpfjyx302d89w9484ivylczp8pzzfl2-ghc-hashable-bootstrap-1.2.7.0
/gnu/store/bfc5iyrlqr23fhp8awmd481za4aank9h-ghc-nats-bootstrap-1.1.2
/gnu/store/1nym2bjr3adhy1pa79iiasnfdz285b08-ghc-unordered-containers-bootstrap-0.2.10.0
/gnu/store/xjgjshwhpc36nfagfz0bg3nrg6fkn615-ghc-integer-logarithms-bootstrap-1.0.3
/gnu/store/jljsapda2vbxn7p37i6sk026r9gbrib7-ghc-scientific-bootstrap-0.3.6.2
/gnu/store/gjsmr0nrgsdyxcq9wizcx31cxpg7f9x7-ghc-semigroups-bootstrap-0.18.5
/gnu/store/ywlnsg1lcf0yzisivi7gm2pmls5jnxbb-ghc-attoparsec-bootstrap-0.13.2.3
/gnu/store/w0q1s85mwvxk44gcs9lmh994rm8p7ik6-ghc-wcwidth-bootstrap-0.0.2
/gnu/store/ibk4x2bkqm7krc6cc2d61hvi213zvvfq-ghc-splitmix-bootstrap-0.0.3
/gnu/store/57zjc7i8hb9sb18yflr46yi1vvr21y31-ghc-clock-bootstrap-0.8

--
Ricardo
R
R
Ricardo Wurmus wrote on 25 May 2020 11:18
(address . 41451@debbugs.gnu.org)
87h7w4jrtw.fsf@mdc-berlin.de
Ricardo Wurmus <rekado@elephly.net> writes:

Toggle quote (4 lines)
> Some Haskell packages have a “-bootstrap” variant to cut dependency
> cycles. Unfortunately, these bootstrap variants remain in the reference
> graph alongside their non-bootstrap counterparts.

On a related note, Haskell packages retain needless references to *all*
other Haskell packages at build time. That’s because we *copy* their
.conf files at build time to create a package cache, and these .conf
files thus propagate even to unrelated packages.

We are effectively using propagation via the lib/ghc-8.6.5/<name>.conf.d
directory.

I don’t know if all the files in there are really necessary, but it
seems to me that perhaps this leads to spurious references.

--
Ricardo
L
L
Ludovic Courtès wrote on 25 May 2020 23:10
Re: bug#41451: Haskell packages retain references to bootstrap variants
(name . Ricardo Wurmus)(address . rekado@elephly.net)(address . 41451@debbugs.gnu.org)
87tv03u3ev.fsf@gnu.org
Ricardo Wurmus <rekado@elephly.net> skribis:

Toggle quote (11 lines)
> Ricardo Wurmus <rekado@elephly.net> writes:
>
>> Some Haskell packages have a “-bootstrap” variant to cut dependency
>> cycles. Unfortunately, these bootstrap variants remain in the reference
>> graph alongside their non-bootstrap counterparts.
>
> On a related note, Haskell packages retain needless references to *all*
> other Haskell packages at build time. That’s because we *copy* their
> .conf files at build time to create a package cache, and these .conf
> files thus propagate even to unrelated packages.

Weren’t these files eventually superseded by the
‘ghc-package-cache-file’ profile hook? Or are these two different
things?

Ludo’.
R
R
Ricardo Wurmus wrote on 26 May 2020 08:49
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 41451@debbugs.gnu.org)
878shfjim0.fsf@elephly.net
Ludovic Courtès <ludo@gnu.org> writes:

Toggle quote (17 lines)
> Ricardo Wurmus <rekado@elephly.net> skribis:
>
>> Ricardo Wurmus <rekado@elephly.net> writes:
>>
>>> Some Haskell packages have a “-bootstrap” variant to cut dependency
>>> cycles. Unfortunately, these bootstrap variants remain in the reference
>>> graph alongside their non-bootstrap counterparts.
>>
>> On a related note, Haskell packages retain needless references to *all*
>> other Haskell packages at build time. That’s because we *copy* their
>> .conf files at build time to create a package cache, and these .conf
>> files thus propagate even to unrelated packages.
>
> Weren’t these files eventually superseded by the
> ‘ghc-package-cache-file’ profile hook? Or are these two different
> things?

That hook also operates on the .conf.d directory containing all .conf
files that have been copied from Haskell inputs.

--
Ricardo
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 41451@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 41451
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch