3

I installed a fresh copy of Ubuntu 12 desktop then:

  1. Installed WINE from the Ubuntu Software Center.
  2. Installed WineTricks from the Ubuntu Software Center.

When I type the following commands in the terminal:

sudo winetricks dotnet40

I get this error message:

wine cmd.exe /c echo '%ProgramFiles%' returned empty string

If i try the command without sudo

winetricks dotnet40

The output is as follows

Executing w_do_call dotnet40
Executing load_dotnet40
------------------------------------------------------
dotnet40 does not yet fully work or install on wine.  Caveat emptor.
------------------------------------------------------
Executing mkdir -p /home/vectoruser/.cache/winetricks/dotnet40
mkdir: cannot create directory `/home/vectoruser/.cache/winetricks/dotnet40': Permission denied
------------------------------------------------------
Note: command 'mkdir -p /home/vectoruser/.cache/winetricks/dotnet40' returned status 1.  Aborting.
------------------------------------------------------

My current user is vectoruser which i use to logon to Ubuntu

The output of

ls -ld /home/vectoruser /home/vectoruser/.cache /home/vectoruser/.cache/winetricks

Gives:

drwxr-xr-x 32 vectoruser vectoruser 4096 Aug  2 19:26 /home/vectoruser
drwx------ 19 vectoruser vectoruser 4096 Aug  2 19:25 /home/vectoruser/.cache
drwxr-xr-x  2 root       root       4096 Aug  2 18:09 /home/vectoruser/.cache/winetricks
5
  • My final aim is to get the Abyss free ASP.NET web server running on Ubuntu using WINE and WINE TRICKS for Ubuntu 12. So i can host my work on Ubuntu while coding normally in visual studio. This will make my life easier as i am a newbie to Ubuntu but very enthusiastic about it Aug 2, 2012 at 17:34
  • winetricks dotnet40 without sudo -- Executing w_do_call dotnet40 Executing load_dotnet40 ------------------------------------------------------ dotnet40 does not yet fully work or install on wine. Caveat emptor. ------------------------------------------------------ Executing mkdir -p /home/vectoruser/.cache/winetricks/dotnet40 mkdir: cannot create directory `/home/vectoruser/.cache/winetricks/dotnet40': Permission denied ------------------------------------------------------ Note: command 'mkdir -p /home/vectoruser/.cache/winetricks/dotnet40' returned status 1. Aborting. Aug 2, 2012 at 17:37
  • ls -ld /home/vectoruser drwxr-xr-x 32 vectoruser vectoruser 4096 Aug 2 19:26 /home/vectoruser Aug 2, 2012 at 17:48
  • Sorry Eliah is it ls -ld or ls -al because ls -ld only returns a one line in the terminal? Aug 2, 2012 at 17:59
  • You only typed the beginning of the command, which is why you only get one line. Enter the whole command, and you should get three lines (though some may be errors): ls -ld /home/vectoruser /home/vectoruser/.cache /home/vectoruser/.cache/winetricks Also, please put the output (and the output of winetricks dotnet40 without sudo from above) in your question. Please also tell whether or not the user vectoruser is you (or that you don't know). Aug 2, 2012 at 18:01

3 Answers 3

2

This is a permissions problem as a result of having previously run Winetricks as root (with sudo). Winetricks was never intended to be run as root.

You can see from ls -ld that the Winetricks cache folder is owned by root:

drwxr-xr-x  2 root       root       4096 Aug  2 18:09 /home/vectoruser/.cache/winetricks

To fix this, you can run this command in a terminal to restore ownership to yourself:

sudo chown -R $USER:$USER "$HOME/.cache"
1

It seems the Ubuntu software center installs an older version of wine so what i did was

  1. installed the synaptic package manager from ubuntu software center
  2. removed anything and everything that had to do with wine including winetricks , gecho , qt4wine etc. basically any package that had wine in it
  3. i followed the instructions from this link, which is to add the wine repository to always get the latest version instructions to add wine repository and install it

  4. After installing and when i clicked the wine configuration item it displayed a dialog to install the mono runtime and other things , i accepted the installation

  5. i tried to run a .NET EXE file and it ran ok.

so next time i will always find the official repository for the apps and add them.

p.s. the Ubuntu software center is a good start but it always needs to be updated and consistent so newbies like me dont get a hard time trying to move to this wonderful O.S.

1
  • This might be good advice, or might have been good advice at the time, but it's at least dependent on what version of ubuntu you are running, how old that is now, and how recently wine has been updaated. So it would be helpful if it was clarified what version of ubuntu this refers to. (yes, I know this comment is long after the fact)
    – mc0e
    May 11, 2014 at 9:22
-2

Open a terminal using Ctrl+Alt+t and then type:

sudo -i

and then type your password and then:

initiate winetricks

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .