haskell / attoparsec

A fast Haskell library for parsing ByteStrings
http://hackage.haskell.org/package/attoparsec
Other
514 stars 93 forks source link

Haddock build issue with internal library? #212

Closed swt2c closed 2 years ago

swt2c commented 2 years ago

On Debian, we're having trouble building attoparsec 0.14.4 documentation (seems to be related to the internal library). Any ideas on what might be going wrong? It seems like Haddock shouldn't be trying to build documentation for internal libraries?

CC: @Bodigrim

Data/Attoparsec/Internal/Types.hs:43:1: error:
    Could not find module ‘Data.Attoparsec.ByteString.Buffer’
    There are files missing in the ‘attoparsec-0.14.4’ package,
    try running 'ghc-pkg check'.
    Use -v (or `:set -v` in ghci) to see a list of the files searched for.
   |
43 | import qualified Data.Attoparsec.ByteString.Buffer as B
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Data/Attoparsec/Internal/Types.hs:44:1: error:
    Could not find module ‘Data.Attoparsec.Text.Buffer’
    There are files missing in the ‘attoparsec-0.14.4’ package,
    try running 'ghc-pkg check'.
    Use -v (or `:set -v` in ghci) to see a list of the files searched for.
   |
44 | import qualified Data.Attoparsec.Text.Buffer as T
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Full build log here: https://buildd.debian.org/status/fetch.php?pkg=haskell-attoparsec&arch=amd64&ver=0.14.4-1&stamp=1655429416&raw=0

Bodigrim commented 2 years ago

@swt2c I cannot reproduce,

cabal unpack attoparsec-0.14.4
cd attoparsec-0.14.4
cabal-3.4.1.0 haddock -w ghc-9.0.2

succeeds on my machine (MacOS).

swt2c commented 2 years ago

OK. I will try to investigate further.

swt2c commented 2 years ago

It turns out that we needed to build the package first. After building, it works fine.