{ description = "pedagogical compiler monorepo (bazel + nix + clang + ccache)"; inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; flake-utils.url = "github:numtide/flake-utils"; }; outputs = { self, nixpkgs, flake-utils, ... }: flake-utils.lib.eachDefaultSystem ( system: let # pkgs = import nixpkgs { inherit system; config.replaceStdenv = {pkgs, ...}: pkgs.clangStdenv; }; pkgs = import nixpkgs { inherit system; }; # lock = builtins.fromJSON (builtins.readFile ./flake.lock); # spec = lock.nodes.nixpkgs.locked; # nixpkgs = fetchTarball "https://github.com/${spec.owner}/${spec.repo}/archive/${spec.rev}.tar.gz"; in { devShells.default = pkgs.mkShell { name = "compiler stuff"; packages = with pkgs; [ # clang-tools # bazelisk bazel_8 bazel-buildtools nix git gcc graphviz doxygen ccache python3 ninja clang-tools clang z3 catch2_3 pkg-config lit buildifier buildozer ]; CC = "ccache clang"; CXX = "ccache clang++"; # LD_LIBRARY_PATH = nixpkgs.lib.makeLibraryPath [ pkgs.libcxx ]; NIX_HARDENING_ENABLE = ""; }; } ); }