0

I am using 64-Bit Linux, and when I Try to open an exe file from command line by the command wine somefile.exe I get an error which says:

wine: invalid directory prefix32 in WINEPREFIX: not an absolute path

Now, I tried to Debug that. In my root/ directory, there is already a folder called prefix32/ which contains these files:

dosdevices  drive_c  system.reg  userdef.reg  user.reg

Moreover, I also went to my Wine Folder by root/.wine Which contains files

dosdevices  drive_c  system.reg  userdef.reg  user.reg  winetricks.log

I also checked nano cat /etc/environment but it is currently empty. Now, I am actually clueless about how to debug this.

Running echo $WINEPREFIX gives me prefix32.

  • Run echo $WINEPREFIX and edit your question with the output. – Thomas Ward Feb 24 '16 at 13:06
  • Edited @ThomasW. – Yada Rahal Feb 24 '16 at 13:13
  • and I've provided an answer :) – Thomas Ward Feb 24 '16 at 13:36
1

The exact error is self-explanatory: the WINEPREFIX environment variable needs to be an absolute path to the wine prefix.

Based on your echo $WINEPREFIX, it is only set to prefix32 which is going to be a relative path to your current directory.

If you know that your wine prefix is always going to be prefix32 then edit your ~/.bashrc to do this at the end:

export WINEPREFIX="/home/$USER/prefix32"

If you only need it to use that prefix temporarily, then put it in front of your wine command:

WINEPREFIX=/home/$USER/prefix32 wine somefile.exe
  • Hello, Thanks for the Information, I just edited my ~/.bashrc and wrote export WINEPREFIX="/home/$USER/prefix32" as per your Instructions. Now, When i Try to Open Any .exe File Using the Command wine somefile.exe It Leaves me Error wine: '/root/.wine' is a 64-bit installation, it cannot be used with a 32-bit wineserver. – Yada Rahal Feb 24 '16 at 14:01
  • Are you trying to run Wine as root? Because that uses the root user's wineprefix, NOT your own. Why in the heck are yo utrying to use Wine as root? (Security 101: DO NOT RUN THINGS AS ROOT UNLESS THERE IS NO OTHER OPTION) – Thomas Ward Feb 24 '16 at 14:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.