Bug 9407 - Steam GUI works fine but games cannot be launched to due missing dependencies
Summary: Steam GUI works fine but games cannot be launched to due missing dependencies
Status: RESOLVED WORKSFORME
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Rémi Verschelde
QA Contact:
URL:
Whiteboard:
Keywords:
: 9942 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-03-15 17:25 CET by jcl darkc
Modified: 2015-07-11 23:59 CEST (History)
8 users (show)

See Also:
Source RPM: steam
CVE:
Status comment:


Attachments

Description jcl darkc 2013-03-15 17:25:35 CET
Description of problem:

Steam GUI works correctly, but games cannot be launched.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. install steam
2. create valve account
3. install demo game "The book of Unwritten Tales:The critter chronicle"
4. launch the game (does not start)

 then I started "steam" from command line to see log details. It looks like some packages are missing to run/install games.


Solution :

1) Install following packages 

urpmi dpkg sudo gksu apt-mga

2) add your account login in /etc/sudoers

3) launch "steam" from console (mandatory) it will ask you to sudo identify you

4) click on library of steam interface

5) click on play button of installed game
(will ask you to sudo identify again)

 then the game works

 JC


Reproducible: 

Steps to Reproduce:
Comment 1 jcl darkc 2013-03-16 16:01:39 CET
I wanted to add that the previous things have been tested from KDE environment.
Comment 2 Manuel Hiebel 2013-03-16 16:11:12 CET
are you sure for dkpg or apt ? it seems strange (but I don't know how stream works)
Comment 3 jcl darkc 2013-03-16 17:28:11 CET
(In reply to Manuel Hiebel from comment #2)
> are you sure for dkpg or apt ? it seems strange (but I don't know how stream
> works)

definitively YES. At least it's requested by the game "The book of Unwritten Tales:The critter chronicle" (from a game's script)

 You should try by yourself....
Manuel Hiebel 2013-03-16 18:32:08 CET

Assignee: bugsquad => nicolas.lecureuil

Comment 4 Perilio Castrol 2013-03-31 17:37:29 CEST
It seems game dependent because I am playing Half-Life using Steam and I don't have installed those packages. Half-Life runs perfectly.

CC: (none) => periliocastrol

Comment 5 Manuel Hiebel 2013-05-05 12:57:23 CEST
*** Bug 9942 has been marked as a duplicate of this bug. ***

CC: (none) => ezequiel_partida

Manuel Hiebel 2013-05-05 12:57:53 CEST

Summary: Steam GUI works fine but games cannot be launched => Steam GUI works fine but games cannot be launched to due missing dependencies

Comment 6 Rémi Verschelde 2013-05-22 13:04:34 CEST
dpkg, sudo and apt are needed if you want that steamdeps installs the missing dependencies. I'm not entirely sure that it would work for all dependencies, since the names differ between Mageia's packages and what Steam is expecting.

The better solution would be to fix steamdeps in the package, so that it relies on urpmi and pkg-config, and not on Debian-based tools.

I'm running Steam without dpkg, sudo and apt, so I'll try to reproduce the bug. Currently downloading the demo.

CC: (none) => remi

Comment 7 Rémi Verschelde 2013-05-22 13:28:05 CEST
Could not reproduce on an i586 system, the game launches for me without dpkg, sudo and apt. I could launch and play the game, but experienced a segfault each time I try to explore the in-game settings.

JC, if you are on a 64bit arch, I guess your problem for The Critter Chronicles is that you lacked 32bit libraries.

@Nicolas: There will be similar issues in the future if Steam can't installed the required dependencies, so...
* Quick and dirty fix: Add requires on dpkg, apt, sudo or patch steamdeps to require su priviledges... It can't be a good solution IMO.
* Do it right: Patch steamdeps to be compatible with Mageia. I talked about it yesterday with a user who did it for himself, it might be handy to see how he fixed steamdeps.
Comment 8 Stuart Morgan 2013-05-23 14:37:16 CEST
Rémi I simply patched steamdeps to return early without doing the dependency checks at all. This works fine for most games because all the currently required steam dependencies are pulled in by the package, but this may not be future proof. It's a reasonable quick fix which can be replaced later by the 'correct' fix, just stick 'return 0' on the line after 'def main():'

Both steamdeps and dependencies.txt would need to be edited for a proper fix. Steamdeps to run the urpmi/q/* equivalents to current apt-get/dpkg commands and dependencies.txt to change the package names to match those used by mageia. Since sudo isn't configured by default on mageia, gurpmi might be better than urpmi for the actual installation command as it will then prompt the user for credentials (tidier than other solutions).

CC: (none) => smorgan

Comment 9 jcl darkc 2013-05-23 15:38:26 CEST
(In reply to Rémi Verschelde from comment #7)

> 
> JC, if you are on a 64bit arch, I guess your problem for The Critter
> Chronicles is that you lacked 32bit libraries.

  Yes I am running 64bits arch
Comment 10 Florian Hubold 2014-07-06 17:06:54 CEST
Seems steamdeps should be adjusted further, as for users who have dpkg installed it may want to install dependencies, which are called slightly different on Mageia

See also https://forums.mageia.org/en/viewtopic.php?f=8&t=8005

CC: (none) => doktor5000

Comment 11 Ezequiel Partida 2015-01-20 23:53:14 CET
It is kind of annoying the need to have to type the sudo password every time you run Steam specially when you have young kids at home.

I just noticed that if you close the terminal window steam will run.. I don't know if that happens when it needs to update itself.
Comment 12 Rémi Verschelde 2015-01-20 23:59:50 CET
@Ezequiel: A workaround would be to uninstall dpkg, then Steam won't ask you for the sudo package because it will abort the dependency check before that.
Comment 13 Oleg Bosis 2015-01-21 07:49:15 CET
Just remove/rename /usr/bin/steamdeps file and the problem won't appear any more. This is the easiest way to deal with it.

Another way is to "cleanup" the contents of this file and make it look like the following:

[code]
#!/usr/bin/env python
"""
	This script handles installing system dependencies for games using the
	Steam runtime.  It is intended to be customized by other distributions
	to "do the right thing"

	Usage: steamdeps dependencies.txt
"""

import sys

###
def main():
	return 0


if __name__ == "__main__":
	sys.exit(main())
[/code]

or even simpler:

[code]
#!/usr/bin/env python

if __name__ == "__main__":
	return 0
[/code]

This is more difficult way ))). You can treat this comment as a patch requested on forum (see comment 10) )).

And don't forget that all required dependencies are really installed automagically by urpmi when you install the steam package (the one that comes with nonfree repo1).

CC: (none) => olegbosis

Comment 14 Florian Hubold 2015-01-21 20:11:08 CET
(In reply to Oleg Bosis from comment #13)
> Just remove/rename /usr/bin/steamdeps file and the problem won't appear any
> more. This is the easiest way to deal with it.

Easiest fix is most often not a proper fix.

> And don't forget that all required dependencies are really installed
> automagically by urpmi when you install the steam package (the one that
> comes with nonfree repo1).

Well, all required dependencies - for now that's only zenity and mesa ...

Proper fix was already mentioned by Stuart:

(In reply to Stuart Morgan from comment #8)
> Both steamdeps and dependencies.txt would need to be edited for a proper
> fix. Steamdeps to run the urpmi/q/* equivalents to current apt-get/dpkg
> commands and dependencies.txt to change the package names to match those
> used by mageia. Since sudo isn't configured by default on mageia, gurpmi
> might be better than urpmi for the actual installation command as it will
> then prompt the user for credentials (tidier than other solutions).
Comment 15 Oleg Bosis 2015-01-21 20:31:00 CET
(In reply to Florian Hubold from comment #14)
> Proper fix was already mentioned by Stuart:
> 
> (In reply to Stuart Morgan from comment #8)
> > Both steamdeps and dependencies.txt would need to be edited for a proper
> > fix. Steamdeps to run the urpmi/q/* equivalents to current apt-get/dpkg
> > commands and dependencies.txt to change the package names to match those
> > used by mageia. Since sudo isn't configured by default on mageia, gurpmi
> > might be better than urpmi for the actual installation command as it will
> > then prompt the user for credentials (tidier than other solutions).

I don't think this is a proper fix. All the required dependencies should be installed along with the steam package installation. This is the main purpose of any package management system including urpmi. Installing dependencies when running a program is a very bad behavuior even if it is technically possible. And using post-install script just won't work due to rpm's db locking (you can not use urpmi/urpme inside packages' pre/post scripts). Another problem with this "fix" is orphaning packages that are not directly required by any other and where not installed manyally.

So the only proper fix is to get rid of this stupid steamdeps script and provide all requires throuh the standard rpm capability i.e. "Requires" keyword in the spec file.
Comment 16 Florian Hubold 2015-01-21 22:00:40 CET
That would mean somebody needs to maintain the translation of dependencies from the steamdeps script and dependencies.txt to Requires. Better would be to find a way to parse the file, so in case of updates they are automatically added to Requires. Although it doesn't look like there will be any more updates to the steam package itself upstream.

Apart from that currently steam uses the bundled libraries in ~/.local/share/Steam/ubuntu* from what I can see. It works fine as far as I've used it with the few linux games that I have, and it may not work at all when you try to use it with the current system libraries that we have in Mageia or it might produce bugs that we have to fix, with no support from upstream.

And there's quite some stuff that needs to be provided AFAICS:

ââ[doktor5000@Mageia5]â[21:57:42]â[~]
ââââ¼ find ~/.local/share/Steam/ubuntu* -type f | wc -l
14056


Did anyone test this yet at all (use Mageia system libraries instead of the bundled ubuntu12 ones) and if so, does steam work properly?
Comment 17 Oleg Bosis 2015-01-21 22:36:25 CET
(In reply to Florian Hubold from comment #16)
> That would mean somebody needs to maintain the translation of dependencies
> from the steamdeps script and dependencies.txt to Requires. Better would be
> to find a way to parse the file, so in case of updates they are
> automatically added to Requires. Although it doesn't look like there will be
> any more updates to the steam package itself upstream.

Even if there would be some updates (I think they would) it is not really frequent event so manual maintaining of Requires would not be burdensome (IMHO). 

> Apart from that currently steam uses the bundled libraries in
> ~/.local/share/Steam/ubuntu* from what I can see. It works fine as far as
> I've used it with the few linux games that I have, and it may not work at
> all when you try to use it with the current system libraries that we have in
> Mageia or it might produce bugs that we have to fix, with no support from
> upstream.
> 
> And there's quite some stuff that needs to be provided AFAICS:
> 
> ââ[doktor5000@Mageia5]â[21:57:42]â[~]
> ââââ¼ find ~/.local/share/Steam/ubuntu* -type f | wc -l
> 14056
> 
> 
> Did anyone test this yet at all (use Mageia system libraries instead of the
> bundled ubuntu12 ones) and if so, does steam work properly?

I've tried to use system libraries instead of steam ones and no, steam doesn't work with them (more correctly steam itself works but steam games do not). And you can not get rid of steam "built-in" runtime. It is always installed automatically and maintains full binary compatibility with ubuntu.

So there's no any reason bothering about runtime libraries. Steam package should only require those ones that are listed in steamdeps.txt and are usual console utilities (curl, xterm or gnome-terminal, python-apt, zenity, xz-utils). Probably some of them are not really required if there is no steamdeps script and apt.
Comment 18 Morgan Leijström 2015-01-22 17:53:44 CET
Hm?  Here the situation is that we installed steam using the magiea package a couple weeks ago and i do not remember any problem.  Installed a demo. Have later bought two games and another demo installed.  All just worked.

Then suddenly yesterday steam asked if i had bought a new computer.
Seem it could not find any installed game.
But my account registration was intact locally and at steam.
It send me a mail woth a cod ei type din and it downloade dand installed one game.
(id did not find the ones it installed earlier.
Today it silently refuse to launch anything.

Weird.  Something broke with recent update maybe?

System: mga5 64 bit KDE from fresh install around alpha, continous updates.
Machine: old server: double dual opteron, + a somewhat modern radeon HD 6850

CC: (none) => fri

Comment 19 Morgan Leijström 2015-01-24 20:37:21 CET
Doh. /home was full. Apparently my head too...
Four demos/game now works OK, but the fith that worked a few days ago fail to launch despite cleaning (possibly i missed something) reinstall and lot of disk space.  I sm not familir with all places Steam use yet. Digging...
Comment 20 Neo Futur 2015-01-28 14:00:20 CET
I also had problems on mageia sonce recent steam updates, see http://steamcommunity.com/groups/SteamClientBeta/discussions/0/620703493332717454/

CC: (none) => mageia.org

Comment 21 Rémi Verschelde 2015-02-01 12:28:37 CET
(In reply to Florian Hubold from comment #14)
> (In reply to Oleg Bosis from comment #13)
> 
> > And don't forget that all required dependencies are really installed
> > automagically by urpmi when you install the steam package (the one that
> > comes with nonfree repo1).
> 
> Well, all required dependencies - for now that's only zenity and mesa ...

And that's about all it wants, at least for the main GUI:
$ steam
Package curl needs to be installed
Package python-apt needs to be installed
Package xterm needs to be installed
Package xz-utils needs to be installed
Package zenity needs to be installed
Package libgl1-mesa-dri:i386 needs to be installed
Package libgl1-mesa-glx:i386 needs to be installed
Package libc6:i386 needs to be installed

curl, zenity and mesa, the rest is Ubuntu-specific stuff: xterm to be able to spawn a terminal when asking for the sudo password, python-apt and xz-utils to handle the dependencies...
We definitely don't need this stuff.

> Proper fix was already mentioned by Stuart:
> 
> (In reply to Stuart Morgan from comment #8)
> > Both steamdeps and dependencies.txt would need to be edited for a proper
> > fix. Steamdeps to run the urpmi/q/* equivalents to current apt-get/dpkg
> > commands and dependencies.txt to change the package names to match those
> > used by mageia. Since sudo isn't configured by default on mageia, gurpmi
> > might be better than urpmi for the actual installation command as it will
> > then prompt the user for credentials (tidier than other solutions).

I had a look at this back when we were preparing the Mageia 4 release, and it just can't be done. steamdeps itself can be edited somewhat to use urpm* instead of dpkg and aptitude, but the dependencies.txt comes directly from Steam: each game has its own dependencies.txt file which tells to steamdeps which dependencies to install, and we can't fix steamdeps in a way that it would be able to convert any Ubuntu library listed in an unknown dependencies.txt file to Mageia deps.

So the solution is indeed to remove/edit steamdeps to a minimal script that would fail silently. I'm using Steam without dpkg (i.e. without steamdeps since it fails silently when there is no dpkg), and I never had any issue for a year or so. Most applications bundle everything they need in Steam's runtime, and we can't fight against that. I'm not even sure steamdeps is really used at all anymore by upstream.
Comment 22 Rémi Verschelde 2015-02-02 19:55:55 CET
Just checked what Fedora (RPM Fusion) is doing with its steam package. In the past they had tried to patch steamdeps it seems: https://gist.github.com/Mailaender/4973797

But in their current package they just rm the steamdeps script. I think we should do the same.
Comment 23 Florian Hubold 2015-02-02 22:52:58 CET
(In reply to Rémi Verschelde from comment #22)
> But in their current package they just rm the steamdeps script. I think we
> should do the same.

Yep, also see the reply in comment 20 - if users might update their steam runtime to any of the beta versions within the client, it might easily break otherwise.
Comment 24 Rémi Verschelde 2015-07-11 23:59:27 CEST
Ok, I've just renamed steamdeps to steamdeps.save in the update I'm providing in bug 13307. steamdeps doesn't work anyway, so let's avoid the problems that it creates when dpkg is installed.

As for the initial issue of comment 0, I believe it is no longer relevant as nowadays Steam bundles practically all its required libraries in the Steam runtime; so basically any Steam user has a copy of all relevant libs of Ubuntu 12.04 LTS in its path. And the games that need libs that are not in the runtime usually provided them with their game data.

And as I stated in comment 7, the mentioned game works fine for me, so closing as WORKSFORME.

Status: NEW => RESOLVED
Resolution: (none) => WORKSFORME
Assignee: mageia => rverschelde


Note You need to log in before you can comment on or make changes to this bug.