Skip to content

Commit

Permalink
Fix flag check for fuzzers (halide#7542)
Browse files Browse the repository at this point in the history
On some system size_t isn't available under <cstdint>, however
it is garaunteed to be available under <cstddef> for all systems.
  • Loading branch information
nathaniel-brough authored and ardier committed Mar 3, 2024
1 parent 3b667e0 commit e9e672c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ set(CMAKE_REQUIRED_LINK_OPTIONS "-fsanitize=fuzzer,address")
set(CMAKE_REQUIRED_FLAGS "-fsanitize=fuzzer-no-link,address")
check_cxx_source_compiles([[
#include <cstdint>
#include <cstddef>
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, std::size_t Size) {
return 0;
}
Expand Down

0 comments on commit e9e672c

Please sign in to comment.