mirror of
https://github.com/SerenityOS/serenity
synced 2024-10-06 16:09:30 +00:00
Fuzzers: Use libc++ on OSS-Fuzz for Lagom code generators
By unsetting `CXXFLAGS` in order to build Lagom code generators without instrumentation, we were also removing `-stdlib=libc++`, so Clang ended up using the runner image's libstdc++ 9 headers. These are too old, and don't contain `<coroutine>`, leading to a build failure. Fixes #24578
This commit is contained in:
parent
a711bb63b7
commit
8b189b7eb0
|
@ -47,7 +47,10 @@ unset CXXFLAGS
|
||||||
export AFL_NOOPT=1
|
export AFL_NOOPT=1
|
||||||
|
|
||||||
if [ "$#" -gt "0" ] && [ "--oss-fuzz" = "$1" ] ; then
|
if [ "$#" -gt "0" ] && [ "--oss-fuzz" = "$1" ] ; then
|
||||||
CXXFLAGS="$CXXFLAGS -DOSS_FUZZ=ON"
|
# The oss-fuzz runner image (as of June 2024) has libstdc++ 9, which lacks the
|
||||||
|
# <coroutine> header. Use the more modern libc++ shipped with oss-fuzz's Clang.
|
||||||
|
# It's already set in CXXFLAGS_SAVE.
|
||||||
|
CXXFLAGS="$CXXFLAGS -DOSS_FUZZ=ON -stdlib=libc++"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# FIXME: Replace these CMake invocations with a CMake superbuild?
|
# FIXME: Replace these CMake invocations with a CMake superbuild?
|
||||||
|
|
Loading…
Reference in a new issue