I tried -fvia-Cand -pgms, but none of them was able to create an executable file, snatching a lot of mistakes, such as Warning: retaining unknown function ``L4' in output from C compiler.
-fvia-C
-pgm
Warning: retaining unknown function ``L4' in output from C compiler
GHC cannot be used as a cross-compiler out of the box. The build system has some cross-compilation support, which we are currently working on improving. See CrossCompilation on the GHC Wiki Page for more information . I suggest continuing the discussion of users of the glasgow-haskell or cvs-ghc mailing lists.