any idea why cabal install cabal-install cant update itself in windows?

C:\Documents and Settings\anatolyy>cabal install cabal-install Resolving dependencies... 'cabal-install-0.6.0' is cached. Configuring cabal-install-0.6.0... Preprocessing executables for cabal-install-0.6.0... Building cabal-install-0.6.0... ... Linking dist\build\cabal\cabal.exe ... Installing: C:\Documents and Settings\anatolyy\Application Data\cabal\bin C:\Documents and Settings\anatolyy>cabal --version cabal-install version 0.5.2 using version 1.4.0.2 of the Cabal library

Windows will not let you modify/delete binaries if they're running as a process, and it won't let you delete .DLL files that're in use by applications either (mapped to shared memory, that is.) So cabal install cannot overwrite the cabal.exe binary after it builds it, because it's already running. I'm not sure anybody's found an adequate solution yet (Duncan?) - .bat files maybe? Austin

On Wed, Oct 22, 2008 at 8:48 PM, Austin Seipp
Windows will not let you modify/delete binaries if they're running as a process, and it won't let you delete .DLL files that're in use by applications either (mapped to shared memory, that is.) So cabal install cannot overwrite the cabal.exe binary after it builds it, because it's already running.
looks like i just needed to fix my paths. I had the default ghc bin directory before the directory where cabal installs its binaries. But after i fixed that, i ran into the windows problem, which i fixed by just copying the binary to a temporary location.

On Wed, 2008-10-22 at 22:48 -0500, Austin Seipp wrote:
Windows will not let you modify/delete binaries if they're running as a process, and it won't let you delete .DLL files that're in use by applications either (mapped to shared memory, that is.) So cabal install cannot overwrite the cabal.exe binary after it builds it, because it's already running.
I'm not sure anybody's found an adequate solution yet (Duncan?) - .bat files maybe?
Indeed it is a nasty problem. I solved it in cabal-install-0.5.2 using cunning trickery. For details see: http://hackage.haskell.org/trac/hackage/ticket/291 Duncan

On Wed, 2008-10-22 at 19:56 -0700, Anatoly Yakovenko wrote:
C:\Documents and Settings\anatolyy>cabal install cabal-install Resolving dependencies... 'cabal-install-0.6.0' is cached. Configuring cabal-install-0.6.0... Preprocessing executables for cabal-install-0.6.0... Building cabal-install-0.6.0... ... Linking dist\build\cabal\cabal.exe ... Installing: C:\Documents and Settings\anatolyy\Application Data\cabal\bin
C:\Documents and Settings\anatolyy>cabal --version cabal-install version 0.5.2 using version 1.4.0.2 of the Cabal library
Right, the problem as you discovered is exe search paths. This is because deciding where we should install exes by default seems to be a controversial issue. So we have not made a good decision yet. http://hackage.haskell.org/trac/hackage/ticket/289 The current state is well known to be sub-optimal (installing by default into a dir that is not on the path by default) but trying to get agreement on the "Right Thing"tm is tricky. This is currently one of the most frequent issues tripping people up so we'll try and come up with a reasonable compromise. Duncan
participants (3)
-
Anatoly Yakovenko
-
Austin Seipp
-
Duncan Coutts