Skip to content

Commit

Permalink
remove solana-sdk from address-lookup-table-program
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinheavey committed Jan 4, 2025
1 parent c80196f commit 01fc970
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 19 deletions.
8 changes: 7 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 7 additions & 1 deletion programs/address-lookup-table/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,15 @@ solana-program = { workspace = true }
thiserror = { workspace = true }

[target.'cfg(not(target_os = "solana"))'.dependencies]
solana-bincode = { workspace = true }
solana-clock = { workspace = true }
solana-instruction = { workspace = true }
solana-log-collector = { workspace = true }
solana-packet = { workspace = true }
solana-program-runtime = { workspace = true }
solana-sdk = { workspace = true }
solana-pubkey = { workspace = true }
solana-system-interface = { workspace = true }
solana-transaction-context = { workspace = true, features = ["bincode"] }

[lib]
crate-type = ["lib"]
Expand Down
28 changes: 13 additions & 15 deletions programs/address-lookup-table/src/processor.rs
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
use {
solana_bincode::limited_deserialize,
solana_clock::Slot,
solana_instruction::error::InstructionError,
solana_log_collector::ic_msg,
solana_program_runtime::{declare_process_instruction, invoke_context::InvokeContext},
solana_sdk::{
address_lookup_table::{
instruction::ProgramInstruction,
program::{check_id, id},
state::{
AddressLookupTable, LookupTableMeta, LookupTableStatus, ProgramState,
LOOKUP_TABLE_MAX_ADDRESSES, LOOKUP_TABLE_META_SIZE,
},
solana_program::address_lookup_table::{
instruction::ProgramInstruction,
program::{check_id, id},
state::{
AddressLookupTable, LookupTableMeta, LookupTableStatus, ProgramState,
LOOKUP_TABLE_MAX_ADDRESSES, LOOKUP_TABLE_META_SIZE,
},
clock::Slot,
instruction::InstructionError,
program_utils::limited_deserialize,
pubkey::{Pubkey, PUBKEY_BYTES},
system_instruction,
},
solana_program_runtime::{declare_process_instruction, invoke_context::InvokeContext},
solana_pubkey::{Pubkey, PUBKEY_BYTES},
solana_system_interface::instruction as system_instruction,
std::convert::TryFrom,
};

Expand All @@ -25,7 +23,7 @@ declare_process_instruction!(Entrypoint, DEFAULT_COMPUTE_UNITS, |invoke_context|
let transaction_context = &invoke_context.transaction_context;
let instruction_context = transaction_context.get_current_instruction_context()?;
let instruction_data = instruction_context.get_instruction_data();
match limited_deserialize(instruction_data)? {
match limited_deserialize(instruction_data, solana_packet::PACKET_DATA_SIZE as u64)? {
ProgramInstruction::CreateLookupTable {
recent_slot,
bump_seed,
Expand Down
8 changes: 7 additions & 1 deletion programs/sbf/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 7 additions & 1 deletion svm/examples/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 01fc970

Please sign in to comment.