diff --git a/hosts/europa/default.nix b/hosts/europa/default.nix index 5487564..f01475b 100644 --- a/hosts/europa/default.nix +++ b/hosts/europa/default.nix @@ -204,6 +204,7 @@ in { unzip virt-manager yt-dlp + zig ]; system.stateVersion = "21.11"; diff --git a/overlays/default.nix b/overlays/default.nix index 9f26224..9726a9a 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -2,6 +2,32 @@ { nixpkgs.overlays = if isUnstable then [ + (self: super: { + zig = super.zig.overrideAttrs (old: { + version = "0.10.0-dev.35e0ff7"; + src = super.fetchFromGitHub { + owner = "ziglang"; + repo = "zig"; + rev = "35e0ff7c364487152d786347cf70f47b2a390f12"; + hash = "sha256-S6m0TrE+Ecm9yBJHgTZRMcKr0W0SoSZYX2CB+5gUSAY="; + }; + + patches = [ ]; + + nativeBuildInputs = with pkgs; [ cmake llvmPackages_14.llvm.dev ]; + + buildInputs = with pkgs; + [ libxml2 zlib ] ++ (with llvmPackages_14; [ libclang lld llvm ]); + + checkPhase = '' + runHook preCheck + ls -lart + ./zig2 test --cache-dir "$TMPDIR" -I $src/test $src/test/behavior.zig + runHook postCheck + ''; + }); + }) + # https://github.com/NixOS/nixpkgs/pull/186130 (self: super: { tidal-hifi = super.tidal-hifi.overrideAttrs (old: {