On Sun, Feb 24, 2013 at 5:28 PM, Andrew Cowie <andrew@operationaldynamics.com> wrote:
On Sat, 2013-02-16 at 08:18 +0100, Henk-Jan van Tuyl wrote:
> > Anyone have any idea if the Cabal library exposes this
> > somewhere?
>
> See...

I blogged about my solution using Krzysztof and Henk's suggestions here:
http://blogs.operationaldynamics.com/andrew/software/haskell/config-dot-h-and-ifdef

Cheers everyone,

I read your blog post and I'm afraid I don't see the point: you write some code to tap into a pre-existing library that figures out what platform you are on so that you can write out a 'config.h' that #define's the platform you are on so that you can then use the C preprocessor to pick a particular code path via conditional compilation.  Why go to all that bother?  Why not just write code that writes out the path you want to take and link against it?

        - Dan C.