commit | 4b881842181b8a8186b0b03d7237fbaf2b6843b0 | [log] [tgz] |
---|---|---|
author | Daniele Di Proietto <ddiproietto@google.com> | Tue May 07 12:50:58 2024 +0000 |
committer | Daniele Di Proietto <ddiproietto@google.com> | Tue May 07 13:05:23 2024 +0000 |
tree | db082e3246f5dde3b3bf1200298c89d50aae8388 | |
parent | 7e9067b9f61ffa461f464d9ca22219bff3b8826b [diff] |
Fix build for oss-fuzz Without this, the oss-fuzz build fails with: ``` Step #3 - "compile-afl-address-x86_64": FAILED: unwinding_fuzzer stripped/unwinding_fuzzer Step #3 - "compile-afl-address-x86_64": /src/aflplusplus/afl-clang-fast++ -fuse-ld=gold -lFuzzingEngine -Wl,--build-id -Wl,-z,max-page-size=16384 -Wl,--gc-sections -Wl,--icf=all -Wl,-O1 -Wl,-rpath=\$ORIGIN/. -Wl,-rpath-link=. -fsanitize=address -O1 -fno-omit-frame-pointer -gline-tables-only -Wno-error=enum-constexpr-conversion -Wno-error=incompatible-function-pointer-types -Wno-error=int-conversion -Wno-error=deprecated-declarations -Wno-error=implicit-function-declaration -Wno-error=implicit-int -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION -fsanitize=address -fsanitize-address-use-after-scope -stdlib=libc++ -Wno-extra-semi-stmt -fno-sanitize=vptr @./unwinding_fuzzer.rsp -lpthread -lrt -o ./unwinding_fuzzer && strip -o ./stripped/unwinding_fuzzer ./unwinding_fuzzer Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_regular:zero.protolog.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_regular:zero.shell_transition.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_regular:zero.surfaceflinger_common.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_regular:zero.surfaceflinger_layers.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_regular:zero.surfaceflinger_transactions.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/graphics/winscope_common:zero.point.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/graphics/winscope_common:zero.rect.pbzero.o'' Step #3 - "compile-afl-address-x86_64": clang++: error: no such file or directory: ''obj/gen/protos/perfetto/trace/android/winscope_common:zero.winscope_extensions.pbzero.o'' ``` I don't know: * why it only fails on the ozz-fuzz docker image and not locally on CI * why exactly changing `:` to `_` fixes the problem but, in general, `:` is used by gn to split the directory from the target name, so it's probably a good idea to avoid using it for something else. Tested by checking out oss-fuzz and perfetto (with the patch applied) and running: * `python infra/helper.py build_image perfetto` * `python infra/helper.py build_fuzzers --sanitizer address --engine afl --architecture x86_64 perfetto ~/perfetto` Reported-at: https://crbug.com/oss-fuzz/68755 Change-Id: I3e3f1f799d53cba676714bb2578ad15c513d6960
Perfetto is a production-grade open-source stack for performance instrumentation and trace analysis. It offers services and libraries and for recording system-level and app-level traces, native + java heap profiling, a library for analyzing traces using SQL and a web-based UI to visualize and explore multi-GB traces.
See https://perfetto.dev/docs or the /docs/ directory for documentation.