如何配置cabal以使用32位和64位软件包的不同文件夹? [英] How can I configure cabal to use different folders for 32-bit and 64-bit packages?
问题描述
我正在对Windows上的64位GHC进行一些测试,并将代码迁移到GHC 7.6.1。这意味着我已经安装了GHC 7.6.1的32位和64位版本,所以我可以区分64位特定问题与7.6.1中的一般问题。
我的cabal配置文件( $ APPDATA / cabal / config
)包含
libsubdir:$ pkgid \ $ compiler
这意味着32位和64位我安装的软件包版本以例如zip-archive-0.1.1.8 / ghc-7.6.1,并相互覆盖。
是否有像 $编译器
但区分32位和64位,或者我可以使用其他技术来使它们保持分开?
您可以使用 $ arch
(和/或 $ os
)和最近足够的Cabal版本,它将被一个字符串替换,如 x86_64
(请参阅Cabal文档部分简单构建系统中的路径变量以获取更多详细信息)
I'm doing some testing of 64-bit GHC on Windows, in tandem with migrating code forward to GHC 7.6.1. This means that I have both the 32-bit and 64-bit versions of GHC 7.6.1 installed, so I can distinguish 64-bit specific problems from general problems with 7.6.1.
My cabal config file ($APPDATA/cabal/config
) contains
libsubdir: $pkgid\$compiler
which means that both 32-bit and 64-bit versions of packages I install are ending up in e.g. zip-archive-0.1.1.8/ghc-7.6.1, and overwriting each other.
Is there any variable like $compiler
but distinguishing 32 and 64 bit, or other technique I can use to get it to keep the packages apart?
You can use $arch
(and/or $os
) with recent enough Cabal versions, which will be replaced by a string such as x86_64
(see Cabal documentation section "Path variables in the simple build system" for more details)
这篇关于如何配置cabal以使用32位和64位软件包的不同文件夹?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!