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.

130 lines
4.0 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. COPY packages/avy.patch /root/avy.patch
  39. RUN apt-get update -qq && \
  40. DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
  41. autoconf \
  42. gperf \
  43. cmake \
  44. libgmp-dev \
  45. ninja-build \
  46. g++ \
  47. python-setuptools \
  48. python-pip \
  49. python-wheel \
  50. libboost-program-options-dev \
  51. mercurial && \
  52. apt-get autoclean && apt-get clean && apt-get -y autoremove && \
  53. rm -rf /var/lib/apt/lists/* && \
  54. cd /root && \
  55. git clone https://github.com/YosysHQ/SymbiYosys.git symbiyosys && \
  56. cd symbiyosys && \
  57. make install PREFIX=/opt/symbiyosys && \
  58. mkdir /opt/symbiyosys/doc && \
  59. curl https://symbiyosys.readthedocs.io/_/downloads/en/latest/pdf/ -o /opt/symbiyosys/doc/symbiyosys_manual.pdf && \
  60. cd .. && \
  61. git clone https://github.com/Z3Prover/z3.git z3 && \
  62. cd z3 && \
  63. python scripts/mk_make.py && \
  64. cd build && \
  65. make -j$(nproc) PREFIX=/opt/z3 && \
  66. make install PREFIX=/opt/z3 && \
  67. cd /root && \
  68. git clone https://github.com/SRI-CSL/yices2.git yices2 && \
  69. cd yices2 && \
  70. autoconf && \
  71. ./configure --prefix=/opt/yices2 && \
  72. make -j$(nproc) && \
  73. make install && \
  74. cd /opt && \
  75. mkdir cvc4 && mkdir cvc4/bin && \
  76. curl -L -o cvc4/bin/cvc4 https://github.com/CVC4/CVC4/releases/download/1.7/cvc4-1.7-x86_64-linux-opt && \
  77. chmod +x cvc4/bin/cvc4 && \
  78. cd /root && \
  79. git clone https://github.com/boolector/boolector && \
  80. cd boolector && \
  81. ./contrib/setup-btor2tools.sh && \
  82. ./contrib/setup-lingeling.sh && \
  83. ./configure.sh && \
  84. make -C build -j$(nproc) PREFIX=/opt/boolector && \
  85. cd /root/boolector && \
  86. mkdir /opt/boolector && \
  87. mkdir /opt/boolector/bin && \
  88. cp build/bin/boolector /opt/boolector/bin/ && \
  89. cp build/bin/btor* /opt/boolector/bin/ && \
  90. cp deps/btor2tools/bin/btorsim /opt/boolector/bin/ && \
  91. cd /root && \
  92. git clone https://github.com/bitwuzla/bitwuzla && \
  93. cd bitwuzla && \
  94. ./contrib/setup-btor2tools.sh && \
  95. ./contrib/setup-lingeling.sh && \
  96. ./contrib/setup-symfpu.sh && \
  97. ./configure.sh && \
  98. make -C build -j$(nproc) PREFIX=/opt/bitwuzla && \
  99. mkdir -p /opt/bitwuzla/bin && \
  100. cp build/bin/bitwuzla /opt/bitwuzla/bin/ && \
  101. cd /root && \
  102. git clone --recursive https://github.com/sterin/super-prove-build && \
  103. cd super-prove-build && \
  104. mkdir build && \
  105. cd build && \
  106. cmake -DCMAKE_BUILD_TYPE=Release -G Ninja .. && \
  107. ninja && \
  108. ninja package && \
  109. tar -C /opt -xzf super_prove*.tar.gz && \
  110. mv /root/suprove /opt/super_prove/bin/ && \
  111. chmod +x /opt/super_prove/bin/suprove
  112. RUN cd /root && \
  113. git clone https://bitbucket.org/arieg/extavy.git && \
  114. cd extavy && \
  115. git checkout new_quip && \
  116. git submodule update --init && \
  117. mkdir build; cd build && \
  118. cmake -DCMAKE_BUILD_TYPE=Debug .. && \
  119. make -j$(nproc) && \
  120. mkdir -p /opt/avy/bin && \
  121. cp -r avy/src/av* /opt/avy/bin/ && \
  122. rm -rf /root/*