Skip to content

Commit

Permalink
tensorflow-py: fix build
Browse files Browse the repository at this point in the history
Fixes the current build issue (https://oss-fuzz-build-logs.storage.googleapis.com/log-455d862d-6130-4650-85d5-2caf99b45a9e.txt):
```
Step #4 - "build-check-libfuzzer-address-x86_64":   File "charset_normalizer/api.py", line 5, in <module>
Step #4 - "build-check-libfuzzer-address-x86_64":   File "PyInstaller/loader/pyimod03_importers.py", line 495, in exec_module
Step #4 - "build-check-libfuzzer-address-x86_64":   File "charset_normalizer/cd.py", line 9, in <module>
Step #4 - "build-check-libfuzzer-address-x86_64": ModuleNotFoundError: No module named 'charset_normalizer.md__mypyc'
```

Signed-off-by: David Korczynski <[email protected]>
  • Loading branch information
DavidKorczynski committed Jan 13, 2023
1 parent dcf2cf8 commit 9e0ba9a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion projects/tensorflow-py/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

RUN python3 -m pip install --upgrade pip
RUN python3 -m pip install --upgrade pip chardet

# Due to Bazel bug, need to symlink python3 to python
# See https:/bazelbuild/bazel/issues/8665
Expand Down
2 changes: 1 addition & 1 deletion projects/tensorflow-py/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ for fuzzer in $(find $SRC -name '*_fuzz.py'); do
fuzzer_basename=$(basename -s .py $fuzzer)
fuzzer_package=${fuzzer_basename}.pkg

pyinstaller --distpath $OUT --onefile --name $fuzzer_package $fuzzer
pyinstaller --distpath $OUT --onefile --name $fuzzer_package $fuzzer --hidden-import=chardet

echo "#!/bin/sh
# LLVMFuzzerTestOneInput for fuzzer detection.
Expand Down

0 comments on commit 9e0ba9a

Please sign in to comment.