Question

I'm running Ubuntu Precise with an amd64 kernel and amd64 userland. I've just installed Haskell using sudo apt-get install haskell-platform. Now I'd like to install a binary using cabal install .... However, that generates an amd64 binary. How is it possible to make Cabal generate an i386 binary (e.g. like gcc -m32) without creating a chroot of a full i386 Ubuntu system (using debootstrap) or creating a virtual machine, or running it on an i386 userland?

Était-ce utile?

La solution

You can get an i386 binary of GHC from the official download site. It is safe to install multiple versions of GHC alongside each other (though I'm not sure whether it handles multiple architectures for a single version gracefully). You can then instruct cabal which compiler to use with its -w option.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top