Confused - A few Questions:

Questions about Wine on Linux
Locked
NewtSoup
Level 1
Level 1
Posts: 9
Joined: Sun Aug 13, 2017 11:40 am

Confused - A few Questions:

Post by NewtSoup »

Hi, I was wondering if I can get some help?

I have wine-staging installed and for the most part it works. I'm very new to Wine and don't entirely get how it works.

I installed wine using the command line and added the appropriate repository as the Ubuntu Software Centre installed a much older version than I wanted.

1) If I type wine at the command line I get "command not found" so I have to run everything using /opt/wine-staging/bin/wine .....

This works but I would rather be able to just type "wine <application>" and have it run. How do I fix this?

2) I have programs installed in the default drive_c and there are desktop shortcuts which work when I double click on them

How do I know whether they are running wine or wine64 ?
How would I set a default "wine"? or a default wine for an app.

3) I have downloaded winetricks to have a look at but when I run it I get "wineserver not found!" how can I fix this? Knowing that I do indeed have wine installed.

I'm sure it's just down to environment variables not being set correctly but as I say I'm new and still learning.
User avatar
Bob Wya
Level 12
Level 12
Posts: 3068
Joined: Sat Oct 16, 2010 7:40 pm

Re: Confused - A few Questions:

Post by Bob Wya »

NewtSoup wrote:Hi, I was wondering if I can get some help?

I have wine-staging installed and for the most part it works. I'm very new to Wine and don't entirely get how it works.

I installed wine using the command line and added the appropriate repository as the Ubuntu Software Centre installed a much older version than I wanted.

1) If I type wine at the command line I get "command not found" so I have to run everything using /opt/wine-staging/bin/wine .....
You haven't followed the WineHQ: Ubuntu installation Wiki!

The winehq-staging, winehq-devel and winehq-stable all install compatibility symbolic links in: /usr/bin/
Note: the hq suffix!

Alternatively just add the wine-staging package out-of-tree PATH to your (Wine) user's PATH env variable:

Code: Select all

printf '\n%s\n' 'export PATH="/opt/wine-staging/bin:${PATH}"' >>"${HOME}/.bashrc"
NewtSoup wrote:2) I have programs installed in the default drive_c and there are desktop shortcuts which work when I double click on them

How do I know whether they are running wine or wine64 ?
How would I set a default "wine"? or a default wine for an app.
You explicitly have to type:

Code: Select all

wine64
to start the 64-bit Wine binary.

You can find the native Linux .desktop launchers Wine automagically builds with:

Code: Select all

find "${HOME}/.local/share/applications/" -name '*.desktop'
You are of course free to change the Exec= line in these files (with the text editor of your choice).
NewtSoup wrote: 3) I have downloaded winetricks to have a look at but when I run it I get "wineserver not found!" how can I fix this? Knowing that I do indeed have wine installed.
This because you have the wine-staging package installed outside of your user's PATH. See my answer to 1).
NewtSoup wrote: I'm sure it's just down to environment variables not being set correctly but as I say I'm new and still learning.
Reading program documentation, and any supplied Wiki's/FAQ's, is a really good habit to get into... 8)

Bob
NewtSoup
Level 1
Level 1
Posts: 9
Joined: Sun Aug 13, 2017 11:40 am

Re: Confused - A few Questions:

Post by NewtSoup »

Thanks for the help.

In my defence I did read the Wiki Page for installing Wine in Ubuntu

The instructions are:

sudo dpkg --add-architecture i386
wget -nc https://dl.winehq.org/wine-builds/Release.key
sudo apt-key add Release.key
sudo apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/
sudo apt-get install --install-recommends winehq-staging

That's all.

And I did exactly that.
So if it installed outside my user path it wasn't of my particular doing.
I wouldn't know anything about "compatibility symbolic links"
Like I said I'm very new to this ( and Linux ) - I followed the instructions to install Wine Staging because it's the only one that makes Star Trek Online run at the moment.
I apologise for not knowing enough. My anxiety makes it hard for me to cope with walls of instruction.
I'm proud to have got as far as I have :)
User avatar
dimesio
Moderator
Moderator
Posts: 13207
Joined: Tue Mar 25, 2008 10:30 pm

Re: Confused - A few Questions:

Post by dimesio »

sudo apt-get install --install-recommends winehq-staging
Are you sure you didn't mistakenly put wine-staging instead of winehq-staging when you actually ran that command? The reason I ask is because doing that would produce exactly the problem you're experiencing.
User avatar
Bob Wya
Level 12
Level 12
Posts: 3068
Joined: Sat Oct 16, 2010 7:40 pm

Re: Confused - A few Questions:

Post by Bob Wya »

NewtSoup wrote:...
I wouldn't know anything about "compatibility symbolic links"
...
Basically then - to put that jargon in simpler terms...

All the main winehq-staging package contains is shortcut links:

Code: Select all

...
/usr/bin/wine -> /opt/wine-staging/bin/wine
...
/usr/share/applications/wine.desktop -> /opt/wine-staging/share/applications/wine.desktop
...
The only dependency for the winehq-staging package is the wine-staging package.

The wine-staging package contains all the out-of-tree actual Wine binaries, libraries, manual, and desktop files.
The files are stored into this directory:

Code: Select all

/opt/wine-staging/
You must therefore of installed the wine-staging package by accident...

FYI ...
The packages are built this way... So that you can install:
  • wine-devel (the Wine Development package)
  • wine-staging (the Wine Staging package)
  • wine-stable (the Wine Stable package)
simultaneously on your system.

Take a look at the Linux Filesystem Hierarchy Standard.

Code: Select all

/opt
is considered an out-of-tree installation location - when referencing this FHS.

Bob
Locked