It seems the meaning of the -main-is switch for GHC and the Main-Is
build option for Cabal executables differ. With GHC, I can point to
any function "main" in any module, but in Cabal I must point to a
filename with precisely the module name "Main". This is tying my hands
with regard to organizing a default executable and exposing some of
its functionality as a library. Is there a way to get around this
restriction?

Concretely, I want to point Cabal's Main-Is to Program/Main.hs which starts with

  module Program.Main where

instead of just

  module Main where


Is this currently possible? I recognize the "add a separate
Program-Main.hs file" workaround, but I'll avoid it if I can.

Thanks!
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to