I have Windows XP and Haskell Platform 2013 installed on it. When I want to compile my code on some computer on which the Haskell platform is not installed on it and I am not allowed to install anything, I can copy my Haskell platform to flash USB card and run it on this computer, and it works just fine.
But sometimes I need additional packages that are not part of the standard Haskell platform build.
I can simply install it on my personal computer using Cabal, but I don’t know how to install them in such a way that they can work portable, i.e. e. from my USB card to not my computer.
I tried this:
cabal install gnuplot --prefix "C:\Program Files\Haskell Platform\2013.2.0.0"
This installed package is in the Haskell platform directory, but when I run the Haskell Platform on another computer, it does not see it.
I think I should make a configuration file that will be installed in the Haskell platform directory, but I do not.
Please help me solve this problem. Thank you in advance!
Thank you very much, Mikhail Glushenkov! Everything is working fine now.
For the convenience of beginners, such as myself, who are looking for answers, I just describe the instructions on what to do in order to have the same result:
0) Read the instructions before doing anything /
1) Remove any additional packages that need to be installed portable (with dependencies): unregister these packages with
ghc-pkg unregister gnuplot
, . pack.conf.d. ,
ghc-pkg list
.
2) (, )
ghc-pkg recache
.
3) haskell. "C:\Program
\Haskell Platform\2013.2.0.0\addlib ":
cabal install gnuplot --prefix "C:\Program Files\Haskell Platform\2013.2.0.0\addlib" --global
.
4) , "package.conf.d": "C:\Program Files\Haskell Platform\2013.2.0.0\addlib\utility-ht-0.0.9\ghc- 7.6.3" : "$topdir \..\addlib\utility-ht-0.0.9\ghc-7.6.3", i. . "C:\Program Files\Haskell Platform\2013.2.0.0\addlib \" → "$ topdir \..\addlib \".
5)
ghc-pkg recache
.
3a) , , 3 ( ). , 3, 4 5.
cabal install gnuplot --prefix "$topdir\..\addlib" --global
.
End.
* UPD *
( 3 4). .
3a !