[Haskell-cafe] Using Cabal during development
daniel.is.fischer at web.de
Wed Feb 10 13:11:37 EST 2010
Am Mittwoch 10 Februar 2010 18:16:42 schrieb Limestraël:
> Neil Brown-7 wrote:
> > Don't you simply need to do what the error message says, and add (*in
> > the Executable section*, at the end of the file):
> Nope, just check my previous message (my issue (2)):
I think http://www.haskell.org/ghc/docs/latest/html/Cabal/authors.html
might help, example 3, a package containing a library and executable
Cabal-Version: >= 1.2
Author: Angela Author
Synopsis: Package with library and two programs
Exposed-Modules: A, B, C
Other-Modules: A, B
Other-Modules: A, C, Utils
For the executable, you have to specify the source dirs and the modules
*from the library you are developing* it needs.
A little inconvenient, admittedly.
> Limestrael wrote:
> > (2) well, then, when building, if I don't specify that my executable
> > depends on my lib, I got:
> > SFML/Direct/Graphics.hs:51:7:
> > Could not find module `SFML.Direct.Types.Enums':
> > It is a member of the hidden package `HSFML-1.5'.
> > Perhaps you need to add `HSFML' to the build-depends in your
> > .cabal file.
> > it is a hidden module in the package `HSFML-1.5'
> > Use -v to see a list of the files searched for.
> > and if I do what it asks me to do (to add the line 'Build-Depends:
> > HSFML' in the 'Executable' section of my .cabal file), I'm told when
> > 'cabal build'ing:
> > cabal: internal error: could not construct a valid install plan.
> > The proposed (invalid) plan contained the following problems:
> > The following packages are involved in a dependency cycle HSFML-1.5
More information about the Haskell-Cafe