Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 806965

Summary: dev-lang/ghc-8.10.4-r1: Unable to bootstrap using musl
Product: Gentoo Linux Reporter: Leonardo Neumann <leonardo>
Component: Current packagesAssignee: Gentoo's Haskell Language team <haskell>
Status: UNCONFIRMED ---    
Severity: normal CC: musl
Priority: Normal    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: ghc musl emerge --info
ghc musl build.log

Description Leonardo Neumann 2021-08-07 12:00:10 UTC
GHC can't bootstrap on a musl-based system probably because the provided binaries used to bootstrap are not compatible.

Reproducible: Always

Steps to Reproduce:
1. emerge -1 =dev-lang/ghc-8.10.4-r1
Actual Results:  
 * Relocating 'lib64' to 'lib' (bug #476998)
/tmp/portage/dev-lang/ghc-8.10.4-r1/temp/ghc-pkg-8.10.4-orig: line 11: /tmp/portage/dev-lang/ghc-8.10.4-r1/work/usr/lib/ghc-8.10.4/bin/ghc-pkg: No such file or directory

(although the file exists in the workdir)
Comment 1 Tom Gillespie 2022-08-19 22:46:34 UTC
I see this behavior as well on 9.0.2-r1. It seems strange that the mv command would fail because there was something wrong with the haskell binaries?
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-08-19 22:51:33 UTC
Pleasse include the full build.log & emerge --info for completneess. It's helpful in particular if debugging from a non-musl system.
Comment 3 Tom Gillespie 2022-08-23 20:47:45 UTC
Created attachment 800671 [details]
ghc musl emerge --info
Comment 4 Tom Gillespie 2022-08-23 20:48:39 UTC
Created attachment 800673 [details]
ghc musl build.log
Comment 5 Siva Mahadevan 2023-10-01 20:31:56 UTC
I'm running into this on a musl+clang system profile trying to emerge ghc-9.0.2 with default USE flags. The same thing happens even when following the post-fail message instructions to USE=ghcbootstrap.

What's the correct way to bootstrap ghc on a musl+clang profile?