forked from ethereum/solidity
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Dockerfile-solcverify-local.src
53 lines (44 loc) · 1.5 KB
/
Dockerfile-solcverify-local.src
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
FROM ubuntu:focal
# Generic packages
RUN apt update && DEBIAN_FRONTEND="noninteractive" apt install -y \
cmake \
curl \
git \
libboost-filesystem-dev \
libboost-program-options-dev \
libboost-system-dev \
libboost-test-dev \
python3-pip \
software-properties-common \
unzip \
wget
# Python dependencies
RUN pip3 install psutil
# CVC4
RUN curl --silent "https://api.github.com/repos/CVC4/CVC4-archived/releases/latest" | grep browser_download_url | grep -E 'linux' | cut -d '"' -f 4 | wget -qi - -O /usr/local/bin/cvc4 \
&& chmod a+x /usr/local/bin/cvc4
# Z3
RUN curl --silent "https://api.github.com/repos/Z3Prover/z3/releases/36678822" | grep browser_download_url | grep -E 'ubuntu' | cut -d '"' -f 4 | wget -qi - -O z3.zip \
&& unzip -p z3.zip '*bin/z3' > /usr/local/bin/z3 \
&& chmod a+x /usr/local/bin/z3
# Get .NET
RUN wget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb \
&& dpkg -i packages-microsoft-prod.deb \
&& apt update \
&& apt install -y apt-transport-https \
&& apt update \
&& apt install -y dotnet-sdk-3.1
# Get boogie
RUN dotnet tool install --global boogie --version 2.8.18
ENV PATH="${PATH}:/root/.dotnet/tools"
# Copy solidity sourcecode, instead of cloning it
RUN mkdir solidity
COPY . solidity
RUN cd solidity \
&& mkdir -p build \
&& cd build \
&& cmake -DUSE_Z3=Off -DUSE_CVC4=Off .. \
&& make \
&& make install
# Set entrypoint
ENTRYPOINT ["solc-verify.py"]