-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
71 lines (61 loc) · 2.51 KB
/
Dockerfile
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
FROM ubuntu:18.04
ENV SMACKDIR /root/smack
ENV EMSCRIPTENDIR /root/emscripten
ENV EMSDKDIR /root/emsdk
ENV CORRALDIR /root/corral
RUN apt-get update && \
apt-get -y install \
software-properties-common \
wget \
sudo \
vim \
git
USER root
# Install smack and everything with it
RUN git clone https://github.com/smackers/smack.git $SMACKDIR
WORKDIR $SMACKDIR
# Build SMACK
RUN sudo bin/build.sh
WORKDIR /root
RUN git clone https://github.com/emscripten-core/emsdk.git $EMSDKDIR
WORKDIR $EMSDKDIR
RUN ./emsdk install 1.39.6
RUN ./emsdk activate 1.39.6
#Get the Emscripten headers
WORKDIR /root
RUN git clone https://github.com/emscripten-core/emscripten.git $EMSCRIPTENDIR
#Setup AV
WORKDIR /root
RUN git clone https://github.com/boogie-org/corral.git -b v1.0.12 $CORRALDIR
WORKDIR $CORRALDIR
RUN git submodule init
RUN git submodule update
RUN wget https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
RUN dpkg -i packages-microsoft-prod.deb
# Get aspnetcore and dotnet
RUN apt-get update && \
apt-get install -y apt-transport-https && \
apt-get update && \
apt-get install -y dotnet-sdk-5.0 && \
apt-get install -y aspnetcore-runtime-5.0 && \
apt-get install -y aspnetcore-runtime-3.1 && \
apt-get install -y dotnet-runtime-5.0 && \
apt-get install -y dotnet-runtime-3.1
#Get mono
RUN apt install -y apt-transport-https dirmngr && \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
echo "deb https://download.mono-project.com/repo/ubuntu vs-bionic main" | tee /etc/apt/sources.list.d/mono-official-vs.list && \
apt update && \
apt-get install -y monodevelop
#Build AV -- This causes an error that we dont care about
RUN msbuild AddOns/AngelicVerifierNull/AngelicVerifierNull.sln; exit 0
RUN find . -type f -name "*.exe" | xargs chmod +x
RUN ln -s /root/smack/share/smack/lib/smack.cpp /usr/local/share/smack/lib/smack.cpp
WORKDIR /root
RUN git clone https://github.com/yugeshk/CS639
WORKDIR /root/CS639
# Add envinronment
RUN echo "source /root/smack.environment" >> ~/.bashrc
RUN echo "source /root/emsdk/emsdk_env.sh" >> ~/.bashrc
RUN echo 'export PATH="/root/smack-deps/boogie:/root/smack-deps/corral:/root/smack-deps/z3:${PATH}"' >> ~/.bashrc
RUN echo 'export PATH="/root/corral/AddOns/AngelicVerifierNull/AngelicVerifierNull/bin/Debug:/root/corral/AddOns/AngelicVerifierNull/AvHarnessInstrumentation/bin/Debug:${PATH}"' >> ~/.bashrc