Update build.sh

This commit is contained in:
Rithvik 2021-12-11 21:31:19 +05:30 committed by GitHub
parent cc927343da
commit 3912518b6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,9 +14,7 @@
# limitations under the License. # limitations under the License.
# #
################################################################################ ################################################################################
python3 setup.py build --build-base=/tmp/build install python3 setup.py build --build-base=/tmp/build install
# Build fuzzers in $OUT. # Build fuzzers in $OUT.
for fuzzer in $(find $SRC -name 'fuzz_*.py'); do for fuzzer in $(find $SRC -name 'fuzz_*.py'); do
fuzzer_basename=$(basename -s .py $fuzzer) fuzzer_basename=$(basename -s .py $fuzzer)
@ -33,7 +31,6 @@ for fuzzer in $(find $SRC -name 'fuzz_*.py'); do
--add-binary /usr/local/lib/libwebpmux.so.3:. \ --add-binary /usr/local/lib/libwebpmux.so.3:. \
--add-binary /usr/local/lib/libxcb.so.1:. \ --add-binary /usr/local/lib/libxcb.so.1:. \
--distpath $OUT --onefile --name $fuzzer_package $fuzzer --distpath $OUT --onefile --name $fuzzer_package $fuzzer
# Create execution wrapper. # Create execution wrapper.
echo "#!/bin/sh echo "#!/bin/sh
# LLVMFuzzerTestOneInput for fuzzer detection. # LLVMFuzzerTestOneInput for fuzzer detection.
@ -43,6 +40,5 @@ ASAN_OPTIONS=\$ASAN_OPTIONS:symbolize=1:external_symbolizer_path=\$this_dir/llvm
\$this_dir/$fuzzer_package \$@" > $OUT/$fuzzer_basename \$this_dir/$fuzzer_package \$@" > $OUT/$fuzzer_basename
chmod u+x $OUT/$fuzzer_basename chmod u+x $OUT/$fuzzer_basename
done done
find Tests/images Tests/icc -print | zip -q $OUT/fuzz_pillow_seed_corpus.zip -@ find Tests/images Tests/icc -print | zip -q $OUT/fuzz_pillow_seed_corpus.zip -@
find Tests/fonts -print | zip -q $OUT/fuzz_font_seed_corpus.zip -@ find Tests/fonts -print | zip -q $OUT/fuzz_font_seed_corpus.zip -@