Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

steamcmd: init at 20180104 #38878

Merged
merged 1 commit into from Sep 8, 2018
Merged

steamcmd: init at 20180104 #38878

merged 1 commit into from Sep 8, 2018

Conversation

tadfisher
Copy link
Contributor

Motivation for this change

Package the steamcmd utility for NixOS.

Curiously, steamcmd.sh and its libraries must reside in a Steam root such that it can overwrite itself at runtime. So I've adapted the debian wrapper which basically copies the system install over to the user's Steam root if it doesn't exist.

An interesting possibility could be to use this tool to install Steam games to the Nix store. It would be of limited use for packaging, however, because Steam games aren't versioned.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@GrahamcOfBorg
Copy link

No attempt on x86_64-linux (full log)

The following builds were skipped because they don't evaluate on x86_64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@GrahamcOfBorg
Copy link

No attempt on aarch64-linux (full log)

The following builds were skipped because they don't evaluate on aarch64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@@ -19,6 +19,7 @@ let
then pkgs.pkgsi686Linux.steamPackages.steam-runtime-wrapped
else null;
};
steamcmd = callPackage ./steamcmd.nix;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we want to initialize it here with callPackage ./steamcmd.nix {}. That way you should be able to get rid of the inherit steam thing below.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

version = "20180104"; # According to steamcmd_linux.tar.gz mtime

src = fetchurl {
url = https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a little annoying it isn't versioned. Any way they could make one available? Definitely look into the url used by other distros.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AUR does not have a versioned URL available.

sha256 = "0z0y0zqvhydmfc9y9vg5am0vz7m3gbj4l2dwlrfz936hpx301gyf";
};

unpackCmd = ''
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the default unpack should work. Any reason for including this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The source tarball does not have a top-level directory. I found a preUnpack incantation that works from another package, so hopefully it's a bit cleaner.

@goertzenator
Copy link
Contributor

I tried this branch as-is and it worked perfectly for my needs. I was able to install and run a viable Arma 3 server.

I'd love to see this merged and I will happily test any updates to this PR. When merged, I'd love to also have it in release-18.03 if at all possible.

@tadfisher
Copy link
Contributor Author

@goertzenator Unfortunately, this package is likely to break once they update the steamcmd installer, since it is not versioned. I've reported an issue here: ValveSoftware/steam-for-linux#5447

@goertzenator
Copy link
Contributor

goertzenator commented May 21, 2018

That is unfortunate, but it doesn't need to be a deal breaker. Spideroak is in the same boat and the strategy for NixOs and Arch is to just stay on top of updates. Furthermore, the steamcmd tarball from Janurary 4 worked for me on May 20, so churn seems to be low.

@tadfisher
Copy link
Contributor Author

@matthewbauer Updated.

@GrahamcOfBorg
Copy link

No attempt on aarch64-linux (full log)

The following builds were skipped because they don't evaluate on aarch64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@GrahamcOfBorg
Copy link

No attempt on x86_64-linux (full log)

The following builds were skipped because they don't evaluate on x86_64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@vcunat
Copy link
Member

vcunat commented Jun 10, 2018

@tadfisher
Copy link
Contributor Author

@matthewbauer Anything else need to be changed at this point, or should we close this due to lack of a versioned source?

@goertzenator
Copy link
Contributor

This no longer seems to work due to some dependency breakage. Maybe a rebase on the current tree would help?

I still use this. If the above problem is trivial I'd love to see this merged.

@tadfisher
Copy link
Contributor Author

@goertzenator Rebased, seems to build fine.

@GrahamcOfBorg
Copy link

No attempt on x86_64-linux (full log)

The following builds were skipped because they don't evaluate on x86_64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@GrahamcOfBorg
Copy link

No attempt on aarch64-linux (full log)

The following builds were skipped because they don't evaluate on aarch64-linux: steamcmd

Partial log (click to expand)


a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.


@matthewbauer matthewbauer merged commit a0dc485 into NixOS:master Sep 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants