Rebased ref, commits from common ancestor:
commit f5209e99aec9b60c41acede92c10d4fa4db5c589
Author: Jan-Marek Glogowski <[email protected]>
AuthorDate: Mon Dec 13 18:47:50 2021 +0100
Commit: Jan-Marek Glogowski <[email protected]>
CommitDate: Sat Dec 18 15:38:56 2021 +0100
oss-fuzz: put LO downloads into $SRC/external-tar
Change-Id: I0d5cf89fabc8e044959dbd0af484b5ca46404eac
diff --git a/bin/oss-fuzz-build.sh b/bin/oss-fuzz-build.sh
index d0f4564a930e..8db91c519d2e 100755
--- a/bin/oss-fuzz-build.sh
+++ b/bin/oss-fuzz-build.sh
@@ -24,7 +24,7 @@ export ASAN_OPTIONS="detect_leaks=0"
df -h $OUT $WORK
cd $WORK
-$SRC/libreoffice/autogen.sh --with-distro=LibreOfficeOssFuzz
--with-external-tar=$SRC
+$SRC/libreoffice/autogen.sh --with-distro=LibreOfficeOssFuzz
--with-external-tar=$SRC/external-tar
make clean
@@ -37,8 +37,8 @@ for a in *fuzzer; do
#some minimal fonts required
mv $a $OUT
mkdir -p $OUT/$a.fonts
- tar -x -C $OUT/$a.fonts --strip-components=1 --wildcards --no-anchored
'*.ttf' -f $SRC/liberation-fonts-ttf*
- cp $SRC/*opens___.ttf $OUT/$a.fonts
+ tar -x -C $OUT/$a.fonts --strip-components=1 --wildcards --no-anchored
'*.ttf' -f $SRC/external-tar/liberation-fonts-ttf*
+ cp $SRC/external-tar/*opens___.ttf $OUT/$a.fonts
#minimal runtime requirements
cp templateservices.rdb $OUT/$a.services.rdb
cp types.rdb $OUT/$a.types.rdb
diff --git a/bin/oss-fuzz-setup.sh b/bin/oss-fuzz-setup.sh
index 18c3fcfb68d9..5566d845f66c 100755
--- a/bin/oss-fuzz-setup.sh
+++ b/bin/oss-fuzz-setup.sh
@@ -7,7 +7,8 @@ echo start downloading dependencies at `date -u`
# convert FOO := BAR$(MICRO) to FOO=BAR$MICRO
source <(sed -e's# := #=#g' download.lst | sed -e 's#[)(]##g')
-cd $SRC
+mkdir $SRC/external-tar
+cd $SRC/external-tar
#cache build dependencies
curl --no-progress-meter -S \
@@ -70,6 +71,9 @@ curl --no-progress-meter -S \
-C - -O https://dev-www.libreoffice.org/src/$EPUBGEN_TARBALL \
-C - -O https://dev-www.libreoffice.org/src/$LIBNUMBERTEXT_TARBALL \
-C - -O https://dev-www.libreoffice.org/src/$QXP_TARBALL
+
+cd $SRC
+
#fuzzing dictionaries
curl --no-progress-meter -S \
-C - -O
https://raw.githubusercontent.com/rc0r/afl-fuzz/master/dictionaries/gif.dict \