Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't compile raydium-amm when using as dependency #27

Open
liewhite opened this issue Nov 30, 2024 · 4 comments
Open

Can't compile raydium-amm when using as dependency #27

liewhite opened this issue Nov 30, 2024 · 4 comments

Comments

@liewhite
Copy link

Compile error like this:

program_id == &spl_memo::id() || program_id == &spl_memo::v1::id()
   |                    ^^ no implementation for `solana_program::pubkey::Pubkey == spl_memo::solana_program::solana_pubkey::Pubkey`
@RainRaydium
Copy link
Contributor

RainRaydium commented Dec 2, 2024

You can specify dependencies using like:
spl-token = { version = "=4.0.0", features = ["no-entrypoint"] } spl-associated-token-account = { version = "=2.2.0", features = [ "no-entrypoint", ] }

@ivanglushko
Copy link

ivanglushko commented Dec 6, 2024

Got the same error.

Compiling spl-token-2022 v0.9.0
error[E0277]: can't compare `solana_program::pubkey::Pubkey` with `spl_memo::solana_program::solana_pubkey::Pubkey`
  --> /Users/ivan/.cargo/registry/src/index.crates.io-6f17d22bba15001f/spl-token-2022-0.9.0/src/extension/memo_transfer/mod.rs:42:20
   |
42 |         program_id == &spl_memo::id() || program_id == &spl_memo::v1::id()
   |                    ^^ no implementation for `solana_program::pubkey::Pubkey == spl_memo::solana_program::solana_pubkey::Pubkey`

I believe it's cause of dependencies version mismatch.
Please @RainRaydium check the Readme.md guide and try to use those versions
This is my Cargo.toml

[dependencies]
amm-cli = { git = "https://github.com/raydium-io/raydium-library" }
common = { git = "https://github.com/raydium-io/raydium-library" }
spl-token = { version = "4.0.0", features = ["no-entrypoint"] }
spl-associated-token-account = { version = "2.2.0", features = ["no-entrypoint"] }
spl-token-2022 = { version = "0.9.0", features = ["no-entrypoint"] }
solana-client = "<1.17.0"
solana-sdk = "<1.17.0"
anyhow = "1.0.53"
clap = { version = "4.1.8", features = ["derive"] }

@v0idum
Copy link

v0idum commented Dec 11, 2024

Got the same error even though i'm using the same Cargo.toml from the Readme

@Smart1442
Copy link

#27 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants