AFLplusplus / AFLplusplus/LibAFL

libafl_libfuzzer fails to build with error: 'sanitizer/allocator_interface.h' file not found

Đang mở
#2,535 4 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Rust
Star
2.6k
Fork
481
Merge trung bình
2 ngày 30 phút
Pull request đã merge (30 ngày)
16

Mô tả

I am trying to use the libafl_libfuzzer shim with cargo-fuzz and hitting this error:
```
--- stderr
src/sanitizer_interfaces.h:1:10: fatal error: 'sanitizer/allocator_interface.h' file not found
thread 'main' panicked at /root/.cargo/git/checkouts/libafl-c33dc6f5ec2f7a70/2c676f0/libafl_targets/build.rs:237:14:
Couldn't generate the sanitizer headers!: ClangDiagnostic("src/sanitizer_interfaces.h:1:10: fatal error: 'sanitizer/allocator_interface.h' file not found\n")
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
thread 'main' panicked at /root/.cargo/git/checkouts/libafl-c33dc6f5ec2f7a70/2c676f0/libafl_libfuzzer/build.rs:137:5:
Couldn't build runtime crate! Did you remember to use nightly? (`rustup default nightly` to install)
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Error: failed to build fuzz script: RUSTFLAGS="-Cpasses=sancov-module -Cllvm-args=-sanitizer-coverage-level=4 -Cllvm-args=-sanitizer-coverage-inline-8bit-counters -Cllvm-args=-sanitizer-coverage-pc-table -Cllvm-args=-sanitizer-coverage-trace-compares --cfg fuzzing -Clink-dead-code -Cllvm-args=-sanitizer-coverage-stack-depth -Cdebug-assertions -C codegen-units=1" "cargo" "build" "--manifest-path" "/root/fuzz/fuzz/Cargo.toml" "--target" "x86_64-unknown-linux-gnu" "--release" "--config" "profile.release.debug=true" "--bin" "fuzz_target1"

```

As I have not been able to find any info on this error elsewhere, I'd appreciate any help. I am using `rustc 1.83.0-nightly (c52c23b6f 2024-09-16)` and running on an X86_64 Ubuntu server

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.