答案 0 :(得分:0)
作为Dave Lee pointed out,可以像这样传递--c2hs-options
标志:
cabal ... --c2hs-options="-d trace"
我无法弄清楚如何通过添加.cabal
或stack.yaml
文件来实现这项工作,或者将其传递给命令,就像与stack build
一样,只需复制来自stack build
输出的命令,并使用附加标志手动运行它:
/Users/py/projects/jspahrsummers/Arbiter/bindings/haskell/.stack-work/dist/x86_64-osx/Cabal-1.24.0.0/setup/setup --builddir=.stack-work/dist/x86_64-osx/Cabal-1.24.0.0 build lib:arbiter --ghc-options " -ddump-hi -ddump-to-file" --c2hs-options="-d trace"