Bug 244207 - [NEW PORT] games/linux-steam-utils: Linux Steam scripts/workarounds
Summary: [NEW PORT] games/linux-steam-utils: Linux Steam scripts/workarounds
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Dave Cottlehuber
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-02-18 05:13 UTC by Alex S
Modified: 2020-06-15 05:33 UTC (History)
8 users (show)

See Also:


Attachments
steam-utils.port (3.77 KB, patch)
2020-02-18 05:13 UTC, Alex S
no flags Details | Diff
steam-utils.log (25.28 KB, text/plain)
2020-02-18 05:17 UTC, Alex S
no flags Details
steam-utils.patch v2 (3.88 KB, patch)
2020-02-19 07:14 UTC, Alex S
no flags Details | Diff
steam-utils.patch v3 (3.70 KB, patch)
2020-02-23 13:35 UTC, Alex S
no flags Details | Diff
linux-steam-utils.log (25.48 KB, text/plain)
2020-02-23 13:39 UTC, Alex S
no flags Details
steam-utils.patch v4 (3.67 KB, patch)
2020-03-01 18:20 UTC, Alex S
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex S 2020-02-18 05:13:55 UTC
Created attachment 211733 [details]
steam-utils.port

I've been asked about it twice, so here is a port for my Linux Steam scripts/workarounds. These scripts make installing Steam on FreeBSD considerably less difficult. To be honest, the result is still kind of underwhelming, especially for people expecting to run actual games and not just stare at the game library UI. Still, this is a considerable improvement upon previous attempts.
Comment 1 Alex S 2020-02-18 05:17:16 UTC
Created attachment 211734 [details]
steam-utils.log

`synth test` log
Comment 2 Alex S 2020-02-18 05:26:51 UTC
By the way, it would be nice to state somewhere this is not an official Valve script, but I really can't decide where to put that. On the other hand, it should be quite obvious anyway, so maybe not. Any suggestions are appreciated.
Comment 3 Nick Wolff 2020-02-18 16:40:09 UTC
Thanks Alex.

I would say the install message would be a good place for a disclaimer that this is an unofficial utility incase someone doesn't read the package description.
Comment 4 Alex S 2020-02-19 07:14:27 UTC
Created attachment 211757 [details]
steam-utils.patch v2

+ disclaimer
- symlink warning
Comment 5 Alex S 2020-02-19 07:24:46 UTC
(In reply to Nick Wolff from comment #3)

> I would say the install message would be a good place for a disclaimer

I'm quite convinced the target audience for this port doesn't habitually read those messages... We'll see how it goes.
Comment 6 Alex S 2020-02-23 13:35:41 UTC
Created attachment 211855 [details]
steam-utils.patch v3

steam-utils -> linux-steam-utils, USES=linux
Comment 7 Alex S 2020-02-23 13:39:13 UTC
Created attachment 211856 [details]
linux-steam-utils.log

`synth test` log
Comment 8 Kurt Jaeger freebsd_committer freebsd_triage 2020-03-01 16:42:14 UTC
testbuilds@work
Comment 9 Kurt Jaeger freebsd_committer freebsd_triage 2020-03-01 17:16:28 UTC
testbuilds look fine. Can someone report if run-tests are fine ?
Comment 10 Alex S 2020-03-01 18:20:40 UTC
Created attachment 212080 [details]
steam-utils.patch v4

Fixed a few mildly embarrassing things.
Comment 11 Alex S 2020-03-06 22:09:23 UTC
Regarding the mailing list question:

> can someone do some run-tests

That would be nice indeed. I think vaguely remember CC'ing someone...

FWIW, there is a corresponding forum thread @ https://forums.freebsd.org/threads/steamuxulation-redux.72140/. No, there is practically zero chance somebody there could be convinced to specifically test the port. That's just the way it is.

> and explain how to use that port ?

It's precisely what the readme/pkg-message says: run `steam-install` script (to download and install Steam into a user home directory), run `steam` script. After that you should be able to log in and use the game library UI. It's assumed, but not explicitly mentioned, that you already have a Steam account and that OpenGL under Linuxulator is properly set up.
Comment 12 shadow53+freebsd 2020-03-15 00:53:28 UTC
(In reply to Alex S from comment #11)

I'm coming up onto finals week at the moment, but once that is over I can take a look at testing this port. I've got 114 games in my library, most of which have Linux versions I can test. Are there any that I should specifically check?

(My games list is at https://steamcommunity.com/id/shad0w0710/games/?tab=all if that helps with suggestions)
Comment 13 Alex S 2020-03-15 01:25:54 UTC
(In reply to shadow53+freebsd from comment #12)

> I've got 114 games in my library, most of which have Linux versions I can test.
> Are there any that I should specifically check?

Whatever you want to check. Let me know if anything actually runs (or not).
Comment 14 Alex S 2020-04-02 22:05:58 UTC
So, is there anything I *personally* can do to move this forward? That is, something not involving waiting indefinitely for other people.
Comment 15 Alex S 2020-04-03 23:47:19 UTC
Ok, enough is enough. This certainly was quite enlightening.
Comment 16 Dave Cottlehuber freebsd_committer freebsd_triage 2020-04-04 07:06:23 UTC
taking this
Comment 17 Dave Cottlehuber freebsd_committer freebsd_triage 2020-04-04 07:08:27 UTC
taking this as frankly its amazing. Rumours of netflix working in the game browser should be enough to pique more peoples' interest...

Kurt are you ok with the patch as is, or do you see the need for further tweaks and changes? I can test this later in the weekend with steam.
Comment 18 Kurt Jaeger freebsd_committer freebsd_triage 2020-04-04 07:22:16 UTC
I'm very fine with the patch, we just need run-tests.
Comment 19 Alex S 2020-04-04 21:50:21 UTC
(In reply to Dave Cottlehuber from comment #17)

> taking this

Don't miss the latest commit.

> Rumours of netflix working in the game browser should be enough to pique more peoples' interest...

Nah, existing FreeBSD users has been self-selecting for years to the point most of them consider the absence of those things a part of their identity. Steam/Widevine/CUDA would be valuable for getting attention of people with some interest in FreeBSD, who are currently using a Linux/Windows desktop. (Which is precisely the crowd who won't test this port.) I'm not particularly optimistic, but at least it's worth a try.
Comment 20 Thibault Payet 2020-04-05 12:23:56 UTC
The port build fine, steam is launching, the store is loading.

One feature that I miss is the possibility to run steam with optirun (the port https://reviews.freebsd.org/D22521 ).
Comment 21 Alex S 2020-04-05 13:18:59 UTC
(In reply to Thibault Payet from comment #20)

> One feature that I miss is the possibility to run steam with optirun (the port https://reviews.freebsd.org/D22521).

You would have to ask Theron for Linux executable support.
Comment 22 Thibault Payet 2020-04-05 13:49:09 UTC
(In reply to Alex S from comment #21)
It is steam that I cannot run with nvrun-vgl, I can run outside steam a linux game with the nvidia driver via a linux VirtualGL wrapper. The steam wrapper seems to clear the LD_LIBRARY_PATH in some ways.
Comment 23 Alex S 2020-04-05 14:46:11 UTC
(In reply to Thibault Payet from comment #22)

> I can run outside steam a linux game
> with the nvidia driver via a linux VirtualGL wrapper.

Is this actually available somewhere?

> The steam wrapper seems to clear the LD_LIBRARY_PATH in some ways.

Yes, quite intentionally so. We have to account for the three separate LD_LIBRARY_PATH environment variables: one for the native FreeBSD environment, one for the Steam client and another one for games. There is no way to make this arbitrary stackable with other wrapper scripts.
Comment 24 Thibault Payet 2020-04-05 15:03:17 UTC
(In reply to Alex S from comment #23)
>> I can run outside steam a linux game
>> with the nvidia driver via a linux VirtualGL wrapper.

>Is this actually available somewhere?

There is no place where this is documented, what I do is simply to download virtualgl (and turbojpeg) for centos7, extract it in a directory and then running my linux executable with :
env LD_LIBRARY_PATH=path_to_linux_virtualgl_lib64 path_to_linux_virtualgl_bin/vglrun -gl -d :8 some_linux_program

using the nvidia-hybrid-graphics port .

>Yes, quite intentionally so. We have to account for the three separate
>LD_LIBRARY_PATH environment variables: one for the native FreeBSD environment,
>one for the Steam client and another one for games. There is no way to make this
>arbitrary stackable with other wrapper scripts.

Wouldn't it be possible to have a special environment variable that will be append to each LD_LIBRARY_PATH ?
Comment 25 Alex S 2020-04-05 15:30:12 UTC
(In reply to Thibault Payet from comment #24)

> Wouldn't it be possible to have a special environment variable that will be append to each LD_LIBRARY_PATH?

It is possible, but since I don't have a compelling use case for that, I didn't bother. Try it and see how it goes.
Comment 26 Dave Cottlehuber freebsd_committer freebsd_triage 2020-04-16 19:59:20 UTC
this works very nicely; there are of course many warnings and errors spat out during run time but it's a fantastic piece of hackery :-)

tested with XCOM2 as it's the only thing I have in steam. Many thanks Alex!

Kurt are you ok if I commit this?
Comment 27 Alex S 2020-04-16 20:19:38 UTC
I would appreciate a version bump to 20200404. It has one trivial change (a workaround for inaccessible /compat/linux/proc/self/fd which is an issue with at least NomadBSD), it doesn't need retesting in my opinion.
Comment 28 Kurt Jaeger freebsd_committer freebsd_triage 2020-04-17 05:35:50 UTC
(In reply to Dave Cottlehuber from comment #26)
Of course I'm absolutly fine with you committing it 8-}
Comment 29 commit-hook freebsd_committer freebsd_triage 2020-04-19 10:58:02 UTC
A commit references this bug:

Author: dch
Date: Sun Apr 19 10:57:33 UTC 2020
New revision: 532102
URL: https://svnweb.freebsd.org/changeset/ports/532102

Log:
  games/linux-steam-utils: new port

  PR:		244207
  Submitted by:	Alex S <iwtcex@gmail.com>
  Reviewed by:	pi
  Differential Revision:	https://reviews.freebsd.org/D24501

Changes:
  head/games/Makefile
  head/games/linux-steam-utils/
  head/games/linux-steam-utils/Makefile
  head/games/linux-steam-utils/distinfo
  head/games/linux-steam-utils/pkg-descr
  head/games/linux-steam-utils/pkg-message
  head/games/linux-steam-utils/pkg-plist
Comment 30 Dave Cottlehuber freebsd_committer freebsd_triage 2020-04-19 10:59:39 UTC
updated to 202020404 as requested, poudriere build passes on x86_64 for 12.1R and 13-0.CURRENT.