Definition of endianess removed
Summary
Commit ee8118ca removes the inclusion of file ghcconfig.h in file compiler/HsVersions.hs. However, file ghcconfig.h includes ghcautoconf.h where the macro WORDS_BIGENDIAN beside others is defined. As a result all checks of the form
#if defined(WORDS_BIGENDIAN)
silently fail even for big endian machines which results in broken binaries.
Macro WORDS_BIGENDIAN is used in the following files which must be taken care of:
-
compiler/llvmGen/Llvm/Types.hs(fixed in !2228 (closed)) -
libraries/ghc-heap/GHC/Exts/Heap.hs(includesghcconfig.hwhich itself includesghcautoconf.h) -
libraries/Cabal/Cabal/Distribution/Fields/Lexer.hs(includesghcconfig.hwhich itself includesghcautoconf.h) -
libraries/bytestring/Data/ByteString/Builder/Prim/Binary.hs(includesMachDeps.hwhich itself includesghcautoconf.h) -
libraries/ghci/GHCi/ResolvedBCO.hs(includesMachDeps.hwhich itself includesghcautoconf.h) -
libraries/base/GHC/ByteOrder.hs(fixed in !2302 (closed)) -
libraries/base/GHC/IO/Encoding/CodePage/API.hs(fixed in !2302 (closed)) -
libraries/base/GHC/IO/Encoding/Iconv.hs(includesMachDeps.hwhich itself includesghcautoconf.h) -
testsuite/tests/primops/should_run/T4442.hs(includesMachDeps.hwhich itself includesghcautoconf.h) -
testsuite/tests/codeGen/should_run/T7600.hs(fixed in !2302 (closed)) -
testsuite/tests/codeGen/should_run/cgrun044.hs(includesghcconfig.hwhich itself includesghcautoconf.h)
Edited by Stefan Schulze Frielinghaus