Skip to content

Commit 00bd0df

Browse files
committed
fix stellar rust build
1 parent 5de3d7c commit 00bd0df

File tree

2 files changed

+14
-7
lines changed

2 files changed

+14
-7
lines changed

flake.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
stellar-cli-flake.url = "github:stellar/stellar-cli";
3434
stellar-cli-flake.inputs = {
3535
flake-utils.follows = "flake-utils";
36-
nixpkgs.follows = "nixpkgs-unstable";
36+
nixpkgs.follows = "nixpkgs";
3737
rust-overlay.follows = "rust-overlay";
3838
};
3939
};
@@ -85,10 +85,17 @@
8585
# with a `pkgconfig` directory such as the `openssl` derivation
8686
# this will then setup the `PKG_CONFIG_PATH` env variable properly
8787
stellar-cli-overlay = final: prev: {
88-
stellar-cli = stellar-cli-flake.packages.${system}.default.overrideAttrs (finalAttrs: previousAttrs: {
89-
nativeBuildInputs = (previousAttrs.nativeBuildInputs or [ ]) ++ (with final; [
88+
stellar-cli = stellar-cli-flake.packages.${system}.default.overrideAttrs (finalAttrs: previousAttrs:
89+
let
90+
nativeBuildInputs' = (previousAttrs.nativeBuildInputs or [ ]) ++ (with final; [
9091
pkg-config
9192
]);
93+
in {
94+
# remove `auditable since it expects rust 2024, but cannot find it
95+
# this is usually disable by passing `auditable = false;` to `buildRustPackage`
96+
# however, nixpkgs does not let us properly override this post-morted, so we have to remove the auditable package
97+
# that inevitably got add in `stellar-cli` flake
98+
nativeBuildInputs = builtins.filter (pkg: !final.lib.strings.hasPrefix "auditable-" pkg.name) nativeBuildInputs';
9299
buildInputs = (previousAttrs.buildInputs or [ ]) ++ (with final; [
93100
openssl
94101
]);

0 commit comments

Comments
 (0)