Can anyone tell me how to determine if I am using 64-bit or 32-bit Glasgow Haskell Compiler (GHC) on OS X? I have installed both 32 and 64-bit versions, and I don’t know which one current is pointing to.
⚡ pwd
/Library/Haskell
⚡ ll
bin -> current/bin
current -> ghc-7.4.2
doc -> current/doc
ghc-7.0.3
ghc-7.4.2
Furthermore…
⚡ ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.4.2
… does not contain the information I am after.
Incidentally, I am running OS X Version 10.7.5 on an Intel Core i5, so I can run either, but I am trying to get yesod going…
There is a bug in the 64-bit GHC 7.4 for Mac which prevents yesod devel from working correctly. This bug has been corrected in 7.6. However, as 7.4 is still the recommended platform for development, it is advisable to install the 32-bit version of GHC.
Try
ghc --info, which should list the target architecture.A more general-purpose solution would be to chase down symlinks and scripts to the actual GHC binary, and then run
fileon it.