vuizvui icon indicating copy to clipboard operation
vuizvui copied to clipboard

Packaging SteamKit for Guix

Open Ambrevar opened this issue 4 years ago • 4 comments

Hi! Friendly cousin here again! :)

I'm trying to package SteamKit for Guix, and since you people have it here in this repository, I figured I would just ask.

As I understand, SteamKit must be compiled and it depends on Mono >= 5.4.

Guix only has Mono 4.4 :( I've tried updating it, but I get stuck with failing tests. https://github.com/mono/mono/issues/18979

I tried to copy Nix Mono definitions as close as possible. Typically, when Nix succeeds and Guix doesn't, it's because Guix does not have networking at build time. So this might be the issue here. Thoughts?

Otherwise, do you think it would be possible to get SteamKit to run without Mono 5.4?

Or do you know of any alternative to SteamKit?

Thanks in advance!

Ambrevar avatar Feb 21 '20 10:02 Ambrevar

Typically, when Nix succeeds and Guix doesn't, it's because Guix does not have networking at build time. So this might be the issue here. Thoughts?

No, nix doesn’t either, except if you turn sandboxing off deliberately (which we don’t do).

Profpatsch avatar Feb 23 '20 15:02 Profpatsch

I tried to copy Nix Mono definitions as close as possible. Typically, when Nix succeeds and Guix doesn't, it's because Guix does not have networking at build time. So this might be the issue here. Thoughts?

Hm, I doubt that, since what @Profpatsch said - it's the same with Nix, we don't have networking at build time. However, when looking at the Nix package I can see that we don't actually run the tests. I'm not the maintainer of the Mono package in nixpkgs, but maybe they ran into the same issue?

Otherwise, do you think it would be possible to get SteamKit to run without Mono 5.4?

Phew, it's been a while since I was working an SteamKit, but I think if you're using an older version of SteamKit, you might be able to get it to compile - however I'm not sure whether it would still be able to communicate with Steam.

Did you try whether it works if you temporarily disable tests for Mono 5.4?

Or do you know of any alternative to SteamKit?

Back then when I integrated SteamKit, it was the only alternative I could find, which allowed to download Steam depots without Steam itself. So no, at least I'm not aware of alternatives.

aszlig avatar Feb 23 '20 20:02 aszlig

Thanks for the update, it's very useful.

I think mono 6 is working on Guix despite the failing tests. I'll leave them out for now.

I'm currently working on the dotnet* packages: first I'll patch the binary packages like Nix does, then I'll try to build from source like Arch Linux does: https://git.archlinux.org/svntogit/community.git/tree/trunk/PKGBUILD?h=packages/dotnet-core

With the dotnet* packages and mono-6 working, I should be able to build msbuild.

And after that, SteamKit.

Lots of work ahead, but looks like I can do it! I'll keep you updated if I manage to build dotnet*, I guess it will be useful to Nix too.

Wish me luck! :D

Ambrevar avatar Feb 27 '20 13:02 Ambrevar

I've made lots of progress:

  • Mono 6 seems to work (tests don't pass though).
  • I've packaged dotnet-sdk (using a binary archive like Nix does).
  • I've built msbuild and it can build a trivial project (the Nix test)

I'm stuck at building protobuf-net (a dep of SteamKit): msbuild fails. I'm discussing the issue with Nix upstream: https://github.com/NixOS/nixpkgs/issues/81194

Pfeww, Mono is hard :( Anyone knowledgeable with Mono in the Nix community?

Ambrevar avatar Feb 28 '20 16:02 Ambrevar