diff --git a/Dockerfile b/Dockerfile index 53abbf4f302..7d1b78f38dd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,7 @@ -# Build Stage FROM --platform=linux/amd64 ubuntu:20.04 as builder -## Install build dependencies. RUN apt-get update -RUN DEBIAN_FRONTEND=noninteractive apt-get install -y vim less man wget tar git gzip unzip make cmake software-properties-common curl +RUN DEBIAN_FRONTEND=noninteractive apt-get install -y make gcc ADD . /repo WORKDIR /repo/unix @@ -11,3 +9,12 @@ ENV LD_LIBRARY_PATH=/repo/unix RUN ldconfig RUN ./configure RUN make -j8 + +RUN mkdir -p /deps +RUN ldd /repo/unix/tclsh | tr -s '[:blank:]' '\n' | grep '^/' | xargs -I % sh -c 'cp % /deps;' + +FROM ubuntu:20.04 as package + +COPY --from=builder /deps /deps +COPY --from=builder /repo/unix/tclsh /repo/unix/tclsh +ENV LD_LIBRARY_PATH=/deps diff --git a/Mayhemfile b/Mayhemfile index d1761029add..e456c167a19 100644 --- a/Mayhemfile +++ b/Mayhemfile @@ -1,7 +1,6 @@ -project: rnshah9/mayhem-tcl +project: tcl target: tclsh -tests: null cmds: - - cmd: /repo/unix/tclsh @@ + - cmd: /repo/unix/tclsh /test.tcl filepath: /test.tcl