Exposed module still hidden, why?
J. Garrett Morris
trevion at gmail.com
Tue Nov 20 15:31:39 EST 2007
As I understand it, Cabal hides all packages by default. If a package
is not in your dependencies, it won't be available to the build, no
matter the status in ghc-pkg.
(Incidentally, this had neat consequences in the past, since it means
that packages being hidden in ghc-pkg also does not make them
unavailable to cabal. I spent some time at a previous employer
attempt to debug a build failure where it turned out that the
developer experiencing the failure had not pulled all the changes. In
particular, we had packages A, B, and C, where C depended on A and B,
and B depended on A. The developer had pulled updates to A and C, but
not B. A built and installed a new version, hiding B (which was based
on an old version). The developer the build C. Cabal started with
everything hidden, then revealed A and B as specified by C's cabal
file, and the predictable build failures resulted. I have not tried
this with GHC/Cabal builds since 6.4.2, so this is probably no longer
On Nov 20, 2007 2:18 PM, Greg Fitzgerald <garious at gmail.com> wrote:
> Using GHC 6.8.1 on Windows XP, after having used ghc-pkg to expose
> 'directory-126.96.36.199', I am getting an error when I build haddock that says
> the package is hidden. When I type "ghc-pkg list", the package is not in
> parenthesis. Typing "ghc -v" says that it is using the file from
> "C:\ghc\ghc- 6.8.1\package.conf". That package.conf file has the 'exposed'
> set to True for that file. Why does GHC still think the package is hidden?
> ...\haddock-0.8>runhaskell Setup.lhs configure
> Configuring haddock-0.8...
> ...\haddock-0.8>runhaskell Setup.lhs build
> Preprocessing executables for haddock-0.8...
> shift/reduce conflicts: 5
> Building haddock-0.8...
> Could not find module `System.Directory':
> it is a member of package directory-188.8.131.52, which is hidden
> ...\haddock-0.8>ghc-pkg list
> Cabal-184.108.40.206, HUnit-220.127.116.11, OpenGL-18.104.22.168, QuickCheck-22.214.171.124,
> Win32-126.96.36.199, array-0.1.0.0, base-188.8.131.52, bytestring-0.9.0.1,
> cgi-3001.1.5.1, containers-0.1.0.0, directory-184.108.40.206, fgl-220.127.116.11,
> filepath-18.104.22.168, (ghc-6.8.1), haskell-src-22.214.171.124,
> haskell98-126.96.36.199 , hpc-0.5.0.0, html-188.8.131.52, mtl-184.108.40.206,
> network-220.127.116.11, old-locale-18.104.22.168, old-time-22.214.171.124,
> packedstring-0.1.0.0, parallel-126.96.36.199, parsec-188.8.131.52,
> pretty-184.108.40.206, process-220.127.116.11, random-18.104.22.168 ,
> regex-base-0.72.0.1, regex-compat-0.71.0.1, regex-posix-0.72.0.1,
> rts-1.0, stm-22.214.171.124, template-haskell-126.96.36.199, time-188.8.131.52,
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users at haskell.org
The man who'd introduced them didn't much like either of them, though
he acted as if he did, anxious as he was to preserve good relations at
all times. One never knew, after all, now did one now did one now did
More information about the Glasgow-haskell-users