Skip to content

Commit 972d4de

Browse files
committed
Fix FreeBSD build: make libbpf-cargo optional and add libpcap to Cross.toml
- Made libbpf-cargo an optional build dependency - Only builds when ebpf feature is enabled - Added Cross.toml configuration for FreeBSD to install libpcap - Verified libbpf-sys no longer tries to build for FreeBSD - Now fixing linker error for missing libpcap
1 parent 99a7cbd commit 972d4de

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

Cross.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,9 @@ pre-build = [
1414
"apt-get install -y libelf-dev:armhf zlib1g-dev:armhf libpcap-dev:armhf gcc-arm-linux-gnueabihf protobuf-compiler libseccomp-dev:armhf libbpf-dev clang llvm"
1515
]
1616

17+
[target.x86_64-unknown-freebsd]
18+
pre-build = [
19+
# FreeBSD uses pkg as package manager
20+
"pkg install -y libpcap",
21+
]
22+

0 commit comments

Comments
 (0)