From e39d617e4dcb455b90b6be3dbb24ef60616ef705 Mon Sep 17 00:00:00 2001 From: Pravdyvy Date: Fri, 12 Jun 2026 18:53:53 +0300 Subject: [PATCH] fix(nix): last try --- flake.lock | 16 ++++++++-------- flake.nix | 14 +++++++++----- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/flake.lock b/flake.lock index ea0c5a43..3193158d 100644 --- a/flake.lock +++ b/flake.lock @@ -20,17 +20,17 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1779701503, - "narHash": "sha256-Cq+R9/cs2Nv/5q8NSH2tgNwQAiOuZK80nEhNMK0jShw=", + "lastModified": 1775835011, + "narHash": "sha256-SQDLyyRUa5J9QHjNiHbeZw4rQOZnTEo61TcaUpjtLBs=", "owner": "logos-blockchain", "repo": "logos-blockchain-circuits", - "rev": "2e79ac30831d89e6a349720c08d5b8b9978970e0", + "rev": "d6cf41f66500d4afc157b4f43de0f0d5bfa01443", "type": "github" }, "original": { "owner": "logos-blockchain", "repo": "logos-blockchain-circuits", - "rev": "2e79ac30831d89e6a349720c08d5b8b9978970e0", + "rev": "d6cf41f66500d4afc157b4f43de0f0d5bfa01443", "type": "github" } }, @@ -6352,16 +6352,16 @@ }, "nixpkgs": { "locked": { - "lastModified": 1767313136, - "narHash": "sha256-16KkgfdYqjaeRGBaYsNrhPRRENs0qzkQVUooNHtoy2w=", + "lastModified": 1769461804, + "narHash": "sha256-msG8SU5WsBUfVVa/9RPLaymvi5bI8edTavbIq3vRlhI=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d", + "rev": "bfc1b8a4574108ceef22f02bafcf6611380c100d", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-25.05", + "ref": "nixos-unstable", "repo": "nixpkgs", "type": "github" } diff --git a/flake.nix b/flake.nix index 50072478..8f54846a 100644 --- a/flake.nix +++ b/flake.nix @@ -14,7 +14,7 @@ crane.url = "github:ipetkov/crane"; logos-blockchain-circuits = { - url = "github:logos-blockchain/logos-blockchain-circuits?rev=2e79ac30831d89e6a349720c08d5b8b9978970e0"; + url = "github:logos-blockchain/logos-blockchain-circuits/d6cf41f66500d4afc157b4f43de0f0d5bfa01443"; }; }; @@ -53,6 +53,7 @@ craneLib = (crane.mkLib pkgs).overrideToolchain rustToolchain; src = ./.; cargoLock = builtins.fromTOML (builtins.readFile ./Cargo.lock); + lbc_dir = logos-blockchain-circuits.packages.${system}.default; # Parse Cargo.lock at eval time to find the locked risc0-circuit-recursion # version and its crates.io checksum — no hardcoding required. @@ -101,9 +102,13 @@ pkgs.gnutar # Required for crane's archive operations (macOS tar lacks --sort) pkgs.python3 # Required for correct builds now, as python is sandboxed in nix builds ]; - LIBCLANG_PATH = "${pkgs.llvmPackages.libclang.lib}/lib"; - + LBC_LIB_DIR = "${lbc_dir}"; + LOGOS_BLOCKCHAIN_CIRCUITS = "${lbc_dir}"; + LBC_POC_LIB_DIR = "${lbc_dir}/poc"; + LBC_POL_LIB_DIR = "${lbc_dir}/pol"; + LBC_POQ_LIB_DIR = "${lbc_dir}/poq"; + LBC_SIGNATURE_LIB_DIR = "${lbc_dir}/zksign"; # Point the risc0-circuit-recursion build script to the pre-fetched zip # so it doesn't try to download it inside the sandbox. RECURSION_SRC_PATH = "${recursionZkr}"; @@ -117,7 +122,6 @@ '' + pkgs.lib.optionalString pkgs.stdenv.isDarwin '' export PATH="$PATH:/usr/bin" ''; - LOGOS_BLOCKCHAIN_CIRCUITS = logos-blockchain-circuits.packages.${system}.default; }; walletFfiPackage = craneLib.buildPackage ( @@ -144,7 +148,7 @@ cargoExtraArgs = "-p indexer_ffi"; postInstall = '' mkdir -p $out/include - cp indexer/ffi/indexer_ffi.h $out/include/ + cp lez/indexer/ffi/indexer_ffi.h $out/include/ '' + pkgs.lib.optionalString pkgs.stdenv.isDarwin '' install_name_tool -id @rpath/libindexer_ffi.dylib $out/lib/libindexer_ffi.dylib