[dlplibs] add key6 corpus + some cleanup (#525)

* add key6 corpus

* do not require liblangtag

* do not build tools
This commit is contained in:
David Tardon 2017-04-07 15:48:13 +02:00 committed by Max Moroz
parent f1f310f2df
commit f6b672f854
2 changed files with 18 additions and 9 deletions

View File

@ -20,8 +20,8 @@ MAINTAINER dtardon@redhat.com
RUN apt-get update
RUN apt-get build-dep -y \
libmspub librevenge libcdr libvisio libpagemaker libfreehand libwpd \
libwpg libwps libmwaw libe-book libabw
RUN apt-get install -y liblzma-dev libpng-dev wget liblangtag-dev
libwpg libwps libmwaw libe-book libabw libetonyek
RUN apt-get install -y liblzma-dev libpng-dev wget
ADD https://dev-www.libreoffice.org/src/lcms2-2.8.tar.gz $SRC/
# download fuzzing corpora
ADD https://dev-www.libreoffice.org/corpus/olefuzzer_seed_corpus.zip \
@ -39,6 +39,7 @@ ADD https://dev-www.libreoffice.org/corpus/olefuzzer_seed_corpus.zip \
https://dev-www.libreoffice.org/corpus/sdafuzzer_seed_corpus.zip \
https://dev-www.libreoffice.org/corpus/sddfuzzer_seed_corpus.zip \
https://dev-www.libreoffice.org/corpus/sdwfuzzer_seed_corpus.zip \
https://dev-www.libreoffice.org/corpus/key6fuzzer_seed_corpus.zip \
$SRC/
RUN wget \
https://sourceforge.net/projects/libwpd/files/corpus/wpdfuzzer_seed_corpus.zip \
@ -76,5 +77,6 @@ RUN git clone --depth 1 git://git.code.sf.net/p/libwps/code libwps
RUN git clone --depth 1 git://git.code.sf.net/p/libmwaw/libmwaw
RUN git clone --depth 1 git://git.code.sf.net/p/libebook/code libe-book
RUN git clone --depth 1 git://gerrit.libreoffice.org/libabw
RUN git clone --depth 1 git://gerrit.libreoffice.org/libetonyek
WORKDIR $SRC
COPY build.sh abw.dict *.options $SRC/

View File

@ -15,17 +15,13 @@
#
################################################################################
# HACK to force linking with static icu, libxml2 and liblangtag
# WTH is liblangtag linked with glib?!
# HACK to force linking with static icu and libxml2
mkdir static
cp -pL \
/usr/lib/*/libicu*.a \
/usr/lib/*/libxml2.a \
/usr/lib/*/liblzma.a \
/usr/lib/*/libpng*.a \
/usr/lib/*/liblangtag.a \
/usr/lib/*/libglib-2.0.a \
/usr/lib/*/libpcre.a \
static
staticlib=$(pwd)/static
@ -158,10 +154,9 @@ popd
pushd libe-book
./autogen.sh
./configure --without-docs --disable-shared --enable-static --disable-tools --enable-fuzzers \
./configure --without-docs --disable-shared --enable-static --without-tools --enable-fuzzers --without-liblangtag \
LDFLAGS=-L$staticlib \
XML_LIBS="-lxml2 -llzma" \
LANGTAG_LIBS="-llangtag -lglib-2.0 -lpcre" \
REVENGE_CFLAGS=-I$rvnginc REVENGE_LIBS="-L$rvnglib -lrevenge-0.0" \
REVENGE_STREAM_CFLAGS=-I$rvnginc REVENGE_STREAM_LIBS="-L$rvnglib -lrevenge-stream-0.0" \
REVENGE_GENERATORS_CFLAGS=-I$rvnginc REVENGE_GENERATORS_LIBS="-L$rvnglib -lrevenge-generators-0.0"
@ -179,6 +174,18 @@ pushd libabw
make -j$(nproc)
popd
pushd libetonyek
./autogen.sh
./configure --without-docs --disable-shared --enable-static \
--without-tools --enable-fuzzers --with-mdds=0.x --without-liblangtag \
LDFLAGS=-L$staticlib \
XML_LIBS="-lxml2 -llzma -licuuc -licudata" \
REVENGE_CFLAGS=-I$rvnginc REVENGE_LIBS="-L$rvnglib -lrevenge-0.0" \
REVENGE_STREAM_CFLAGS=-I$rvnginc REVENGE_STREAM_LIBS="-L$rvnglib -lrevenge-stream-0.0" \
REVENGE_GENERATORS_CFLAGS=-I$rvnginc REVENGE_GENERATORS_LIBS="-L$rvnglib -lrevenge-generators-0.0"
make -j$(nproc)
popd
cp */src/fuzz/*fuzzer $OUT
cp *_seed_corpus.zip $OUT
cp *.options $OUT