-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
55 lines (45 loc) · 1.2 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
FROM msoos/cryptominisat:latest
LABEL maintainer="Mate Soos"
LABEL version="1.0"
LABEL Description="An advanced SMT solver"
# get curl, etc
USER root
RUN apt-get update && apt-get install --no-install-recommends -y bison flex \
&& rm -rf /var/lib/apt/lists/*
# get M4RI
# RUN wget https://bitbucket.org/malb/m4ri/downloads/m4ri-20140914.tar.gz \
# && tar -xvf m4ri-20140914.tar.gz
# WORKDIR m4ri-20140914
# RUN ./configure \
# && make \
# && make install \
# && make clean
# build minisat
RUN mkdir -p /home/solver/
WORKDIR /home/solver/
RUN wget https://github.com/msoos/minisat/archive/2.2.1.tar.gz \
&& tar xvf 2.2.1.tar.gz
WORKDIR /home/solver/minisat-2.2.1/
RUN mkdir build && cd build && cmake .. \
&& make -j6 \
&& make install \
&& cd .. \
&& rm -rf build
# build stp
COPY . /home/solver/stp
WORKDIR /home/solver/stp
RUN mkdir build
WORKDIR /home/solver/stp/build
RUN cmake .. \
&& make -j6 \
&& make install \
&& rm -rf *
# set up for running
USER solver
WORKDIR /home/solver/
ENTRYPOINT ["stp", "--SMTLIB2"]
# --------------------
# HOW TO USE
# --------------------
# on file through STDIN:
# cat myfile.smt | docker run --rm -i -a stdin -a stdout stp