X-Git-Url: http://git.xonotic.org/?p=xonotic%2Fxonotic.git;a=blobdiff_plain;f=default.nix;h=fe38854085cb4a93fca063c9deb240d81809d932;hp=9e8c87e4a963d3f010235cd1ec401d92381eab30;hb=0252169d81ea543adbd91036b738790a9075a069;hpb=9d2e0f613a2eb1861bab8b8485516f707d94ed8c diff --git a/default.nix b/default.nix index 9e8c87e4..fe388540 100644 --- a/default.nix +++ b/default.nix @@ -1,11 +1,14 @@ # nix-shell -A xonotic +# --argstr cc clang { nixpkgs ? , - pkgs ? (import nixpkgs) {} + pkgs ? (import nixpkgs) {}, + cc ? null, }: with pkgs; let VERSION = "0.8.2"; + stdenv = if (cc != null) then overrideCC pkgs.stdenv pkgs."${cc}" else pkgs.stdenv; targets = rec { xonotic = stdenv.mkDerivation rec { name = "xonotic-${version}"; @@ -121,6 +124,7 @@ let ncurses libjpeg libpng + minizip mesa