Skip to content

Commit

Permalink
Correct path for pull request triggers and check out where the fuzzin…
Browse files Browse the repository at this point in the history
…g takes place.
  • Loading branch information
sydseter committed Apr 7, 2024
1 parent 792556c commit 3722a4a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
14 changes: 10 additions & 4 deletions .clusterfuzzlite/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ update-alternatives --set python3 /usr/bin/python3.10
#pip install nuitka
python3 -m pip install -r requirements.txt --require-hashes
python3 -m pip install -r install_cornucopia_deps.txt --require-hashes --no-deps

$SRC=$(pwd)
echo "What is here?"
ls
pwd
#for debugging
#exec "$SHELL"
# Build fuzzers into $OUT. These could be detected in other ways.
Expand All @@ -22,14 +25,17 @@ for fuzzer in $(find "$SRC/tests/scripts" -name '*_fuzzer.py'); do
fuzzer_package=${fuzzer_basename}.pkg

#python3 -m nuitka3 --output-dir=$OUT --onefile --output-filename=$fuzzer_package $fuzzer
python3 -m PyInstaller --distpath $OUT --onefile --name $fuzzer_package $fuzzer
python3 -m PyInstaller --distpath $SRC --onefile --name $fuzzer_package $fuzzer

echo "#!/bin/sh
# LLVMFuzzerTestOneInput for fuzzer detection.
echo "fuzzing now, this is what is here"
ls
pwd
this_dir=\$(dirname \"\$0\")
ASAN_OPTIONS=\$ASAN_OPTIONS:symbolize=1:external_symbolizer_path=\$this_dir/llvm-symbolizer:detect_leaks=0 \
\$this_dir/tests/scripts/$fuzzer_package \$@" > $OUT/$fuzzer_basename
chmod +x $OUT/$fuzzer_basename
\$this_dir/tests/scripts/$fuzzer_package \$@" > $SRC/$fuzzer_basename
chmod +x $SRC/$fuzzer_basename
done

# build fuzzers
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/cflite_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ on:
pull_request:
paths:
- 'scripts/convert**'
- 'test/scripts/convert**'
- 'tests/scripts/convert**'
- '.github/workflows/cflite_pr.yml'
- 'test/scripts/*_fuzzer.py'
- 'tests/scripts/*_fuzzer.py'
- '.clusterfuzzlite/**'
permissions: read-all
jobs:
Expand Down

0 comments on commit 3722a4a

Please sign in to comment.