0

Minimal example: I have a Cabal project with the following structure:

Test
  Test.cabal
  Test.hs

The code file:

{-
Description: Description.

* Description
-}
module Test (test) where
  -- | Test.
  test :: Int
  test = 0

The cabal file:

cabal-version: 3.8
author: Liisi Kerik
category: Test
description:
  Description.
name: Test
synopsis: Synopsis.
version: 0.0.0
library
  build-depends: base
  exposed-modules: Test
  ghc-options: -Wall

cabal haddock works but I get a warning:

Warning: The documentation for the following packages are not installed. No
links will be generated to these packages: base-4.18.0.0, ghc-bignum-1.3,
ghc-prim-0.10.0
 100% (  2 /  2) in 'Test'
Warning: Test: could not find link destinations for:

        - GHC.Types.Int

and the resulting html documentation contains no link to the documentation of Int.

I'm on Windows 10, GHC 9.6.2, Cabal 3.10.1.0.

I know that similar questions have been asked before but I don't understand the solutions, can't make them work or they're Linux-specific.

cafce25
  • 15,907
  • 4
  • 25
  • 31
Liisi
  • 329
  • 1
  • 6
  • Specifically _what_ solutions have you tried and what prevents them from making them work for you? – Cubic Aug 16 '23 at 10:43
  • I can't use that one since the solution is Linux-specific: https://stackoverflow.com/questions/31095109/haddock-could-not-find-link-destinations-for I also tried to reinstall packages: ```cabal install --reinstall --upgrade-dependencies world``` But that just threw an error. I'm not using sandbox, so sandbox-related answers aren't relevant. ```cabal v2-haddock --haddock-html-location='https://hackage.haskell.org/package/$pkg-$version/docs' --haddock-hyperlink-source --haddock-quickjump``` That one just doesn't help, the documentation is still missing the links. – Liisi Aug 16 '23 at 10:50

0 Answers0