[Haskell-cafe] Building Binaries with Cabal

Neil Mitchell ndmitchell at gmail.com
Thu Nov 30 15:53:36 EST 2006


>     let mydescrip = case System.Info.os of
>                       "mingw32" -> descrip
>                       _ -> descrip {buildDepends =

Arrrrggggghhhhhhh! To test if the operating system is windows you
compare against a hard coded string which _isn't_ an OS, but _is_ an
optional component by a 3rd party. It's required to build some Haskell
compilers, but for Yhc and Hugs its not required at any stage, and its
presence is optional!

I know this isn't your fault, it just scares me deeply that "os" could
return something that isn't an os! How about we add a cpu string,
which returns the amount of RAM installed. Or how about we add a
compiler string, which returns the users surname...



More information about the Haskell-Cafe mailing list