Skip to content

make bindist packages the wrong binaries for cross compilers

When building binary distributions via make binary-dist, the resulting binaries in the package end up being compiled for the target instead of the host when cross compiling.

E.g. building a cross compiler for iOS on macOS yields:

./inplace/bin/ghc-cabal:                            Mach-O 64-bit executable x86_64
./utils/ghc-cabal/dist/build/tmp/ghc-cabal:         Mach-O 64-bit executable x86_64
./utils/ghc-cabal/dist-install/build/tmp/ghc-cabal: Mach-O 64-bit executable arm64
./inplace/lib/bin/hsc2hs:                     Mach-O 64-bit executable x86_64
./utils/hsc2hs/dist/build/tmp/hsc2hs:         Mach-O 64-bit executable x86_64
./utils/hsc2hs/dist-install/build/tmp/hsc2hs: Mach-O 64-bit executable arm64

to just name ghc-cabal and hsc2hs.

Trac metadata
Trac field Value
Version 8.2.1
Type Bug
TypeOfFailure OtherFailure
Priority high
Resolution Unresolved
Component Package system
Test case
Differential revisions
BlockedBy
Related
Blocking
CC bgamari
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information