GaloisInc / HaLVM

The Haskell Lightweight Virtual Machine (HaLVM): GHC running on Xen
BSD 3-Clause "New" or "Revised" License
1.05k stars 88 forks source link

Build failure: Not in scope `WORD_SIZE_IN_BITS_FLOAT##` #22

Closed dnaq closed 10 years ago

dnaq commented 10 years ago

When building integer-simple I get the errors

"inplace/bin/ghc-stage1" -hisuf hi -osuf  o -hcsuf hc -static  -O -H64m    -package-name integer-simple-0.1.1.0 -hide-all-packages -i -ilibraries/integer-simple/. -ilibraries/integer-simple/dist-install/build -ilibraries/integer-simple/dist-install/build/autogen -Ilibraries/integer-simple/dist-install/build -Ilibraries/integer-simple/dist-install/build/autogen -Ilibraries/integer-simple/.    -optP-include -optPlibraries/integer-simple/dist-install/build/autogen/cabal_macros.h -package ghc-prim-0.3.1.0 -package-name integer-simple -Wall -XHaskell98 -XCPP -XMagicHash -XBangPatterns -XUnboxedTuples -XForeignFunctionInterface -XUnliftedFFITypes -XNoImplicitPrelude -O2  -no-user-package-db -rtsopts      -odir libraries/integer-simple/dist-install/build -hidir libraries/integer-simple/dist-install/build -stubdir libraries/integer-simple/dist-install/build   -c libraries/integer-simple/./GHC/Integer/Type.hs -o libraries/integer-simple/dist-install/build/GHC/Integer/Type.o 

libraries/integer-simple/GHC/Integer/Type.hs:857:47:
    Not in scope: data constructor ‛WORD_SIZE_IN_BITS_FLOAT##’

libraries/integer-simple/GHC/Integer/Type.hs:868:64:
    Not in scope: data constructor ‛WORD_SIZE_IN_BITS_FLOAT#’

This can be solved by making the following changes in halvm-ghc/libraries/integer-simple/GHC/Integer/Type.hs

Replacing the occurence of

`WORD_SIZE_IN_BITS_FLOAT##

with

`WORD_SIZE_IN_BITS.0##

and replacing the occurence of

WORD_SIZE_IN_BITS_FLOAT#

with

WORD_SIZE_IN_BITS.0#
acw commented 10 years ago

Either a clean build or an update to a more recent ghc/base seems to have fixed this issue. At least, it built cleanly on my Ubuntu 13.10 test machine.