Skip to content

Commit f235036

Browse files
committed
builds: get source code through git clone to derive version strings later
1 parent 4cdb1a4 commit f235036

File tree

4 files changed

+11
-13
lines changed

4 files changed

+11
-13
lines changed

base.dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ FROM base AS build
1616
RUN apt-get update -qq \
1717
&& DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
1818
clang \
19+
git \
1920
make
2021

2122
ENV CC clang

ghdl-yosys-plugin.dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ FROM hdlc/yosys AS base
22

33
RUN apt-get update -qq \
44
&& DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
5+
git \
56
libgnat-8 \
67
&& apt-get autoclean && apt-get clean && apt-get -y autoremove \
78
&& rm -rf /var/lib/apt/lists
@@ -12,8 +13,7 @@ FROM base AS plugin
1213

1314
COPY --from=hdlc/pkg:ghdl /ghdl /opt/ghdl
1415

15-
RUN mkdir /tmp/ghdl-yosys-plugin && cd /tmp/ghdl-yosys-plugin \
16-
&& curl -fsSL https://codeload.github.com/ghdl/ghdl-yosys-plugin/tar.gz/master | tar xzf - --strip-components=1
16+
RUN git clone https://github.com/ghdl/ghdl-yosys-plugin.git /tmp/ghdl-yosys-plugin
1717

1818
RUN cp -vr /opt/ghdl/* / \
1919
&& cd /tmp/ghdl-yosys-plugin \

nextpnr.dockerfile

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,9 @@ RUN apt-get update -qq \
1212
FROM build AS build-ice40
1313
COPY --from=hdlc/pkg:icestorm /icestorm/usr/local/share/icebox /usr/local/share/icebox
1414

15-
RUN mkdir -p /tmp/nextpnr/build \
16-
&& cd /tmp/nextpnr \
17-
&& curl -fsSL https://codeload.github.com/YosysHQ/nextpnr/tar.gz/master | tar xzf - --strip-components=1 \
18-
&& cd build \
15+
RUN git clone --depth 1 https://github.com/YosysHQ/nextpnr.git /tmp/nextpnr \
16+
&& mkdir /tmp/nextpnr/build/ \
17+
&& cd /tmp/nextpnr/build \
1918
&& cmake .. \
2019
-DARCH=ice40 \
2120
-DBUILD_GUI=OFF \
@@ -29,10 +28,9 @@ RUN mkdir -p /tmp/nextpnr/build \
2928
FROM build AS build-ecp5
3029
COPY --from=hdlc/pkg:prjtrellis /prjtrellis /
3130

32-
RUN mkdir -p /tmp/nextpnr/build \
33-
&& cd /tmp/nextpnr \
34-
&& curl -fsSL https://codeload.github.com/YosysHQ/nextpnr/tar.gz/master | tar xzf - --strip-components=1 \
35-
&& cd build \
31+
RUN git clone --depth 1 https://github.com/YosysHQ/nextpnr.git /tmp/nextpnr \
32+
&& mkdir /tmp/nextpnr/build/ \
33+
&& cd /tmp/nextpnr/build \
3634
&& cmake .. \
3735
-DARCH=ecp5 \
3836
-DBUILD_GUI=OFF \

yosys.dockerfile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,14 @@ RUN apt-get update -qq \
2020
flex \
2121
gawk \
2222
gcc \
23-
git \
2423
iverilog \
2524
pkg-config \
2625
zlib1g-dev \
2726
&& apt-get autoclean && apt-get clean && apt-get -y autoremove \
2827
&& rm -rf /var/lib/apt/lists/*
2928

30-
RUN mkdir /tmp/yosys && cd /tmp/yosys \
31-
&& curl -fsSL https://codeload.github.com/YosysHQ/yosys/tar.gz/master | tar xzf - --strip-components=1 \
29+
RUN git clone --depth 1 https://github.com/YosysHQ/yosys.git /tmp/yosys \
30+
&& cd /tmp/yosys \
3231
&& make -j $(nproc) \
3332
&& make DESTDIR=/opt/yosys install \
3433
&& make test

0 commit comments

Comments
 (0)