FROM ubuntu:22.04 ENV LANG=C.UTF-8 LC_ALL=C.UTF-8 ENV PATH /opt/conda/bin:$PATH SHELL ["/bin/bash", "-c"] # Basic dependencies, antlr4, and C++ build tools # libpoly: libgmp-dev # racket: openssh-client RUN set -x && \ apt-get update --fix-missing && \ apt-get install -y --no-install-recommends \ bzip2 \ ca-certificates \ openssh-client \ git \ wget \ build-essential \ zip unzip \ python3-dev python3-pip \ gcc make cmake ninja-build \ antlr4 \ libgmp-dev \ software-properties-common gpg-agent # racket and rosette and other racket packages ARG DEBIAN_FRONTEND=noninteractive RUN add-apt-repository -y ppa:plt/racket && \ apt-get update && \ apt-get install -y racket libssl-dev curl && \ raco pkg install --auto rosette && \ raco pkg install --auto csv-reading && \ raco pkg install --auto graph && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* # build rust & circom 2.0.7 RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && \ source "$HOME/.cargo/env" && \ git clone https://github.com/iden3/circom.git && \ cd circom/ && \ git checkout v2.0.7 && \ cargo build --release && \ cargo install --path circom && \ cd .. && rm -rf circom/ # install z3 RUN wget https://github.com/Z3Prover/z3/releases/download/z3-4.11.0/z3-4.11.0-x64-glibc-2.31.zip && \ unzip z3-4.11.0-x64-glibc-2.31.zip && \ cp z3-4.11.0-x64-glibc-2.31/bin/z3 /bin/ && \ rm -r z3-4.11.0-x64-glibc-2.31/ # install libpoly RUN git clone https://github.com/SRI-CSL/libpoly.git && \ cd ./libpoly/ && \ cd ./build/ && \ cmake .. -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local && \ cmake --build . && \ cmake --install . && \ cd ../../ && rm -r ./libpoly # fetch cvc5-ff RUN pip install toml && \ git clone https://github.com/alex-ozdemir/CVC4.git -b ff --single-branch && \ cd ./CVC4 && \ git checkout ddcecc5 # compile and install CoCoALib with patch from cvc5-ff RUN wget https://cocoa.dima.unige.it/cocoa/cocoalib/tgz/CoCoALib-0.99800.tgz && \ tar -xvzf CoCoALib-0.99800.tgz &&\ patch -s -p1 -d ./CoCoALib-0.99800 < ./CVC4/cmake/deps-utils/CoCoALib-0.99800-trace.patch && \ cd CoCoALib-0.99800/ && \ ./configure && \ make && \ make install && \ cd .. && rm -r ./CoCoALib-0.99800 # compile and install cvc5-ff RUN cd ./CVC4/ && \ ./configure.sh --cocoa --auto-download --ninja && \ cd ./build/ && \ cmake --build . && \ cmake --install . && \ cd ../.. && rm -r ./CVC4 CMD [ "/bin/bash" ]