这些是我得到的链接器错误:
happy-1.19.5: configure
cpphs-1.20.2: download
th-reify-many-0.1.6: download
time-qq-0.0.1.0: download
th-reify-many-0.1.6: configure
th-reify-many-0.1.6: build
time-qq-0.0.1.0: configure
time-qq-0.0.1.0: build
cpphs-1.20.2: configure
th-reify-many-0.1.6: copy/register
time-qq-0.0.1.0: copy/register
cpphs-1.20.2: build
cpphs-1.20.2: copy/register
Progress: 4/9
-- While building package happy-1.19.5 using:
/usr/local/bin/ghc --make -odir /tmp/stack1466/happy-1.19.5/.stack-work/dist/x86_64-freebsd/Cabal-1.22.4.0/setup -hidir /tmp/stack1466/happy-1.19.5/.stack-work/dist/x86_64-freebsd/Cabal-1.22.4.0/setup
-i -i. -package=Cabal-1.22.4.0 -clear-package-db -global-package-db -package-db=/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/pkgdb /tmp/stack1466/happy-1.19.5/Setup.lhs -o /tmp/stack1466/happy-1.1
9.5/.stack-work/dist/x86_64-freebsd/Cabal-1.22.4.0/setup/setup
Process exited with code: ExitFailure 1
Logs have been written to: /root/project-name/.stack-work/logs/happy-1.19.5.log
[1 of 1] Compiling Main ( /tmp/stack1466/happy-1.19.5/Setup.lhs, /tmp/stack1466/happy-1.19.5/.stack-work/dist/x86_64-freebsd/Cabal-1.22.4.0/setup/Main.o )
/tmp/stack1466/happy-1.19.5/Setup.lhs:20:1: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:21:1: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:22:1: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:68:1: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:74:1: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:81:19: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:82:23: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:83:26: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:84:26: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:85:30: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:86:33: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:87:32: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:88:36: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:89:39: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:94:14: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:99:13: Warning: Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:100:17: Warning:
Tab character
/tmp/stack1466/happy-1.19.5/Setup.lhs:101:23: Warning:
Tab character
Linking /tmp/stack1466/happy-1.19.5/.stack-work/dist/x86_64-freebsd/Cabal-1.22.4.0/setup/setup ...
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_rtldNext':
HsUnix.c:(.text+0x80): multiple definition of `__hsunix_rtldNext'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x0): first defined here
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_rtldDefault':
HsUnix.c:(.text+0x90): multiple definition of `__hsunix_rtldDefault'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x10): first defined here
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_ptsname':
HsUnix.c:(.text+0x130): multiple definition of `__hsunix_ptsname'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x20): first defined here
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_grantpt':
HsUnix.c:(.text+0x140): multiple definition of `__hsunix_grantpt'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x30): first defined here
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_unlockpt':
HsUnix.c:(.text+0x150): multiple definition of `__hsunix_unlockpt'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x40): first defined here
/usr/local/lib/ghc-7.10.2/unix_A3WgcI5QiHK4PDo4jSYdwQ/libHSunix-2.7.1.0-A3WgcI5QiHK4PDo4jSYdwQ.a(HsUnix.o): In function `__hsunix_push_module':
HsUnix.c:(.text+0x160): multiple definition of `__hsunix_push_module'
/root/.stack/snapshots/x86_64-freebsd/lts-7.14/7.10.2/lib/x86_64-freebsd-ghc-7.10.2/unix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS/libHSunix-2.7.2.0-3psvMyG1UoBJLXj9bF7fFS.a(HsUnix.o):(.text+0x50): first defined here
collect2: error: ld returned 1 exit status
杂项
- ghc-7.10.2
- 虚拟机中的 FreeBSD 10.3-RELEASE-p18
- 快乐-1.19.5
- 堆栈版本 1.0.1,Git 修订版 e1c8e2c(3065 次提交)x86_64
我正在考虑的选项:
弄清楚链接器错误是关于什么的。也许它很容易修复。也许在 StackOverflow 上询问一下。;) 有什么想法吗?
尝试找出我的项目的哪个依赖项正在使用 Happy,看看我是否可以不用它。我试图通过这个来解决这个问题
stack list-dependencies --depth=100
,stack dot --external
但不幸的是,这些都没有帮助我。
我怎样才能找出我的哪些直接依赖项依赖它(可能是间接依赖)?尝试说服
stack
使用happy
我能够通过pkg install hs-happy
. 我该怎么办?从 linux 交叉编译 FreeBSD。如果我有一个交叉编译器,我是否正确地怀疑这可能不是问题?无论哪种方式,设置 linux->FreeBSD 交叉编译器会很困难吗?我怎么能这样做呢?
尝试摆脱对 FreeBSD 的需求。不幸的是,我的托管服务提供商目前只支持 FreeBSD,而我真的很喜欢它们还有其他原因(物有所值及其相关理念)。也许,如果一切都失败了,你能告诉我你的 Haskell 项目最喜欢哪个 Linux 托管服务提供商吗?
我怀疑选项#1 或#3 可能是最轻松的。
或者你们还有其他想法吗?