[Haskell-cafe] Windows 7 Permission Denied Problem on Cabal

Ralph Hodgson rhodgson at topquadrant.com
Mon May 17 18:37:06 EDT 2010


Thanks for your help - that worked beautifully.

 

From: Phyx [mailto:lonetiger at gmail.com] 
Sent: Monday, May 17, 2010 1:38 AM
To: rhodgson at topquadrant.com; haskell-cafe at haskell.org
Subject: RE: [Haskell-cafe] Windows 7 Permission Denied Problem on Cabal

 

Right, the problem is that under windows 7 and vista the Program Files
folder if not "yours" as in you don't have direct permission to write there
without elevation. 

You could go to the Haskell folder, and grand your current user full rights,
but any new tools installed will inherit the original and not modified
permission (I believe).

 

The other approach I like much better is instead of doing global installs,
do user installs. In fact, I made it my default. Which solves any permission
error, but means every user on that machine has to install the libs
separately which shouldn't be a problem if you're the only one.

 

To do this go to C:\Users\<username>\AppData\Roaming\cabal\ and open the
file "config" in a text editor and inside that, uncomment the bit that says
"user-install: True"

 

That should do it.

 

From: haskell-cafe-bounces at haskell.org
[mailto:haskell-cafe-bounces at haskell.org] On Behalf Of Ralph Hodgson
Sent: Monday, May 17, 2010 09:51
To: haskell-cafe at haskell.org
Subject: RE: [Haskell-cafe] Windows 7 Permission Denied Problem on Cabal

 

Providing more evidence of the issue by running cabal with -v flag:

 

...

...

Linking...

C:\Program Files (x86)\Haskell Platform\2009.2.0.2\bin\ar.exe -r
dist\build\libHSCabal-1.8.0.4.a dist\build\Distribution\Compiler.o
dist\build\Distribution\InstalledPackageInfo.o 

...

...

...

Registering Cabal-1.8.0.4...

C:\Program Files (x86)\Haskell Platform\2009.2.0.2\bin\ghc-pkg.exe update -
--global --no-user-package-conf --package-conf=dist\package.conf.inplace

Creating
C:\Users\Ralph\AppData\Local\Temp\Cabal-1.8.0.411920\Cabal-1.8.0.4\dist\setu
p(and its parents)

C:\Users\Ralph\AppData\Local\Temp\Cabal-1.8.0.411920\Cabal-1.8.0.4\dist\setu
p\setup.exe install --verbose=2

directory dist\doc\html\Cabal does exist: False

Creating C:\Program Files (x86)\Haskell\doc\Cabal-1.8.0.4 (and its parents)

setup.exe: permission denied

cabal: Error: some packages failed to install:

Cabal-1.8.0.4 failed during the final install step. The exception was:

exit: ExitFailure 1

cabal-install-0.8.2 depends on Cabal-1.8.0.4 which failed to install.

 

C:\Users\Ralph>

 

From: haskell-cafe-bounces at haskell.org
[mailto:haskell-cafe-bounces at haskell.org] On Behalf Of Ralph Hodgson
Sent: Monday, May 17, 2010 12:18 AM
To: haskell-cafe at haskell.org
Subject: [Haskell-cafe] Windows 7 Permission Denied Problem on Cabal

 

Following a successful install of the Haskell Platform on MAC OSX,  I
proceed to update my Windows PC. 

 

Frustration followed. I am blocked by a "Permission Denied" error when I do
a "Setup install":

 

>ghc --make Setup

[58 of 58] Compiling Main             ( Setup.hs, Setup.o )

Linking Setup.exe ...

 

>Setup configure

Configuring Cabal-1.8.0.4...

 

>Setup build

Preprocessing library Cabal-1.8.0.4...

Building Cabal-1.8.0.4...

Registering Cabal-1.8.0.4...

 

>Setup install

Setup: permission denied

 

> 

 

I changed the permission on folders in the "Haskell Platform" directories to
"full control", without any effect.

 

I have searched the web for help but  could not find my problem. Can't help
but think it is something trivial but what?

 

Help appreciated.

 

Ralph Hodgson, @ralphtq <http://twitter.com/ralphtq> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20100517/d9fb130b/attachment.html


More information about the Haskell-Cafe mailing list