diff options
| author | Sam Estep <sam@samestep.com> | 2025-07-23 21:34:21 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-24 01:34:21 +0000 |
| commit | 9666fbcab891156fb058d6a1b8f427ccc3ffecab (patch) | |
| tree | 626de80431a8ee43319f99e128f6144331b9f9a6 /flake.nix | |
| parent | 559c8307d7537319c9f2b3f3d386d8b9b147aba3 (diff) | |
Document how to use LLDB in the Slang codebase (#7809)
* Document how to use LLDB in the Slang codebase
* Include `slang_lldb.py` in `.lldbinit`
* Switch from GCC to Clang
* Include a VS Code task to build before debugging
* Fix clangd
Diffstat (limited to 'flake.nix')
| -rw-r--r-- | flake.nix | 14 |
1 files changed, 11 insertions, 3 deletions
@@ -16,12 +16,20 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + # We want to use Clang instead of GCC because it seems to behave better + # with LLDB, so we use `mkShellNoCC` here instead of `mkShell` because + # the latter brings in GCC by default on Linux. + devShell = pkgs.mkShellNoCC { buildInputs = [ + # Must put `clang-tools` before `clang` for clangd to work properly. + # We use `llvmPackages_17.clang-tools` instead of just `clang-tools` + # to match the `clang-format` version used in CI. + pkgs.llvmPackages_17.clang-tools + + pkgs.clang pkgs.cmake pkgs.gersemi - pkgs.llvm - pkgs.llvmPackages_17.clang-tools + pkgs.lldb pkgs.ninja pkgs.nixfmt-rfc-style pkgs.prettier |
