Reduce size of git clone and use all cores in make

This commit is contained in:
2025-10-05 12:45:18 +02:00
parent dab784a40e
commit 0dfd6a825f

View File

@@ -32,9 +32,9 @@ RUN apk add yosys
WORKDIR /home/root/aur-install
# Install prjxray librairies
RUN git clone https://github.com/supersurviveur/prjxray.git && \
RUN git clone https://github.com/supersurviveur/prjxray.git --depth 1 && \
cd prjxray && \
git submodule update --init && \
git submodule update --init --depth 1 && \
# include fasm2frames in python package
mv utils/fasm2frames.py prjxray/ && \
sed -E 's/(fasm2frames=)utils/\1prjxray/' -i setup.py && \
@@ -44,7 +44,7 @@ RUN git clone https://github.com/supersurviveur/prjxray.git && \
-DCMAKE_INSTALL_PREFIX='/usr' \
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
-Wno-dev && \
cmake --build build && \
cmake --build build -j$(nproc) && \
python -m build --wheel --no-isolation --skip-dependency-check && \
python -m installer dist/*.whl && \
python -m build third_party/fasm --wheel --no-isolation --skip-dependency-check && \
@@ -54,7 +54,7 @@ RUN git clone https://github.com/supersurviveur/prjxray.git && \
RUN pip install textx --break-system-packages
# Install the zynq7 prjxray database
RUN git clone https://github.com/f4pga/prjxray-db.git && \
RUN git clone https://github.com/f4pga/prjxray-db.git --depth 1 && \
cd prjxray-db && \
install -dm 755 /usr/share/xray/database && \
cp -r zynq7 /usr/share/xray/database/ && \
@@ -62,9 +62,9 @@ RUN git clone https://github.com/f4pga/prjxray-db.git && \
rm /usr/share/xray/database/zynq7/xc7z020 -rf
# Install nextpnr-himbaechel
RUN git clone https://github.com/YosysHQ/nextpnr && \
RUN git clone https://github.com/YosysHQ/nextpnr --depth 1 && \
cd nextpnr && \
git submodule update --remote --init himbaechel/uarch/xilinx/meta && \
git submodule update --remote --init --depth 1 himbaechel/uarch/xilinx/meta && \
cmake -S "." -B build \
-DARCH=himbaechel \
-DHIMBAECHEL_UARCH=xilinx \
@@ -75,12 +75,12 @@ RUN git clone https://github.com/YosysHQ/nextpnr && \
-DCMAKE_BUILD_TYPE=None \
-DCMAKE_INSTALL_PREFIX=/usr \
-DUSE_OPENMP=ON && \
make -C build
make -C build -j$(nproc)
# Install sv2v
RUN git clone https://github.com/zachjs/sv2v && \
RUN git clone https://github.com/zachjs/sv2v --depth 1 && \
cd sv2v && \
make
make -j$(nproc)
COPY copy_bin_deps.sh /usr/bin/
RUN chmod +x /usr/bin/copy_bin_deps.sh