Open tillydray opened 5 years ago
Can this still be reproduced? I recently also changed the regex library in the epub-metadata dep from regex-compat-tdfa
to regex-compat
, wonder if that may affect this.
UPDATE1: added epub-metadata
to all build-depends:
and am running stack build
again because I'm not sure which one(s) it properly belongs in 🤞🏼
UPDATE2: that didn't work
Can this still be reproduced?
@dino- I just cloned fresh, and am on stack Version 2.11.1 aarch64. Here's what I get
$ stack build
Preparing to install GHC to an isolated location. This will not interfere with any system-level installation.
Downloaded ghc-9.2.6.
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
Installed GHC.
No information from Hackage index, updating
Selected mirror https://hackage.haskell.org/
Downloading root
Waiting to acquire cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Acquired cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Released cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Selected mirror https://hackage.haskell.org/
Downloading timestamp
Downloading snapshot
Downloading mirrors
Cannot update index (no local copy)
Downloading index
Waiting to acquire cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Acquired cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Released cache lock on /Users/jason/.stack/pantry/hackage/hackage-security-lock
Updated package index downloaded
Calculating hashes to check for hackage-security rebases or filesystem changes
No old cache found, populating cache from scratch
Populating cache from file size 858081792, hash a768945ca7f6a540ccc8d683dbf6130df407bfe89d93089f07d3aa0a290a0e45
Populating package index cache ...
Package index cache populated
Error: [S-4804]
Stack failed to construct a build plan.
While constructing the build plan, Stack encountered the following errors:
In the dependencies for epub-tools-3.0:
epub-metadata must match >=5.0, but the Stack configuration has no specified version (no package with that name found, perhaps there is a typo in a package's build-depends or
an omission from the stack.yaml packages list?)
needed since epub-tools is a build target.
Ah, sorry about that. Most of the changes I've been working on are in the epub-metadata
library that epub-tools
uses. They are breaking changes which is why the version was moved up in this repo's cabal file. I just pushed a new commit that temporarily makes this package build against an unreleased commit of epub-metadata
on Github instead of Stackage. Should work now.
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 9.4.4
$ stack --version
Version 2.11.1 aarch64
@dino-
I pulled and got the below error, so I did a fresh clone and still got this error.
Linking /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6 ...
ld64.lld: error: unknown argument '--gc-sections'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)
Error: [S-6374]
While building simple Setup.hs (scroll up to its section to see the error) using:
/Users/jason/.stack/programs/aarch64-osx/ghc-9.2.6/bin/ghc-9.2.6 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.6.3.0 /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs -o /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6
Process exited with code: ExitFailure 1
I ran stack build -v
but didn't see any helpful issues
2023-07-08 09:47:47.305431: [debug] Run process within /private/var/folders/pc/fmm1wp655gb7wmw5ph6lqh2m0000gn/T/stack-93d0012480fb2fca/: /Users/jason/.stack/programs/aarch64-osx/ghc-9.2.6/bin/ghc-9.2.6 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.6.3.0 /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs -o /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6
Linking /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6 ...
ld64.lld: error: unknown argument '--gc-sections'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)
2023-07-08 09:47:47.580108: [debug] Checking for project config at: /Users/jason/Projects/epub-tools/stack.yaml
2023-07-08 09:47:47.580189: [debug] Loading project config file stack.yaml
2023-07-08 09:47:47.582256: [debug] (SQL) SELECT COUNT(*) FROM "last_performed" WHERE ("action"=?) AND ("timestamp">=?); [PersistInt64 1,PersistUTCTime 2023-07-07 13:47:47.58223 UTC]
2023-07-08 09:47:47.582442: [error]
Error: [S-6374]
While building simple Setup.hs (scroll up to its section to see the error) using:
/Users/jason/.stack/programs/aarch64-osx/ghc-9.2.6/bin/ghc-9.2.6 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.6.3.0 /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs -o /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6
Process exited with code: ExitFailure 1
I did notice this warning so I did stack upgrade --force-download
but I was already on the latest.
Warning: this is an unsupported build that may use different versions of
dependencies and GHC than the officially released binaries, and therefore may
not behave identically. If you encounter problems, please try the latest
official build by running 'stack upgrade --force-download'.
So I did rm -rf ~/.stack
and ran stack build
again. Waiting on the output and will update this comment when it finishes.
UPDATE: got similar error output as before
stack build
Cloning fe8c268c081a9c0cc4de89ead9cd6b9bda99908f from https://github.com/dino-/epub-metadata.git
Preparing to install GHC to an isolated location. This will not interfere with any system-level installation.
Downloaded ghc-9.2.6.
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
Installed GHC.
[1 of 2] Compiling Main ( /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs, /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.o )
[2 of 2] Compiling StackSetupShim ( /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs, /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.o )
Linking /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6 ...
ld64.lld: error: unknown argument '--gc-sections'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)
Error: [S-6374]
While building simple Setup.hs (scroll up to its section to see the error) using:
/Users/jason/.stack/programs/aarch64-osx/ghc-9.2.6/bin/ghc-9.2.6 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.6.3.0 /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs -o /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6
Process exited with code: ExitFailure 1
The xcode-select error xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance
is odd because
$ which xcode-select
/usr/bin/xcode-select
$ which xcodebuild
/usr/bin/xcodebuild
I'm still having build problems myself to be honest, even on Linux. Working on it, will work more tomorrow. The true solution is that I need to release the epub-metadata v5.0 library properly. Not sure how to interpret the xcode errors though.
Not sure how to interpret the xcode errors though.
Figured it out. I assumed it meant that those tools couldn't be found, but actually it's a setting that needs to be updated in my case. But after doing sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
, stack build
still gives the same error as before
$ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
$ stack build
Linking /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6 ...
ld64.lld: error: unknown argument '--gc-sections'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)
Error: [S-6374]
While building simple Setup.hs (scroll up to its section to see the
error) using:
/Users/jason/.stack/programs/aarch64-osx/ghc-9.2.6/bin/ghc-9.2.6 -rtsopts -threaded -clear-package-db -global-package-db -hide-all-packages -package base -main-is StackSetupShim.mainOverride -package Cabal-3.6.3.0 /Users/jason/.stack/setup-exe-src/setup-6HauvNHV.hs /Users/jason/.stack/setup-exe-src/setup-shim-6HauvNHV.hs -o /Users/jason/.stack/setup-exe-cache/aarch64-osx/tmp-Cabal-simple_6HauvNHV_3.6.3.0_ghc-9.2.6
Process exited with code: ExitFailure 1
Just wanted to poke this discussion and say I made some updates and release a new 3.2 version.
When running the tests from a fresh clone and build, I get