I am starting a project. my cabal file specifies
build-depends: base <4.8, criterion >=1.0 && <1.1, memoize <=0.6
criterion is in the sandbox of current directory. If I check with ghc-pkg list memoize
it will show.
C:/Program Files/Haskell Platform/2014.2.0.0\lib\package.conf.d: (no packages)
C:\Users\Song\AppData\Roaming\ghc\x86_64-mingw32-7.8.3\package.conf.d: memoize-0.6
memoize is globally available.
However, when I run cabal repl, cabal complains memoize is missing. Do I have to re-install the package in the sandbox in this case?
Yes, you do. The purpose of sandboxes is to work independently of the user package database, not in addition to it. You can override this by adding back the user package database with the --package-db
flag, but it isn't a recommended workflow.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.