Error building ghc on raspberry pi.

roconnor at theorem.ca roconnor at theorem.ca
Thu Jan 3 05:38:04 CET 2013


Some further information it seems that llc is segfaulting:

pi at raspberrypi /tmp/ghc-7.4.1 $ llc -O3 -relocation-model=static /tmp/ghc7189_0/ghc7189_0.bc -o /tmp/ghc7189_0/ghc7189_0.lm_s 
Stack dump:
0.      Program arguments: llc -O3 -relocation-model=static /tmp/ghc7189_0/ghc7189_0.bc -o /tmp/ghc7189_0/ghc7189_0.lm_s 
1.      Running pass 'Function Pass Manager' on module '/tmp/ghc7189_0/ghc7189_0.bc'.
2.      Running pass 'ARM Instruction Selection' on function '@ghczmprim_GHCziTypes_Czh_info'
Segmentation fault
pi at raspberrypi /tmp/ghc-7.4.1 $ llc --version
Low Level Virtual Machine (http://llvm.org/):
   llvm version 3.0
    (Debian 3.0-10)Optimized build.
   Built Jul 26 2012 (20:20:52).
   Host: arm-unknown-linux-gnueabihf
   Host CPU: (unknown)

   Registered Targets:
     alpha    - Alpha [experimental]
     arm      - ARM
     bfin     - Analog Devices Blackfin [experimental]
     c        - C backend
     cellspu  - STI CBEA Cell SPU [experimental]
     cpp      - C++ backend
     mblaze   - MBlaze
     mips     - Mips
     mips64   - Mips64 [experimental]
     mips64el - Mips64el [experimental]
     mipsel   - Mipsel
     msp430   - MSP430 [experimental]
     ppc32    - PowerPC 32
     ppc64    - PowerPC 64
     ptx32    - PTX (32-bit) [Experimental]
     ptx64    - PTX (64-bit) [Experimental]
     sparc    - Sparc
     sparcv9  - Sparc V9
     systemz  - SystemZ
     thumb    - Thumb
     x86      - 32-bit X86: Pentium-Pro and above
     x86-64   - 64-bit X86: EM64T and AMD64
     xcore    - XCore

On Wed, 2 Jan 2013, roconnor at theorem.ca wrote:

> I'm trying to build ghc-7.4.1 using ghc-7.4.1 on my raspberry pi (armv6l) and 
> I get the following error:
>
> "inplace/bin/ghc-stage1"   -H32m -O    -package-name ghc-prim-0.2.0.0 
> -hide-all-packages -i -ilibraries/ghc-prim/. 
> -ilibraries/ghc-prim/dist-install/build 
> -ilibraries/ghc-prim/dist-install/build/autogen 
> -Ilibraries/ghc-prim/dist-install/build 
> -Ilibraries/ghc-prim/dist-install/build/autogen -Ilibraries/ghc-prim/. 
> -optP-include 
> -optPlibraries/ghc-prim/dist-install/build/autogen/cabal_macros.h -package 
> rts-1.0  -package-name ghc-prim -XHaskell98 -XCPP -XMagicHash 
> -XForeignFunctionInterface -XUnliftedFFITypes -XUnboxedTuples 
> -XEmptyDataDecls -XNoImplicitPrelude -O2  -no-user-package-conf -rtsopts 
> -odir libraries/ghc-prim/dist-install/build -hidir 
> libraries/ghc-prim/dist-install/build -stubdir 
> libraries/ghc-prim/dist-install/build -hisuf hi -osuf  o -hcsuf hc -c 
> libraries/ghc-prim/./GHC/Types.hs -o 
> libraries/ghc-prim/dist-install/build/GHC/Types.o
> Stack dump:
> 0.      Program arguments: llc -O3 -relocation-model=static 
> /tmp/ghc6324_0/ghc6324_0.bc -o /tmp/ghc6324_0/ghc6324_0.lm_s 1.      Running 
> pass 'Function Pass Manager' on module '/tmp/ghc6324_0/ghc6324_0.bc'.
> 2.      Running pass 'ARM Instruction Selection' on function 
> '@ghczmprim_GHCziTypes_Czh_info'
> /tmp/ghc6324_0/ghc6324_0.lm_s: openBinaryFile: does not exist (No such file 
> or directory)
> make[1]: *** [libraries/ghc-prim/dist-install/build/GHC/Types.o] Error 1
> make: *** [all] Error 2
>
> Anyone have any thoughts on what might be the matter and what I can do to fix 
> it.  (If only openBinaryFile said which file doesn't exist.)
>
>

-- 
Russell O'Connor                                      <http://r6.ca/>
``All talk about `theft,''' the general counsel of the American Graphophone
Company wrote, ``is the merest claptrap, for there exists no property in
ideas musical, literary or artistic, except as defined by statute.''



More information about the Glasgow-haskell-users mailing list