Skip to content

Commit

Permalink
steam: decimate
Browse files Browse the repository at this point in the history
  • Loading branch information
K900 committed Sep 12, 2024
1 parent 0c75b59 commit 353db8b
Show file tree
Hide file tree
Showing 8 changed files with 115 additions and 427 deletions.
2 changes: 1 addition & 1 deletion nixos/modules/programs/steam.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ in {
default = pkgs.steam;
defaultText = lib.literalExpression "pkgs.steam";
example = lib.literalExpression ''
pkgs.steam-small.override {
pkgs.steam.override {
extraEnv = {
MANGOHUD = true;
OBS_VKCAPTURE = true;
Expand Down
3 changes: 3 additions & 0 deletions pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
, targetPkgs ? pkgs: []
, multiPkgs ? pkgs: []
, multiArch ? false # Whether to include 32bit packages
, includeClosures ? false # Whether to include closures of all packages
, extraBuildCommands ? ""
, extraBuildCommandsMulti ? ""
, extraOutputsToInstall ? []
Expand Down Expand Up @@ -171,13 +172,15 @@ let
${pkgs.glib.dev}/bin/glib-compile-schemas $out/share/glib-2.0/schemas
fi
'';
inherit includeClosures;
};

staticUsrProfileMulti = buildEnv {
name = "${name}-usr-multi";
paths = baseMultiPaths ++ multiPaths;
extraOutputsToInstall = [ "out" "lib" ] ++ extraOutputsToInstall;
ignoreCollisions = true;
inherit includeClosures;
};

# setup library paths only for the targeted architecture
Expand Down
17 changes: 2 additions & 15 deletions pkgs/games/steam/default.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{ makeScopeWithSplicing', generateSplicesForMkScope
, stdenv, buildFHSEnv, pkgsi686Linux, mesa-demos
, stdenv
}:

let
Expand All @@ -10,21 +10,8 @@ let
else if stdenv.hostPlatform.system == "i686-linux" then "i386"
else throw "Unsupported platform: ${stdenv.hostPlatform.system}";

steam-runtime = callPackage ./runtime.nix { };
steam-runtime-wrapped = callPackage ./runtime-wrapped.nix { };
steam = callPackage ./steam.nix { };
steam-fhsenv = callPackage ./fhsenv.nix {
mesa-demos-i686 =
if self.steamArch == "amd64"
then pkgsi686Linux.mesa-demos
else mesa-demos;
steam-runtime-wrapped-i686 =
if self.steamArch == "amd64"
then pkgsi686Linux.steamPackages.steam-runtime-wrapped
else null;
inherit buildFHSEnv;
};
steam-fhsenv-small = steam-fhsenv.override { withGameSpecificLibraries = false; };
steam-fhsenv = callPackage ./fhsenv.nix {};

# This has to exist so Hydra tries to build all of Steam's dependencies.
# FIXME: Maybe we should expose it as something more generic?
Expand Down
Loading

0 comments on commit 353db8b

Please sign in to comment.