Skip to content

Commit

Permalink
Use aya from git
Browse files Browse the repository at this point in the history
Signed-off-by: Sean Young <[email protected]>
  • Loading branch information
seanyoung committed May 11, 2024
1 parent 352d3df commit 1858e06
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ log = "0.4"
peg = "0.8"

[target.'cfg(target_os = "linux")'.dependencies]
aya = "0.12"
aya = { git = "https://github.com/aya-rs/aya.git" }
irp = { version = "0.3.3", path = "irp", features = [ "bpf" ] }

[target.'cfg(not(target_os = "linux"))'.dependencies]
Expand Down
2 changes: 1 addition & 1 deletion irp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ bpf = [ "inkwell" ]
cir = { path = ".." }
rand = "0.8"
irptransmogrifier = { path = "tests/rust-irptransmogrifier" }
aya-obj = "0.1"
aya-obj = { version = "0.1", features = [ "std" ] }
rbpf = "0.2"
4 changes: 2 additions & 2 deletions src/lirc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
use aya::{
programs::{Link, LircMode2, ProgramError},
Bpf,
Ebpf,
};
use num_integer::Integer;
use std::{
Expand Down Expand Up @@ -466,7 +466,7 @@ impl Lirc {
/// Load and attach bpf program. The bpf program should a valid ELF object file,
/// which contains a single LircMode2 program.
pub fn attach_bpf(&self, bpf: &[u8]) -> Result<(), String> {
let mut bpf = match Bpf::load(bpf) {
let mut bpf = match Ebpf::load(bpf) {
Ok(bpf) => bpf,
Err(e) => {
return Err(format!("{e}"));
Expand Down

0 comments on commit 1858e06

Please sign in to comment.