You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Any crate which wants to use Solana syscalls need to depend on the entire solana-program crate. This pulls in a lot of dependencies which is undesired for utility crates.
For a concrete example, I’m trying to modify ibc-rs to support Solana’s syscall for calculating SHA 256 but it doesn’t work out as easily as it could. In particular, I’m at the moment facing issues with zeroize dependency resolution.
Proposed Solution
Provide a solana-program-syscalls crate which exposes contents of the solana_program::syscalls module. solana-program crate would than depend on that new crate and simply include pub use solana_program_syscalls as syscalls; statement.
This would be mostly a trivial change except that some of the syscalls depend on data types such as Pubkey. Those would need to be included in that crate.
The text was updated successfully, but these errors were encountered:
Problem
Any crate which wants to use Solana syscalls need to depend on the entire solana-program crate. This pulls in a lot of dependencies which is undesired for utility crates.
For a concrete example, I’m trying to modify ibc-rs to support Solana’s syscall for calculating SHA 256 but it doesn’t work out as easily as it could. In particular, I’m at the moment facing issues with zeroize dependency resolution.
Proposed Solution
Provide a
solana-program-syscalls
crate which exposes contents of thesolana_program::syscalls
module.solana-program
crate would than depend on that new crate and simply includepub use solana_program_syscalls as syscalls;
statement.This would be mostly a trivial change except that some of the syscalls depend on data types such as Pubkey. Those would need to be included in that crate.
The text was updated successfully, but these errors were encountered: