add support for bcc 0.20.0 (#184)

Adds support for bcc 0.20.0
This commit is contained in:
Brian Martin 2021-11-23 08:18:07 -08:00 committed by GitHub
parent 435833dd53
commit b6e987446e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 38 additions and 1 deletions

View File

@ -156,6 +156,25 @@ jobs:
key: ${{ env.DIST }}-${{ env.LLVM }}-${{ env.BCC }}
- name: Run CI
run: bash -e build/ci.sh
focal-llvm_9-bcc_v0_20_0:
name: focal / llvm 9 / bcc 0.20.0
runs-on: ubuntu-20.04
env:
BCC: "0.20.0"
DIST: focal
FEATURES: v0_20_0
LLVM: "9"
STATIC: true
steps:
- uses: actions/checkout@v2
- name: BCC Build Cache
uses: actions/cache@v2
with:
path: |
deps
key: ${{ env.DIST }}-${{ env.LLVM }}-${{ env.BCC }}
- name: Run CI
run: bash -e build/ci.sh
rustfmt:
runs-on: ubuntu-latest
steps:

View File

@ -12,7 +12,7 @@ homepage = "https://github.com/rust-bpf/rust-bcc"
edition = '2018'
[dependencies]
bcc-sys = "0.19.1"
bcc-sys = "0.20.0"
byteorder = "1.4.3"
libc = "0.2.108"
thiserror = "1.0.30"
@ -46,3 +46,4 @@ v0_16_0 = ["bcc-sys/v0_16_0", "specific"]
v0_17_0 = ["bcc-sys/v0_17_0", "specific"]
v0_18_0 = ["bcc-sys/v0_18_0", "specific"]
v0_19_0 = ["bcc-sys/v0_19_0", "specific"]
v0_20_0 = ["bcc-sys/v0_20_0", "specific"]

View File

@ -155,6 +155,8 @@ elif [[ "${BCC}" == "0.18.0" ]]; then
git checkout b1ab869032611d9fcdaea56851cd6126cca2eba8
elif [[ "${BCC}" == "0.19.0" ]]; then
git checkout 4c561d037e2798563c2e87edcc5a406b020a458c
elif [[ "${BCC}" == "0.20.0" ]]; then
git checkout 14278bf1a52dd76ff66eed02cc9db7c7ec240da6
fi
## Installing BCC dependencies
sudo apt-get --yes install cmake bison

View File

@ -32,6 +32,7 @@ pub use v0_6_0::*;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
mod v0_9_0;
@ -48,6 +49,7 @@ mod v0_9_0;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub use v0_9_0::*;

View File

@ -231,6 +231,7 @@ impl BPFBuilder {
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific")
))]
fn create_module(&self) -> Result<MutPointer, BccError> {
@ -361,6 +362,7 @@ impl BPF {
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
unsafe fn load_func_impl(
@ -418,6 +420,7 @@ impl BPF {
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub fn load_func(&mut self, name: &str, bpf_prog_type: BpfProgType) -> Result<i32, BccError> {
@ -586,6 +589,7 @@ impl BPF {
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
/// load the named BPF program from within the compiled BPF code
@ -681,6 +685,7 @@ impl BPF {
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
/// Returns true if raw tracepoints are supported by the running kernel

View File

@ -20,6 +20,7 @@ pub use v0_4_0::*;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
mod v0_6_0;
@ -40,6 +41,7 @@ mod v0_6_0;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub use v0_6_0::*;

View File

@ -20,6 +20,7 @@ pub use v0_4_0::*;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
mod v0_6_0;
@ -40,6 +41,7 @@ mod v0_6_0;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub use v0_6_0::*;

View File

@ -40,6 +40,7 @@ pub use v0_6_0::*;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
mod v0_17_0;
@ -48,6 +49,7 @@ mod v0_17_0;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub use v0_17_0::*;

View File

@ -31,6 +31,7 @@ pub use self::v0_4_0::{usdt_generate_args, USDTContext};
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
mod v0_10_0;
@ -46,6 +47,7 @@ mod v0_10_0;
feature = "v0_17_0",
feature = "v0_18_0",
feature = "v0_19_0",
feature = "v0_20_0",
not(feature = "specific"),
))]
pub use self::v0_10_0::{usdt_generate_args, USDTContext};