Opened 11 months ago

Closed 10 months ago

Last modified 8 months ago

#68957 closed defect (fixed)

Cabal fails to build from source on MacOS 10.15: Failed to build Cabal-syntax-3.10.2.0

Reported by: Gandoon (Erik Hedlund) Owned by: essandess (Steve Smith)
Priority: Normal Milestone:
Component: ports Version: 2.8.1
Keywords: Cc:
Port: cabal

Description

The cabal port fails to build the upgrade to @3.10.2.0_0 from @3.10.1.0_0 that built successfully 15/3 2023. System in question is MacOS 10.15.7 and it fails with complaints regarding:

Failed to build ed25519-0.0.5.0.
Build log (
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_cabal/cabal/work/.home/.cabal/logs/ghc-9.6.3/d25519-0.0.5.0-6c355779.log
):
Configuring library for ed25519-0.0.5.0..
Preprocessing library for ed25519-0.0.5.0..
Building library for ed25519-0.0.5.0..
[1 of 1] Compiling Crypto.Sign.Ed25519 ( src/Crypto/Sign/Ed25519.hs, dist/build/Crypto/Sign/Ed25519.o, dist/build/Crypto/Sign/Ed25519.dyn_o )

<no location info>: error:
    Failed to load interface for ‘Language.Haskell.TH.Syntax’
There are files missing in the ‘template-haskell’ package,
try running 'ghc-pkg check'.
Use -v (or `:set -v` in ghci) to see a list of the files searched for.

Failed to build safe-exceptions-0.1.7.4.
Build log (
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_cabal/cabal/work/.home/.cabal/logs/ghc-9.6.3/sf-xcptns-0.1.7.4-3c00444b.log
):
Configuring library for safe-exceptions-0.1.7.4..
Preprocessing library for safe-exceptions-0.1.7.4..
Building library for safe-exceptions-0.1.7.4..
[1 of 1] Compiling Control.Exception.Safe ( src/Control/Exception/Safe.hs, dist/build/Control/Exception/Safe.o, dist/build/Control/Exception/Safe.dyn_o )

<no location info>: error:
    Failed to load interface for ‘Language.Haskell.TH.Syntax’
There are files missing in the ‘template-haskell’ package,
try running 'ghc-pkg check'.
Use -v (or `:set -v` in ghci) to see a list of the files searched for.
Error: cabal-prebuilt: Failed to build Cabal-syntax-3.10.2.0 (which is
required by exe:cabal from cabal-install-3.10.2.0).
Failed to build documentation for base64-bytestring-1.2.1.0 (which is required
by exe:cabal from cabal-install-3.10.2.0).
Failed to build documentation for cryptohash-sha256-0.11.102.1 (which is
required by exe:cabal from cabal-install-3.10.2.0).
Failed to build ed25519-0.0.5.0 (which is required by exe:cabal from
cabal-install-3.10.2.0). See the build log above for details.
Failed to build documentation for hashable-1.4.3.0 (which is required by
exe:cabal from cabal-install-3.10.2.0).
Failed to build documentation for regex-base-0.94.0.2 (which is required by
exe:cabal from cabal-install-3.10.2.0).
Failed to build safe-exceptions-0.1.7.4 (which is required by exe:cabal from
cabal-install-3.10.2.0). See the build log above for details.

I am currently unsure how to proceed. It may come down to a missing dependency, but at this time I have yet to figure out if that is the case and if the problem can be easily solved by installing any additional ports. Nevertheless, if it indeed is a simple missing dependency it is still worth the effort to start a ticket for now so it can be fixed.

Attachments (1)

cabal-main.log (30.2 KB) - added by Gandoon (Erik Hedlund) 11 months ago.
Log from failed build on MacOS 10.15

Download all attachments as: .zip

Change History (8)

Changed 11 months ago by Gandoon (Erik Hedlund)

Attachment: cabal-main.log added

Log from failed build on MacOS 10.15

comment:1 Changed 11 months ago by kencu (Ken)

probably need to see what happened in here:

/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_cabal/cabal/work/.home/.cabal/logs/ghc-9.6.3/d25519-0.0.5.0-6c355779.log

comment:2 Changed 11 months ago by ryandesign (Ryan Carsten Schmidt)

Owner: set to essandess
Status: newassigned

comment:3 in reply to:  1 Changed 11 months ago by Gandoon (Erik Hedlund)

Replying to kencu:

probably need to see what happened in here:

/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_cabal/cabal/work/.home/.cabal/logs/ghc-9.6.3/d25519-0.0.5.0-6c355779.log

What happens there is just the following:

Configuring library for ed25519-0.0.5.0..
Preprocessing library for ed25519-0.0.5.0..
Building library for ed25519-0.0.5.0..
[1 of 1] Compiling Crypto.Sign.Ed25519 ( src/Crypto/Sign/Ed25519.hs, dist/build/Crypto/Sign/Ed25519.o, dist/build/Crypto/Sign/Ed25519.dyn_o )

<no location info>: error:
    Failed to load interface for ‘Language.Haskell.TH.Syntax’
There are files missing in the ‘template-haskell’ package,
try running 'ghc-pkg check'.
Use -v (or `:set -v` in ghci) to see a list of the files searched for.

And it is not quite clear to me what I can or should do about it.

comment:4 Changed 11 months ago by kencu (Ken)

there was a recent fix added to cabal

https://github.com/macports/macports-ports/commit/618718b52c8912637a8e5d719bd25d6d3a4ba816

have you updated your ports tree to pick that up?

comment:5 in reply to:  4 ; Changed 10 months ago by Gandoon (Erik Hedlund)

Replying to kencu:

there was a recent fix added to cabal

https://github.com/macports/macports-ports/commit/618718b52c8912637a8e5d719bd25d6d3a4ba816

have you updated your ports tree to pick that up?

Hi and happy new year!

I just ran a clean --all and rebuilt, and this time it didn't fail. Thank you for the heads up.

This ticket can thus probably be closed now.

comment:6 in reply to:  5 Changed 10 months ago by mascguy (Christopher Nielsen)

Resolution: fixed
Status: assignedclosed

Replying to Gandoon:

I just ran a clean --all and rebuilt, and this time it didn't fail. Thank you for the heads up.

This ticket can thus probably be closed now.

Great, glad the issue is resolved!

comment:7 Changed 8 months ago by kencu (Ken)

Summary: Cabal fails to build on MacOS 10.15Cabal fails to build from source on MacOS 10.15: Failed to build Cabal-syntax-3.10.2.0
Note: See TracTickets for help on using tickets.