mirror of
https://github.com/dashpay/dash.git
synced 2024-12-24 11:32:46 +01:00
ci: don't stage packages in /tmp
, reduce layers for cppcheck
build
This commit is contained in:
parent
eef863554a
commit
187fe17650
@ -111,10 +111,28 @@ RUN pip3 install \
|
||||
pyzmq==22.3.0 \
|
||||
vulture==2.3
|
||||
|
||||
# dash_hash
|
||||
ARG DASH_HASH_VERSION=1.4.0
|
||||
RUN git clone --depth 1 --no-tags --branch=${DASH_HASH_VERSION} https://github.com/dashpay/dash_hash
|
||||
RUN cd dash_hash && pip3 install -r requirements.txt .
|
||||
RUN set -ex; \
|
||||
cd /tmp; \
|
||||
git clone --depth 1 --no-tags --branch=${DASH_HASH_VERSION} https://github.com/dashpay/dash_hash; \
|
||||
cd dash_hash && pip3 install -r requirements.txt .; \
|
||||
cd .. && rm -rf dash_hash
|
||||
|
||||
ARG CPPCHECK_VERSION=2.13.0
|
||||
RUN set -ex; \
|
||||
curl -fL "https://github.com/danmar/cppcheck/archive/${CPPCHECK_VERSION}.tar.gz" -o /tmp/cppcheck.tar.gz; \
|
||||
mkdir -p /opt/cppcheck && tar -xzf /tmp/cppcheck.tar.gz -C /opt/cppcheck --strip-components=1 && rm /tmp/cppcheck.tar.gz; \
|
||||
cd /opt/cppcheck; \
|
||||
mkdir build && cd build && cmake .. && cmake --build . -j "$(( $(nproc) - 1 ))"; \
|
||||
mkdir /usr/local/share/Cppcheck && ln -s /opt/cppcheck/cfg/ /usr/local/share/Cppcheck/cfg; \
|
||||
rm -rf /tmp/cppcheck.tar.gz
|
||||
ENV PATH="/opt/cppcheck/build/bin:${PATH}"
|
||||
|
||||
ARG SHELLCHECK_VERSION=v0.7.1
|
||||
RUN set -ex; \
|
||||
curl -fL "https://github.com/koalaman/shellcheck/releases/download/${SHELLCHECK_VERSION}/shellcheck-${SHELLCHECK_VERSION}.linux.x86_64.tar.xz" -o /tmp/shellcheck.tar.xz; \
|
||||
mkdir -p /opt/shellcheck && tar -xf /tmp/shellcheck.tar.xz -C /opt/shellcheck --strip-components=1 && rm /tmp/shellcheck.tar.xz
|
||||
ENV PATH="/opt/shellcheck:${PATH}"
|
||||
|
||||
# Add user with specified (or default) user/group ids and setup configuration files
|
||||
ARG USER_ID=1000
|
||||
@ -144,16 +162,6 @@ RUN apt-get update && apt-get install $APT_ARGS \
|
||||
xorriso \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ARG CPPCHECK_VERSION=2.13.0
|
||||
RUN curl -sL "https://github.com/danmar/cppcheck/archive/${CPPCHECK_VERSION}.tar.gz" | tar -xvzf - --directory /tmp/
|
||||
RUN cd /tmp/cppcheck-${CPPCHECK_VERSION} && mkdir build && cd build && cmake .. && cmake --build . -j 8
|
||||
ENV PATH="/tmp/cppcheck-${CPPCHECK_VERSION}/build/bin:${PATH}"
|
||||
RUN mkdir /usr/local/share/Cppcheck && ln -s /tmp/cppcheck-${CPPCHECK_VERSION}/cfg/ /usr/local/share/Cppcheck/cfg
|
||||
|
||||
ARG SHELLCHECK_VERSION=v0.7.1
|
||||
RUN curl -sL "https://github.com/koalaman/shellcheck/releases/download/${SHELLCHECK_VERSION}/shellcheck-${SHELLCHECK_VERSION}.linux.x86_64.tar.xz" | tar --xz -xf - --directory /tmp/
|
||||
ENV PATH="/tmp/shellcheck-${SHELLCHECK_VERSION}:${PATH}"
|
||||
|
||||
# This is a hack. It is needed because gcc-multilib and g++-multilib are conflicting with g++-arm-linux-gnueabihf. This is
|
||||
# due to gcc-multilib installing the following symbolic link, which is needed for -m32 support. However, this causes
|
||||
# arm builds to also have the asm folder implicitly in the include search path. This is kind of ok, because the asm folder
|
||||
|
Loading…
Reference in New Issue
Block a user