diff --git a/nix/srcds/default.nix b/nix/srcds/default.nix index be1dda5..8bc31c9 100644 --- a/nix/srcds/default.nix +++ b/nix/srcds/default.nix @@ -57,6 +57,11 @@ patches = (prev.patches or []) ++ [./curl-symbol-downgrade.patch]; } ); + + mainProgram = + if system == "x86_64-linux" + then "srcds_run_64" + else "srcds_run"; in stdenvNoCC.mkDerivation { pname = "srcds-tf2"; @@ -82,10 +87,17 @@ in echo 440 > $out/steam_appid.txt + mkdir -p $out/bin + + echo "#! /bin/sh" > $out/bin/${mainProgram} + echo "exec $out/${mainProgram} "'$@' >> $out/bin/${mainProgram} + chmod +x $out/bin/${mainProgram} + runHook postInstall ''; meta = with lib; { + inherit mainProgram; description = "TF2 dedicated server"; homepage = "https://steamdb.info/app/440/"; changelog = "https://store.steampowered.com/news/app/440?updates=true";