堆栈构建失败并显示 LLD 错误

Kas*_*ard 5 haskell lld haskell-stack

我试图建立一些哈斯克尔包stackhaskell-ide-enginehlint明确),但他们都失败了许多ld.lld错误信息,凡是涉及到R_X86_64_32S搬迁,例如:

ld.lld: error: can't create dynamic relocation R_X86_64_32S against symbol: stg_bh_upd_frame_info in readonly segment; recompile object files with -fPIC or pass '-Wl,-z,notext' to allow text relocations in the output
>>> defined in /home/kas/.stack/programs/x86_64-linux/ghc-tinfo6-8.6.5/lib/ghc-8.6.5/rts/libHSrts_thr.a(Updates.thr_o)
>>> referenced by /home/kas/.stack/setup-exe-src/setup-shim-mPHDZzAJ.o:(s6WS_info)
Run Code Online (Sandbox Code Playgroud)

我尝试配置stack为使用不同的链接器(使用ghc-options标志),但我无法让它工作,它总是使用lld.

有谁知道我如何更改stack的链接器,或以其他方式修复错误?

谢谢!