From e93725e78862e88ca4ac5065470906ac27af45fd Mon Sep 17 00:00:00 2001 From: Tyera Date: Tue, 7 Nov 2023 13:30:10 -0700 Subject: [PATCH] Add more comments about solana-program patch (downstream) (#33965) * Add more comments re solana-program patch * More specific advice --- Cargo.toml | 7 +++++++ programs/sbf/Cargo.toml | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 8e85b5144..d68391858 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -451,6 +451,13 @@ crossbeam-epoch = { git = "https://github.com/solana-labs/crossbeam", rev = "fd2 # and we end up with two versions of `solana-program` and `solana-zk-token-sdk` and all of their # dependencies in our build tree. # +# If you are developing downstream using non-crates-io solana-program (local or +# forked repo, or from github rev, eg), duplicate the following patch statements +# in your Cargo.toml. If you still hit duplicate-type errors with the patch +# statements in place, run `cargo update -p solana-program` and/or `cargo update +# -p solana-zk-token-sdk` to remove extraneous versions from your Cargo.lock +# file. +# # There is a similar override in `programs/sbf/Cargo.toml`. Please keep both comments and the # overrides in sync. solana-program = { path = "sdk/program" } diff --git a/programs/sbf/Cargo.toml b/programs/sbf/Cargo.toml index 6f069a3f5..7ab496de8 100644 --- a/programs/sbf/Cargo.toml +++ b/programs/sbf/Cargo.toml @@ -196,6 +196,13 @@ targets = ["x86_64-unknown-linux-gnu"] # and we end up with two versions of `solana-program` and `solana-zk-token-sdk` and all of their # dependencies in our build tree. # +# If you are developing downstream using non-crates-io solana-program (local or +# forked repo, or from github rev, eg), duplicate the following patch statements +# in your Cargo.toml. If you still hit duplicate-type errors with the patch +# statements in place, run `cargo update -p solana-program` and/or `cargo update +# -p solana-zk-token-sdk` to remove extraneous versions from your Cargo.lock +# file. +# # There is a similar override in `../../Cargo.toml`. Please keep both comments and the # overrides in sync. solana-program = { path = "../../sdk/program" }