A cross-platform simulator for the GreenArrays GA144 multi-computer chip.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

add nix flake dev shell for Zig

Kent Smith 4c340010 b5b2e960

+282
+7
.envrc
··· 1 + if ! has nix_direnv_version || ! nix_direnv_version 3.0.6; then 2 + source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/3.0.6/direnvrc" "sha256-RYcUJaRMf8oF5LznDrlCXbkOQrywm0HDv1VjYGaJGdM=" 3 + fi 4 + 5 + use flake 6 + 7 + nix_direnv_manual_reload
+2
.gitignore
··· 1 + # Nix 2 + .direnv
+230
flake.lock
··· 1 + { 2 + "nodes": { 3 + "flake-compat": { 4 + "flake": false, 5 + "locked": { 6 + "lastModified": 1696426674, 7 + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", 8 + "owner": "edolstra", 9 + "repo": "flake-compat", 10 + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", 11 + "type": "github" 12 + }, 13 + "original": { 14 + "owner": "edolstra", 15 + "repo": "flake-compat", 16 + "type": "github" 17 + } 18 + }, 19 + "flake-compat_2": { 20 + "flake": false, 21 + "locked": { 22 + "lastModified": 1696426674, 23 + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", 24 + "owner": "edolstra", 25 + "repo": "flake-compat", 26 + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", 27 + "type": "github" 28 + }, 29 + "original": { 30 + "owner": "edolstra", 31 + "repo": "flake-compat", 32 + "type": "github" 33 + } 34 + }, 35 + "flake-utils": { 36 + "inputs": { 37 + "systems": "systems" 38 + }, 39 + "locked": { 40 + "lastModified": 1705309234, 41 + "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", 42 + "owner": "numtide", 43 + "repo": "flake-utils", 44 + "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", 45 + "type": "github" 46 + }, 47 + "original": { 48 + "owner": "numtide", 49 + "repo": "flake-utils", 50 + "type": "github" 51 + } 52 + }, 53 + "flake-utils_2": { 54 + "inputs": { 55 + "systems": "systems_2" 56 + }, 57 + "locked": { 58 + "lastModified": 1705309234, 59 + "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", 60 + "owner": "numtide", 61 + "repo": "flake-utils", 62 + "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", 63 + "type": "github" 64 + }, 65 + "original": { 66 + "owner": "numtide", 67 + "repo": "flake-utils", 68 + "type": "github" 69 + } 70 + }, 71 + "gitignore": { 72 + "inputs": { 73 + "nixpkgs": [ 74 + "zls-pkg", 75 + "nixpkgs" 76 + ] 77 + }, 78 + "locked": { 79 + "lastModified": 1709087332, 80 + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", 81 + "owner": "hercules-ci", 82 + "repo": "gitignore.nix", 83 + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", 84 + "type": "github" 85 + }, 86 + "original": { 87 + "owner": "hercules-ci", 88 + "repo": "gitignore.nix", 89 + "type": "github" 90 + } 91 + }, 92 + "nixpkgs": { 93 + "locked": { 94 + "lastModified": 1741550880, 95 + "narHash": "sha256-XfEc9v7BQWzMFIk9RLTGyWxrl0EKz3fPsG5kga2E8YU=", 96 + "owner": "nixos", 97 + "repo": "nixpkgs", 98 + "rev": "5f30dc85946066641b0520641c5fb807af6a7c03", 99 + "type": "github" 100 + }, 101 + "original": { 102 + "owner": "nixos", 103 + "ref": "release-24.11", 104 + "repo": "nixpkgs", 105 + "type": "github" 106 + } 107 + }, 108 + "nixpkgs_2": { 109 + "locked": { 110 + "lastModified": 1741196730, 111 + "narHash": "sha256-0Sj6ZKjCpQMfWnN0NURqRCQn2ob7YtXTAOTwCuz7fkA=", 112 + "owner": "NixOS", 113 + "repo": "nixpkgs", 114 + "rev": "48913d8f9127ea6530a2a2f1bd4daa1b8685d8a3", 115 + "type": "github" 116 + }, 117 + "original": { 118 + "owner": "NixOS", 119 + "ref": "nixos-24.11", 120 + "repo": "nixpkgs", 121 + "type": "github" 122 + } 123 + }, 124 + "root": { 125 + "inputs": { 126 + "nixpkgs": "nixpkgs", 127 + "zig-overlay": "zig-overlay", 128 + "zls-pkg": "zls-pkg" 129 + } 130 + }, 131 + "systems": { 132 + "locked": { 133 + "lastModified": 1681028828, 134 + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 135 + "owner": "nix-systems", 136 + "repo": "default", 137 + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 138 + "type": "github" 139 + }, 140 + "original": { 141 + "owner": "nix-systems", 142 + "repo": "default", 143 + "type": "github" 144 + } 145 + }, 146 + "systems_2": { 147 + "locked": { 148 + "lastModified": 1681028828, 149 + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", 150 + "owner": "nix-systems", 151 + "repo": "default", 152 + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", 153 + "type": "github" 154 + }, 155 + "original": { 156 + "owner": "nix-systems", 157 + "repo": "default", 158 + "type": "github" 159 + } 160 + }, 161 + "zig-overlay": { 162 + "inputs": { 163 + "flake-compat": "flake-compat", 164 + "flake-utils": "flake-utils", 165 + "nixpkgs": [ 166 + "nixpkgs" 167 + ] 168 + }, 169 + "locked": { 170 + "lastModified": 1741522135, 171 + "narHash": "sha256-28WtUALoateXrfh8z91F6Ub0Q8Ax58LUAZM2tS8pA7s=", 172 + "owner": "mitchellh", 173 + "repo": "zig-overlay", 174 + "rev": "ce940be092e6813531a90f1c537ec98d7cb4d471", 175 + "type": "github" 176 + }, 177 + "original": { 178 + "owner": "mitchellh", 179 + "repo": "zig-overlay", 180 + "type": "github" 181 + } 182 + }, 183 + "zig-overlay_2": { 184 + "inputs": { 185 + "flake-compat": "flake-compat_2", 186 + "flake-utils": "flake-utils_2", 187 + "nixpkgs": [ 188 + "zls-pkg", 189 + "nixpkgs" 190 + ] 191 + }, 192 + "locked": { 193 + "lastModified": 1741263138, 194 + "narHash": "sha256-qlX8tgtZMTSOEeAM8AmC7K6mixgYOguhl/xLj5xQrXc=", 195 + "owner": "mitchellh", 196 + "repo": "zig-overlay", 197 + "rev": "627055069ee1409e8c9be7bcc533e8823fb87b18", 198 + "type": "github" 199 + }, 200 + "original": { 201 + "owner": "mitchellh", 202 + "repo": "zig-overlay", 203 + "type": "github" 204 + } 205 + }, 206 + "zls-pkg": { 207 + "inputs": { 208 + "gitignore": "gitignore", 209 + "nixpkgs": "nixpkgs_2", 210 + "zig-overlay": "zig-overlay_2" 211 + }, 212 + "locked": { 213 + "lastModified": 1741303397, 214 + "narHash": "sha256-A5Mn+mfIefOsX+eNBRHrDVkqFDVrD3iXDNsUL4TPhKo=", 215 + "owner": "zigtools", 216 + "repo": "zls", 217 + "rev": "7485feeeda45d1ad09422ae83af73307ab9e6c9e", 218 + "type": "github" 219 + }, 220 + "original": { 221 + "owner": "zigtools", 222 + "ref": "0.14.0", 223 + "repo": "zls", 224 + "type": "github" 225 + } 226 + } 227 + }, 228 + "root": "root", 229 + "version": 7 230 + }
+43
flake.nix
··· 1 + { 2 + description = "A simulator for the GA144 multi-computer"; 3 + 4 + inputs = { 5 + # We want to stay as up to date as possible but need to be careful that the 6 + # glibc versions used by our dependencies from Nix are compatible with the 7 + # system glibc that the user is building for. 8 + nixpkgs.url = "github:nixos/nixpkgs/release-24.11"; 9 + 10 + zig-overlay = { 11 + url = "github:mitchellh/zig-overlay"; 12 + inputs.nixpkgs.follows = "nixpkgs"; 13 + }; 14 + 15 + zls-pkg.url = "github:zigtools/zls?ref=0.14.0"; 16 + }; 17 + 18 + outputs = { 19 + nixpkgs, 20 + zig-overlay, 21 + zls-pkg, 22 + ... 23 + }: 24 + builtins.foldl' nixpkgs.lib.recursiveUpdate {} ( 25 + builtins.map ( 26 + system: let 27 + pkgs = nixpkgs.legacyPackages.${system}; 28 + zig = zig-overlay.packages.${system}."0.14.0"; 29 + zls = zls-pkg.packages.${system}.default; 30 + in { 31 + devShells.${system}.default = pkgs.mkShell { 32 + nativeBuildInputs = [ 33 + zig 34 + zls 35 + ]; 36 + }; 37 + 38 + formatter.${system} = pkgs.alejandra; 39 + } 40 + # Our supported systems are the same supported systems as the Zig binaries. 41 + ) (builtins.attrNames zig-overlay.packages) 42 + ); 43 + }