aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Paul Dreik <github@pauldreik.se>2019-05-29 21:04:12 +0200
committerGravatar jonathanmetzman <31354670+jonathanmetzman@users.noreply.github.com>2019-05-29 12:04:12 -0700
commit55fdfd13d73ec6bb4af48258380a32208624bd38 (patch)
tree21ad975ec76d65f7829abf3185a86f5bb3fc3f00
parentd4fc73db43ba4351a13f1fe9c5efdceaad79c499 (diff)
[libfmt] needs recursive clone (#2475)
* the fmt-fuzzer needs recursive clone now
-rw-r--r--projects/libfmt/Dockerfile6
-rwxr-xr-xprojects/libfmt/build.sh9
-rw-r--r--projects/libfmt/project.yaml1
3 files changed, 13 insertions, 3 deletions
diff --git a/projects/libfmt/Dockerfile b/projects/libfmt/Dockerfile
index 91082f24..a4e99d8d 100644
--- a/projects/libfmt/Dockerfile
+++ b/projects/libfmt/Dockerfile
@@ -20,7 +20,11 @@ RUN echo "CXX=$CXX"
RUN echo "CXXFLAGS=$CXXFLAGS"
RUN apt-get update && apt-get install -y cmake ninja-build
-RUN git clone --single-branch --branch fuzz https://github.com/pauldreik/fmt.git
+RUN git clone --single-branch --branch fuzz \
+ https://github.com/pauldreik/fmt.git \
+ --recursive
+# this requires git>=2.9.0
+#--shallow-submodules
WORKDIR fmt
COPY build.sh $SRC/
diff --git a/projects/libfmt/build.sh b/projects/libfmt/build.sh
index c2a2013d..b67fbba1 100755
--- a/projects/libfmt/build.sh
+++ b/projects/libfmt/build.sh
@@ -23,9 +23,16 @@
mkdir build
cd build
-cmake .. -GNinja -DCMAKE_BUILD_TYPE=Debug \
+# use C++ 14 instead of 17, because even if clang is
+# bleeding edge, cmake is old in the oss fuzz image.
+
+cmake .. \
+-GNinja \
+-DCMAKE_BUILD_TYPE=Debug \
+-DCMAKE_CXX_STANDARD=14 \
-DFMT_DOC=Off \
-DFMT_TEST=Off \
+-DFMT_SAFE_DURATION_CAST=On \
-DFMT_FUZZ=On \
-DFMT_FUZZ_LINKMAIN=Off \
-DFMT_FUZZ_LDFLAGS=$LIB_FUZZING_ENGINE
diff --git a/projects/libfmt/project.yaml b/projects/libfmt/project.yaml
index 13d709da..41549407 100644
--- a/projects/libfmt/project.yaml
+++ b/projects/libfmt/project.yaml
@@ -3,4 +3,3 @@ primary_contact: "pauldreikossfuzz@gmail.com"
auto_ccs:
- "victor.zverovich@gmail.com"
-