Cargo Features
[dependencies]
solana-sdk = { version = "2.2.1", default-features = false, features = ["program", "full", "borsh", "dev-context-only-utils", "frozen-abi", "openssl-vendored"] }
- program
-
"program" feature is a legacy feature retained to support v1.3 and older
programs. New development should not use this feature. Instead use the solana-program crate - default = borsh, full
-
These default features are set whenever
solana-sdk
is added without
somewhere in the dependency tree.default-features = false - full default = serde_json, solana-signature
-
Enables solana-transaction-error, solana-quic-definitions, solana-rent-collector, solana-secp256k1-program, solana-seed-derivable, solana-seed-phrase, solana-shred-version, solana-signer, solana-system-transaction, and solana-transaction, solana-client-traits, solana-cluster-type, solana-commitment-config, solana-compute-budget-interface, solana-ed25519-program, solana-genesis-config, solana-hard-forks, solana-keypair, solana-offchain-message, solana-precompile-error, solana-precompiles, and solana-presigner, rand of solana-pubkey, debug-signature of solana-transaction-context
Affects
pubkey::write_pubkey_file
,pubkey::read_pubkey_file
… - borsh default
-
Enables borsh of solana-compute-budget-interface, solana-program, and solana-secp256k1-recover
- dev-context-only-utils
-
Enables dev-context-only-utils of solana-account, solana-compute-budget-interface, solana-rent-debits, solana-transaction, and solana-transaction-context
- frozen-abi
-
Enables frozen-abi of solana-account, solana-cluster-type, solana-feature-set, solana-fee-structure, solana-genesis-config, solana-hard-forks, solana-inflation, solana-packet, solana-poh-config, solana-program, solana-rent-collector, solana-reward-info, solana-short-vec, solana-signature, solana-transaction, and solana-transaction-error
- openssl-vendored
-
Enables the "vendored" feature of openssl inside of secp256r1-program
Enables openssl-vendored of solana-precompiles
Features from optional dependencies
In crates that don't use the dep:
syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.