[Haskell-cafe] generating object file for ARM

Fabien R theedge456 at free.fr
Sat Feb 6 15:19:43 UTC 2016


Hello,

I would like to link my Haskell module with existing object files for 
armv7-m. I use ghc 7.4.1 on debian/amd64.

This command seems incorrect or incomplete:
ghc -pgmcarm-none-eabi-gcc -pgmParm-none-eabi-cpp -pgmaarm-none-eabi-as 
-pgmlarm-none-eabi-ld  -keep-tmp-files  HaskellModule.hs

A lot of errors appeared:
[1 of 1] Compiling HaskellModule    ( HaskellModule.hs, HaskellModule.o )
/tmp/ghc13654_0/ghc13654_0.s: Assembler messages:

/tmp/ghc13654_0/ghc13654_0.s:5:0:
      Error: unrecognized symbol type ""

/tmp/ghc13654_0/ghc13654_0.s:17:0:
      Error: unrecognized symbol type ""

/tmp/ghc13654_0/ghc13654_0.s:29:0:
      Error: bad instruction `leaq -40(%rbp),%rax'

/tmp/ghc13654_0/ghc13654_0.s:30:0:
      Error: bad instruction `cmpq %r15,%rax'

Any hints ?

-- 
Fabien
______________________________


More information about the Haskell-Cafe mailing list