
10 May
2013
10 May
'13
2:57 a.m.
On Thu, May 09, 2013 at 06:10:55PM +0200, Ertugrul Söylemez wrote:
If the program is just a demo that you wouldn't normally want to install with the library, you can make it a test suite instead of an executable:
This seems like a strange hack to me. If it's not a test suite you shouldn't call it one. Instead you can use a flag which the user has to manually specify if they want the demo executables. Something like flag demo description: Install the demos. default: False manual: True executable theDemo ... if !flag(demo) buildable: False if flag(demo) build-depends: base, mylib, ... For a real-world example of this, see http://hackage.haskell.org/package/diagrams%2Dbuilder . -Brent