
* linux kernel (x509_cert) and process fuzzing example * rework filters * update to latest qemu * working for process and kernel fuzzing * new i2s mutator for binary only fuzzers * refactoring modules with new filtering interface * add state as parameter of harness * hide unused global in usermode * Script for stub bindings generation * do not try to check whether it is worth generating the bindings, always generate when the env variable is on. * add taplo to fmt_all.sh * Moved fuzzers (again) in a target-centric way. * fix rust 2024 warnings. * new libafl_qemu harness structure. * rename qemu_systemmode into qemu_baremetal * fix qemu baremetal makefile * fix formatter --------- Co-authored-by: Toka <tokazerkje@outlook.com>
28 lines
797 B
Rust
28 lines
797 B
Rust
// build.rs
|
|
|
|
use std::env;
|
|
|
|
fn main() {
|
|
let out_dir = env::var_os("OUT_DIR").unwrap();
|
|
let out_dir = out_dir.to_string_lossy().to_string();
|
|
|
|
println!("cargo:rerun-if-changed=harness.c");
|
|
|
|
// Enforce clang for its -fsanitize-coverage support.
|
|
std::env::set_var("CC", "clang");
|
|
std::env::set_var("CXX", "clang++");
|
|
|
|
cc::Build::new()
|
|
// Use sanitizer coverage to track the edges in the PUT
|
|
.flag("-fsanitize-coverage=trace-pc-guard,trace-cmp")
|
|
// Take advantage of LTO (needs lld-link set in your cargo config)
|
|
//.flag("-flto=thin")
|
|
.flag("-Wno-sign-compare")
|
|
.file("./harness.c")
|
|
.compile("harness");
|
|
|
|
println!("cargo:rustc-link-search=native={}", &out_dir);
|
|
|
|
println!("cargo:rerun-if-changed=build.rs");
|
|
}
|