I'm having trouble with install --builddir.

If I run

$ cabal install --builddir /some/absolute/path test-framework

I get an error after regex-posix is installed, during the build of 
test-framework:

Text/Regex/Posix/Wrap.hsc:141:8:
   Could not find module `Text.Regex.Base.RegexLike'
   It is a member of the hidden package `regex-base-0.93.2'.
   Perhaps you need to add `regex-base' to the build-depends in your .cabal 
file.
   Use -v to see a list of the files searched for.

But if I run

$ cabal install --builddir /some/absolute/path regex-posix
$ rm -r /some/absolute/path
$ cabal install --builddir /some/absolute/path test-framework

I do not get the error. Between experiments I'm removing my ~/.cabal and ~/.ghc 
and running cabal update.


Naively, it looks to me like using an absolute builddir has changed things so 
successive packages share the same intermediate files, which in turn has caused 
a later package to erroneously recompile a previously generated file.

My ultimate aim is only to be able to use cabal-dev for my development builds, 
but without writing into my source tree. Is there any way to specify a build 
directory outside the source of a package without it winding up shared? 
Could/should cabal instead create a separate subdirectory within the specified 
builddir for each package to be built, so that specifying an external location 
didn't break things?

Thanks,
Ben Scarlet
_______________________________________________
cabal-devel mailing list
cabal-devel@haskell.org
http://www.haskell.org/mailman/listinfo/cabal-devel

Reply via email to