
On Fri, Aug 22, 2014 at 10:22 AM, Omari Norman
But a tool like Cartel does nothing about compile times. If compile times are really a concern, I would just put the library in a completely separate package and package the executables and tests separately.
One way to help reduce compile times (a bit anyway) is to separate the executables and tests into parallel source directories from your library code. I generally use a layout like this: <project dir>/ - project.cabal - src/ - apps/ - tests/resources/ - tests/src/ Library code goes in src, application Main's go in apps/, test source goes in tests/src/ and any necessary data files go in tests/resources. Then tests and apps defined in the cabal file depend on the library, and the source for the library is not rebuilt for each executable/test declaration in the cabal file (generally speaking; with flags and custom builds you can cause just about anything...) --Rogan