On Mon, Mar 25, 2013 at 10:05 AM, Henning Thielemann <lemming@henning-thielemann.de> wrote:

On Mon, 25 Mar 2013, Andreas Voellmy wrote:

Hi, 
I have a library that has some modules written as .hsc files and I want to include some executables that use
those modules. Cabal doesn't seem to find the modules when it is building the executable. It complains that
the module used by the executable is in a hidden package (of the same name as the package being built).
Adding the package as a dependency in the executable section doesn't work since it references a library
defined in the same package.

This should work since Cabal-1.14. Can you show, how exactly you added the dependency to the executable?

I included the two source files, A.hsc and B.hs, and the cabal file in my last email. That shows how I add the dependency in the executable section. I have those three files in a single directory.