2019-03-01 19:06:43 -06:00
|
|
|
FROM ubuntu:18.04 as builder
|
2019-02-26 19:53:31 -06:00
|
|
|
LABEL author="Abdelrahman Hosny <abdelrahman.hosny@hotmail.com>"
|
2019-07-01 06:21:16 -05:00
|
|
|
RUN apt-get update -qq \
|
|
|
|
&& DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
|
|
|
|
ca-certificates \
|
2019-02-26 19:53:31 -06:00
|
|
|
clang \
|
|
|
|
bison \
|
2019-07-01 06:21:16 -05:00
|
|
|
build-essential \
|
2019-02-26 19:53:31 -06:00
|
|
|
flex \
|
|
|
|
gawk \
|
|
|
|
git \
|
2019-07-01 06:21:16 -05:00
|
|
|
libffi-dev \
|
|
|
|
libreadline-dev \
|
2019-02-26 19:53:31 -06:00
|
|
|
pkg-config \
|
2019-07-01 06:21:16 -05:00
|
|
|
python3 \
|
|
|
|
tcl-dev \
|
|
|
|
&& apt-get autoclean && apt-get clean && apt-get -y autoremove \
|
|
|
|
&& update-ca-certificates \
|
|
|
|
&& rm -rf /var/lib/apt/lists
|
|
|
|
|
2019-02-26 19:53:31 -06:00
|
|
|
COPY . /
|
2019-07-01 06:24:28 -05:00
|
|
|
RUN make \
|
|
|
|
&& make install \
|
|
|
|
&& mkdir dist && cp yosys yosys-abc yosys-config yosys-filterlib yosys-smtbmc dist/
|
2019-02-26 19:53:31 -06:00
|
|
|
|
2019-03-01 19:06:43 -06:00
|
|
|
FROM ubuntu:18.04
|
2019-07-01 06:21:16 -05:00
|
|
|
RUN apt-get update -qq \
|
|
|
|
&& DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
|
|
|
|
libreadline-dev \
|
|
|
|
tcl-dev
|
2019-02-26 19:53:31 -06:00
|
|
|
|
2019-07-01 06:24:28 -05:00
|
|
|
COPY --from=builder /dist /build
|
2019-02-26 19:53:31 -06:00
|
|
|
|
|
|
|
ENV PATH /build:$PATH
|
2019-03-01 19:06:43 -06:00
|
|
|
RUN useradd -m yosys
|
|
|
|
USER yosys
|
2019-02-26 19:53:31 -06:00
|
|
|
ENTRYPOINT ["yosys"]
|