From 932d4077e9d2434526c84c9543e5f03dc08b6410 Mon Sep 17 00:00:00 2001 From: bcapuano Date: Wed, 3 Aug 2022 21:14:53 -0400 Subject: [PATCH] Made requested changes --- Dockerfile | 14 +++++--------- Mayhemfile | 1 - 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index 4e0bf776..ec4f34f9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,12 +3,11 @@ FROM fuzzers/cargo-fuzz:0.10.0 as builder ##Install Build Dependencies RUN apt-get update && \ - DEBIAN_FRONTEND=noninteractive apt-get install -y git clang + DEBIAN_FRONTEND=noninteractive apt-get install -y clang ##ADD source code to the build stage WORKDIR / -ADD https://api.github.com/repos/ennamarie19/miniz_oxide/git/refs/heads/mayhem version.json -RUN git clone -b mayhem https://github.com/ennamarie19/miniz_oxide.git +ADD . /miniz_oxide WORKDIR /miniz_oxide ##Build @@ -17,13 +16,10 @@ RUN rustup default nightly RUN cargo install cargo-fuzz -Z no-index-update RUN cargo fuzz build inflate_nonwrapping -Zno-index-update -##Prepare all library dependencies for copy -RUN mkdir /deps -RUN cp `ldd /miniz_oxide/fuzz/target/x86_64-unknown-linux-gnu/release/inflate_nonwrapping | grep so | sed -e '/^[^\t]/ d' | sed -e 's/\t//' | sed -e 's/.*=..//' | sed -e 's/ (0.*)//' \ -| sort | uniq` /deps 2>/dev/null || : - FROM --platform=linux/amd64 ubuntu:20.04 +RUN apt-get update && \ + DEBIAN_FRONTEND=noninteractive apt-get install -y libgcc1 libstdc++6 + COPY --from=builder /miniz_oxide/fuzz/target/x86_64-unknown-linux-gnu/release/inflate_nonwrapping /inflate_nonwrapping -COPY --from=builder /deps /usr/lib CMD ["/inflate_nonwrapping"] diff --git a/Mayhemfile b/Mayhemfile index 83700c0a..80c62b89 100644 --- a/Mayhemfile +++ b/Mayhemfile @@ -1,4 +1,3 @@ -image: ghcr.io/ennamarie19/miniz-oxide-fuzz:latest project: miniz-oxide target: inflate-fuzz testsuite: