Building and run bpftime
Install Dependencies
Install the required packages:
sudo apt install -y --no-install-recommends \
libelf1 libelf-dev zlib1g-dev make git libboost1.74-all-dev \
binutils-dev libyaml-cpp-dev llvm
git submodule update --init --recursive
We've tested on Ubuntu 23.04. The recommended gcc
>= 12.0.0 clang
>= 16.0.0
On Ubuntu 20.04, you may need to manually switch to gcc-12.
Build and install cli tool
sudo apt-get install libelf-dev zlib1g-dev # Install dependencies
make release && make install # Build and install the runtime
cd tools/cli-rs && cargo build --release
mkdir -p ~/.bpftime && cp ./target/release/bpftime ~/.bpftime
export PATH=$PATH:~/.bpftime
Then you can run cli:
Compilation for vm
Build the complete runtime:
On old systems, you may need to buil with old binutils version(TODO: fix it):
For a lightweight build without the runtime (only vm library and LLVM JIT):
Testing
Run the test suite for runtime to validate the implementation: