Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 20 additions & 2 deletions projects/libvpx/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ LDFLAGS="$CXXFLAGS" LD=$CXX $SRC/libvpx/configure \
--extra-cflags="${extra_c_flags}" \
--disable-webm-io \
--enable-debug \
--disable-vp8-encoder \
--disable-vp9-encoder
--enable-vp8-encoder \
--enable-vp9-encoder
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like the decoders, these are enabled by default. You can remove the lines.

make -j$(nproc) all
popd

Expand All @@ -60,4 +60,22 @@ for decoder in "${fuzzer_decoders[@]}"; do
-Wl,--end-group
cp $SRC/vpx_fuzzer_seed_corpus.zip $OUT/${fuzzer_name}_seed_corpus.zip
cp $SRC/vpx_dec_fuzzer.dict $OUT/${fuzzer_name}.dict
cp $OUT/${fuzzer_name} $OUT/${fuzzer_name}_nalloc
done

fuzzer_src_name=vpx_enc_fuzzer
fuzzer_encoders=( 'vp9' 'vp8' )
for encoder in "${fuzzer_encoders[@]}"; do
fuzzer_name=${fuzzer_src_name}"_"${encoder}

$CXX $CXXFLAGS -std=c++11 \
-DENCODER=${encoder} \
-I$SRC/libvpx \
-I${build_dir} \
-Wl,--start-group \
$LIB_FUZZING_ENGINE \
$SRC/libvpx/examples/${fuzzer_src_name}.cc -o $OUT/${fuzzer_name} \
${build_dir}/libvpx.a \
-Wl,--end-group
cp $OUT/${fuzzer_name} $OUT/${fuzzer_name}_nalloc
done