繁体   English   中英

堆栈构建错误:构建 package aeson 时。 (阴谋集团)退出失败 1

[英]Stack build error: while building package aeson. (cabal) ExitFailure 1

当我运行“堆栈构建”时,出现错误:

--  While building package aeson-1.1.2.0 using:
      /Users/kaspazza/.stack/setup-exe-cache/x86_64-osx/Cabal-simple_mPHDZzAJ_1.24.2.0_ghc-8.0.2 --builddir=.stack-work/dist/x86_64-osx/Cabal-1.24.2.0 build --ghc-options ""
    Process exited with code: ExitFailure 1

我的堆栈.yaml:

resolver: lts-9.10

packages:
- '.'

extra-deps: []

flags: {}

extra-package-dbs: []

命令:stack exec - ghc 给出:

/Users/kaspazza/.stack/programs/x86_64-osx/ghc-8.0.2/bin/ghc

命令:ghc --version

The Glorious Glasgow Haskell Compilation System, version 8.8.3

命令:堆栈构建

aeson   > configure
aeson   > Configuring aeson-1.1.2.0...
aeson   > build    
aeson   > Building aeson-1.1.2.0...
aeson   > Preprocessing library aeson-1.1.2.0...
aeson   > [ 1 of 21] Compiling Data.Aeson.Types.Internal ( Data/Aeson/Types/Internal.hs, .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Data/Aeson/Types/Internal.o )
aeson   > [ 2 of 21] Compiling Data.Aeson.Types.Generic ( Data/Aeson/Types/Generic.hs, .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Data/Aeson/Types/Generic.o )
aeson   > [ 3 of 21] Compiling Data.Aeson.Parser.UnescapeFFI ( ffi/Data/Aeson/Parser/UnescapeFFI.hs, .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Data/Aeson/Parser/UnescapeFFI.o )
aeson   > [ 4 of 21] Compiling Data.Aeson.Parser.Unescape ( Data/Aeson/Parser/Unescape.hs, .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Data/Aeson/Parser/Unescape.o )
aeson   > [ 5 of 21] Compiling Data.Aeson.Parser.Internal ( Data/Aeson/Parser/Internal.hs, .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Data/Aeson/Parser/Internal.o )
aeson   > <command line>: can't load .so/.DLL for: /Users/kaspazza/.stack/snapshots/x86_64-osx/8b5cff025076e7bab89d6dbb5e562716cf2b67bbcde1528460c4f36feefa23fb/8.0.2/lib/x86_64-osx-ghc-8.0.2/libHStime-locale-compat-0.1.1.3-KZ1jqNx8uhlHjmuPPj6V1Y-ghc8.0.2.dylib (dlopen(/Users/kaspazza/.stack/snapshots/x86_64-osx/8b5cff025076e7bab89d6dbb5e562716cf2b67bbcde1528460c4f36feefa23fb/8.0.2/lib/x86_64-osx-ghc-8.0.2/libHStime-locale-compat-0.1.1.3-KZ1jqNx8uhlHjmuPPj6V1Y-ghc8.0.2.dylib, 5): REBASE_OPCODE_SET_SEGMENT_AND_OFFSET_ULEB has segment 2 which is not a writable segment (__LINKEDIT) in /Users/kaspazza/.stack/snapshots/x86_64-osx/8b5cff025076e7bab89d6dbb5e562716cf2b67bbcde1528460c4f36feefa23fb/8.0.2/lib/x86_64-osx-ghc-8.0.2/libHStime-locale-compat-0.1.1.3-KZ1jqNx8uhlHjmuPPj6V1Y-ghc8.0.2.dylib)

--  While building package aeson-1.1.2.0 using:
      /Users/kaspazza/.stack/setup-exe-cache/x86_64-osx/Cabal-simple_mPHDZzAJ_1.24.2.0_ghc-8.0.2 --builddir=.stack-work/dist/x86_64-osx/Cabal-1.24.2.0 build --ghc-options ""
    Process exited with code: ExitFailure 1
Progress 1/2

命令: cabal 安装

cabal: Could not resolve dependencies:
[__0] trying: duckling-0.1.6.1 (user goal)
[__1] next goal: snap-server (dependency of duckling)
[__1] rejecting: snap-server-1.1.1.1 (conflict: duckling =>
snap-server>=1.0.1.1 && <1.1)
[__1] skipping: snap-server-1.1.1.0, snap-server-1.1.0.0 (has the same
characteristics that caused the previous version to fail: excluded by
constraint '>=1.0.1.1 && <1.1' from 'duckling')
[__1] trying: snap-server-1.0.3.3
[__2] next goal: base (dependency of duckling)
[__2] rejecting: base-4.13.0.0/installed-4.13.0.0 (conflict: snap-server =>
base>=4 && <4.11)
[__2] skipping: base-4.14.0.0, base-4.13.0.0, base-4.12.0.0, base-4.11.1.0,
base-4.11.0.0 (has the same characteristics that caused the previous version
to fail: excluded by constraint '>=4 && <4.11' from 'snap-server')
[__2] rejecting: base-4.10.1.0, base-4.10.0.0, base-4.9.1.0, base-4.9.0.0,
base-4.8.2.0, base-4.8.1.0, base-4.8.0.0, base-4.7.0.2, base-4.7.0.1,
base-4.7.0.0, base-4.6.0.1, base-4.6.0.0, base-4.5.1.0, base-4.5.0.0,
base-4.4.1.0, base-4.4.0.0, base-4.3.1.0, base-4.3.0.0, base-4.2.0.2,
base-4.2.0.1, base-4.2.0.0, base-4.1.0.0, base-4.0.0.0, base-3.0.3.2,
base-3.0.3.1 (constraint from non-upgradeable package requires installed
instance)
[__2] fail (backjumping, conflict set: base, duckling, snap-server)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: snap-server, duckling, base

(我在 Mac 上,我认为问题出在我机器上工具的版本/依赖项上)任何想法为什么我会收到错误,或者我该如何调试它?

从我的评论中复制

显然,这也是使用ghc-8.6.3构建的。 这样的 ghc 版本在堆栈的快照13.11中可用。 如果您愿意,可以更改stack.yaml以将解析器设置为 lts lts-13.11 它将下载不同版本的编译器和库。 也许它有效

从你的评论

正如您所说,您必须添加allow-newer: true以便它可以正确解决依赖关系

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM