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 build hello world example using solido repo as external repo #557

Closed
kkonevets opened this issue Apr 12, 2022 · 2 comments
Closed

Comments

@kkonevets
Copy link
Collaborator

kkonevets commented Apr 12, 2022

Can't build hello world example using solido repo as external repo https://github.com/kkonevets/solexamp
It uses latest solana-program-1.10.8 instead of solana-program-1.7.8 from your patch. Specifying dependencies does not help

image

[Update]
My original Cargo.toml was:

[package]
name = "solexamp"
version = "0.1.0"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[patch.crates-io]
solana-program = { git = "https://github.com/ChorusOne/solana", branch = "program-test-178" }

[dependencies]
lido = { git = "https://github.com/ChorusOne/solido", rev = "bdfdbc677d9ff33f4e12cd01d9c1f24c31b30ae7" }
solana-program = "1.7.8"

So, delete Cargo.lock, add solana-program dependency with = sign ("=1.7.8") and it will compile

@ruuda
Copy link
Contributor

ruuda commented Apr 12, 2022

As discussed elsewhere, adding this to your Cargo.toml will help:

[dependencies]
solana-sdk = "=1.7.8"
solana-program = "=1.7.8"
solana-program-test = "=1.7.8"
solana-frozen-abi = "=1.7.8"
solana-frozen-abi-macro = "=1.7.8"

The reason we still use solana-sdk 1.7.8 is because Anchor framework (the eDSL) has a dependency on =1.7.8 (it doesn’t allow newer versions), and the multisig program uses Anchor framwork, and the CLI tool depends on that to build transactions ...

@ruuda ruuda closed this as completed Apr 12, 2022
@kkonevets
Copy link
Collaborator Author

kkonevets commented Apr 12, 2022

The actual reason my initial Cargo.toml did not compile was that I didn't prefix version with = like in =1.7.8

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

2 participants