Better error for unbuildable package
monoidal opened this issue · comments
Krzysztof Gogolewski commented
At the moment, an unbuildable text depends on base < 0
:
-- Certain version of GHC crash on Windows, when TemplateHaskell encounters C++.
-- https://gitlab.haskell.org/ghc/ghc/-/issues/19417
if flag(simdutf) && os(windows) && impl(ghc == 8.0.1 || >= 8.8 && < 8.10.5 || == 9.0.1)
build-depends: base < 0
-- For GHC 8.2, 8.6.3 and 8.10.1 even TH + C crash Windows linker.
if os(windows) && impl(ghc >= 8.2 && < 8.4 || == 8.6.3 || == 8.10.1)
build-depends: base < 0
-- GHC 8.10 has linking issues (probably TH-related) on ARM.
if (arch(aarch64) || arch(arm)) && impl(ghc == 8.10.*)
build-depends: base < 0
-- Subword primitives in GHC 9.2.1 are broken on ARM platforms.
if (arch(aarch64) || arch(arm)) && impl(ghc == 9.2.1)
build-depends: base < 0
The error message gives no indication what is the problem. It is really confusing, e.g. https://gitlab.haskell.org/ghc/ghc/-/issues/22205.
Is it possible to have better UX? If we have to use the hack, perhaps the name of the dependency could be a clue/keyword for the user to search?
ˌbodʲɪˈɡrʲim commented
M1 owners should not use 9.2.1 under any circumstances, much less to compile text-2
. Given the only affected user has already upgraded, I see little incentive to complicate this setup with fake packages.