···44, rustPlatform
55, openssl
66, zlib
77+, zstd
78, pkg-config
89, python3
910, xorg
···17181819rustPlatform.buildRustPackage rec {
1920 pname = "nushell";
2020- version = "0.33.0";
2121+ version = "0.35.0";
21222223 src = fetchFromGitHub {
2324 owner = pname;
2425 repo = pname;
2526 rev = version;
2626- sha256 = "sha256-Asjm3IoAfzphITLQuNh6r/i/pjEM/A+wpCsAB83bu2U=";
2727+ sha256 = "0p5whwx6wk9k7mrxhr7azrppbj9mv53hd4bl1cgygxz231aq8337";
2728 };
28292929- cargoSha256 = "sha256-Ly59mdUzSI2pIPbckWn1WBz/o2zVzpAzaCDROLdjG7Y=";
3030+ cargoSha256 = "0xs0s02zf78pgd94ifh465mg14rrwjfg7qbzmmq8jha758gfwdi3";
30313132 nativeBuildInputs = [ pkg-config ]
3233 ++ lib.optionals (withExtraFeatures && stdenv.isLinux) [ python3 ];
33343434- buildInputs = [ openssl ]
3535+ buildInputs = [ openssl zstd ]
3536 ++ lib.optionals stdenv.isDarwin [ zlib libiconv Security ]
3637 ++ lib.optionals (withExtraFeatures && stdenv.isLinux) [ xorg.libX11 ]
3738 ++ lib.optionals (withExtraFeatures && stdenv.isDarwin) [ AppKit nghttp2 libgit2 ];
38393940 cargoBuildFlags = lib.optional withExtraFeatures "--features=extra";
4141+4242+ # Since 0.34, nu has an indirect dependency on `zstd-sys` (via `polars` and
4343+ # `parquet`, for dataframe support), which by default has an impure build
4444+ # (git submodule for the `zstd` C library). The `pkg-config` feature flag
4545+ # fixes this, but it's hard to invoke this in the right place, because of
4646+ # the indirect dependencies. So add a direct dependency on `zstd-sys` here
4747+ # at the top level, along with this feature flag, to ensure that when
4848+ # `zstd-sys` is transitively invoked, it triggers a pure build using the
4949+ # system `zstd` library provided above.
5050+ #
5151+ # (If this patch needs updating, in a nushell repo add the zstd-sys line to
5252+ # Cargo.toml, then `cargo update --package zstd-sys` to update Cargo.lock.)
5353+ cargoPatches = [ ./use-system-zstd-lib.diff ];
40544155 # TODO investigate why tests are broken on darwin
4256 # failures show that tests try to write to paths