
On Wed, Jul 21, 2010 at 04:53, Rogan Creswick
On Tue, Jul 20, 2010 at 8:50 PM, Tom Hawkins
wrote: Thanks. I tried this, but it appears cabal-install ignores the Setup.hs file. The only way I could get it to take is if I run 'runhaskell Setup.hs configure' directly. I always assumed cabal-install runs Setup.hs under the hood, but apparently not. Why is this?
I believe you must set
Build-type: Custom
in your cabal file to use user hooks in Setup.hs. I don't fully understand the implications of using Custom, though.
I am successfully using hooks with the following in my .cabal file: Build-Type : Simple and my main in Setup.hs looks like this: main = defaultMainWithHooks $ simpleUserHooks { cleanHook = profileClean , runTests = runTestsBuild } /M -- Magnus Therning (OpenPGP: 0xAB4DFBA4) magnus@therning.org Jabber: magnus@therning.org http://therning.org/magnus identi.ca|twitter: magthe