Continue reading if you get errors like this:
usr/bin/ghc -hide-all-packages -package Cabal -package base -package binary -package bytestring -package containers -package deepseq -package directory -package exceptions -package filepath -package haskeline -package mtl -package parsec -package pretty -package process -package stm -package template-haskell -package terminfo -package text -package transformers -package unix -package xhtml --make /var/tmp/portage/dev-haskell/xml-conduit-1.9.1.1/work/xml-conduit-1.9.1.1/Setup.hs -j4 +RTS -A256M -qb0 -RTS -threaded -dynamic -o setup
[1 of 1] Compiling Main ( /var/tmp/portage/dev-haskell/xml-conduit-1.9.1.1/work/xml-conduit-1.9.1.1/Setup.hs, /var/tmp/portage/dev-haskell/xml-conduit-1.9.1.1/work/xml-conduit-1.9.1.1/Setup.o )
/var/tmp/portage/dev-haskell/xml-conduit-1.9.1.1/work/xml-conduit-1.9.1.1/Setup.hs:3:1: error:
Could not load module ‘Distribution.Extra.Doctest’
It is a member of the hidden package ‘cabal-doctest-1.0.9’.
You can run ‘:set -package cabal-doctest’ to expose it.
(Note: this unloads all the modules in the current scope.)
Use -v (or `:set -v` in ghci) to see a list of the files searched for.
|
3 | import Distribution.Extra.Doctest (defaultMainWithDoctests)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Add GHC_BOOTSTRAP_PACKAGES to your ebuild to bring a number of packages into scope for Setup.hs. Example:
GHC_BOOTSTRAP_PACKAGES=(
cabal-doctest
haskell-gi
)
A change to haskell-cabal.eclass is being added, where extra dependencies to build Setup.hs must now be listed in the ebuild using the new GHC_BOOTSTRAP_PACKAGES variable. Without this new feature, it is possible to get namespace collisions such as:
/var/tmp/portage/dev-vcs/darcs-2.16.5-r3/work/darcs-2.16.5/Setup.hs:7:1: error:
Ambiguous module name ‘Distribution.PackageDescription’:
it was found in multiple packages:
Cabal-3.6.3.0 Cabal-syntax-3.8.1.0
|
7 | import Distribution.PackageDescription ( PackageDescription )
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Most common packages bundled with GHC are exposed by default, which is all that is needed for most custom Setup.hs setups. However, it is likely there are still packages in the tree that need to be fixed by adding GHC_BOOTSTRAP_PACKAGES.
Packages needing a fix (so far):
Continue reading if you get errors like this:
Add
GHC_BOOTSTRAP_PACKAGESto your ebuild to bring a number of packages into scope forSetup.hs. Example:A change to
haskell-cabal.eclassis being added, where extra dependencies to buildSetup.hsmust now be listed in the ebuild using the newGHC_BOOTSTRAP_PACKAGESvariable. Without this new feature, it is possible to get namespace collisions such as:Most common packages bundled with GHC are exposed by default, which is all that is needed for most custom
Setup.hssetups. However, it is likely there are still packages in the tree that need to be fixed by addingGHC_BOOTSTRAP_PACKAGES.Packages needing a fix (so far):
app-portage/hackportapp-text/haskell-awkdev-haskell/foldldev-haskell/pretty-simpledev-haskell/generic-lensdev-haskell/xml-conduitdev-haskell/co-log-coredev-haskell/haskell-gidev-haskell/pcg-randomdev-haskell/xml-html-qqdev-haskell/polysemy-plugindev-haskell/polysemydev-vcs/git-annexdev-haskell/gi-gmoduledev-haskell/gi-glibdev-haskell/gi-gobjectdev-haskell/gi-giodev-haskell/gi-cairodev-haskell/gi-freetype2dev-haskell/gi-harfbuzzdev-haskell/gi-pangodev-haskell/gi-atkdev-haskell/gi-dbusmenudev-haskell/gi-xlibdev-haskell/gi-gdkpixbufdev-haskell/gi-gdkdev-haskell/gi-gtkdev-haskell/gi-vtedev-haskell/gi-gdkx11dev-haskell/gi-dbusmenugtk3dev-haskell/gi-gtksourcedev-haskell/validation-selectivedev-haskell/gi-gstdev-haskell/gi-gstbasedev-haskell/gi-gstvideox11-terms/termonaddev-haskell/pangodev-haskell/cairodev-haskell/glibdev-haskell/giodev-haskell/gtkdev-haskell/gtk3dev-haskell/gtkglextdev-haskell/svgcairodev-haskell/fixed-vectordev-haskell/nonempty-vectordev-haskell/higgledydev-haskell/lhs2tex