You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
3.6 KiB

3 years ago
  1. FROM debian:buster-slim as yosys
  2. ## YOSYS ##
  3. # Get yosys dependencies
  4. RUN apt-get update -qq && \
  5. DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
  6. ca-certificates \
  7. gcc \
  8. make \
  9. bison \
  10. flex \
  11. libreadline-dev \
  12. gawk \
  13. tcl-dev \
  14. libffi-dev \
  15. graphviz \
  16. xdot \
  17. pkg-config \
  18. python3 \
  19. libboost-system-dev \
  20. libboost-python-dev \
  21. libboost-filesystem-dev \
  22. clang \
  23. curl \
  24. git && \
  25. apt-get autoclean && apt-get clean && apt-get -y autoremove && \
  26. update-ca-certificates && \
  27. rm -rf /var/lib/apt/lists/* && \
  28. cd /root && \
  29. git clone https://github.com/YosysHQ/yosys.git yosys && \
  30. cd yosys && \
  31. make -j$(nproc) PREFIX=/opt/yosys && \
  32. make install PREFIX=/opt/yosys && \
  33. mkdir /opt/yosys/doc && \
  34. curl https://github.com/YosysHQ/yosys-manual-build/releases/download/manual/manual.pdf -o /opt/yosys/doc/yosys_manual.pdf
  35. # SymbiYosys, Solvers
  36. FROM yosys AS symbiyosys
  37. COPY packages/suprove /root/suprove
  38. RUN apt-get update -qq && \
  39. DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
  40. autoconf \
  41. gperf \
  42. cmake \
  43. libgmp-dev \
  44. ninja-build \
  45. g++ \
  46. python-setuptools \
  47. python-pip \
  48. python-wheel \
  49. mercurial && \
  50. apt-get autoclean && apt-get clean && apt-get -y autoremove && \
  51. rm -rf /var/lib/apt/lists/* && \
  52. cd /root && \
  53. git clone https://github.com/YosysHQ/SymbiYosys.git symbiyosys && \
  54. cd symbiyosys && \
  55. make install PREFIX=/opt/symbiyosys && \
  56. mkdir /opt/symbiyosys/doc && \
  57. curl https://symbiyosys.readthedocs.io/_/downloads/en/latest/pdf/ -o /opt/symbiyosys/doc/symbiyosys_manual.pdf && \
  58. cd .. && \
  59. git clone https://github.com/Z3Prover/z3.git z3 && \
  60. cd z3 && \
  61. python scripts/mk_make.py && \
  62. cd build && \
  63. make -j$(nproc) PREFIX=/opt/z3 && \
  64. make install PREFIX=/opt/z3 && \
  65. cd /root && \
  66. git clone https://github.com/SRI-CSL/yices2.git yices2 && \
  67. cd yices2 && \
  68. autoconf && \
  69. ./configure --prefix=/opt/yices2 && \
  70. make -j$(nproc) && \
  71. make install && \
  72. cd /opt && \
  73. mkdir cvc4 && mkdir cvc4/bin && \
  74. curl -L -o cvc4/bin/cvc4 https://github.com/CVC4/CVC4/releases/download/1.7/cvc4-1.7-x86_64-linux-opt && \
  75. chmod +x cvc4/bin/cvc4 && \
  76. cd /root && \
  77. git clone https://github.com/boolector/boolector && \
  78. cd boolector && \
  79. ./contrib/setup-btor2tools.sh && \
  80. ./contrib/setup-lingeling.sh && \
  81. ./configure.sh && \
  82. make -C build -j$(nproc) PREFIX=/opt/boolector && \
  83. cd /root/boolector && \
  84. mkdir /opt/boolector && \
  85. mkdir /opt/boolector/bin && \
  86. cp build/bin/boolector /opt/boolector/bin/ && \
  87. cp build/bin/btor* /opt/boolector/bin/ && \
  88. cp deps/btor2tools/bin/btorsim /opt/boolector/bin/ && \
  89. cd /root && \
  90. git clone https://github.com/bitwuzla/bitwuzla && \
  91. cd bitwuzla && \
  92. ./contrib/setup-btor2tools.sh && \
  93. ./contrib/setup-lingeling.sh && \
  94. ./contrib/setup-symfpu.sh && \
  95. ./configure.sh && \
  96. make -C build -j$(nproc) PREFIX=/opt/bitwuzla && \
  97. mkdir -p /opt/bitwuzla/bin && \
  98. cp build/bin/bitwuzla /opt/bitwuzla/bin/ && \
  99. cd /root && \
  100. git clone --recursive https://github.com/sterin/super-prove-build && \
  101. cd super-prove-build && \
  102. mkdir build && \
  103. cd build && \
  104. cmake -DCMAKE_BUILD_TYPE=Release -G Ninja .. && \
  105. ninja && \
  106. ninja package && \
  107. tar -C /opt -xzf super_prove*.tar.gz && \
  108. mv /root/suprove /opt/super_prove/bin/ && \
  109. chmod +x /opt/super_prove/bin/suprove && \
  110. rm -rf /root/*