On Tue, Mar 20, 2012 at 1:45 AM, Ketil Malde <ke...@malde.org> wrote: > > I have a small project that installs a couple of Haskell tools and a > script that uses these. Cabal will of course build and install the > Haskell programs, but how can I get Cabal to install the script as > well? There's a host of UserHooks available¹, but it'd probably be > better to have an example than to try to experiment with the right > configuration.
I don't have an example handy, but I think you'll want preInts, instHook, or postInst. I'd probably go with postInst unless you need data provided by instHook's type that isn't passed to preInst or postInst. LocalBuildInfo /probably/ has the details you need (eg: installDirTemplates). Don't forget to invoke the default hook as part of your re-implementation -- if you override instHook, for example, you need to invoke the instHook that *would have* happened, or no installation will take place. --Rogan > > -k > > ¹ > http://www.haskell.org/cabal/release/cabal-latest/doc/API/Cabal/Distribution-Simple.html#t%3AUserHooks > -- > If I haven't seen further, it is by standing in the footprints of giants > > _______________________________________________ > Haskell-Cafe mailing list > Haskell-Cafe@haskell.org > http://www.haskell.org/mailman/listinfo/haskell-cafe _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe