mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-17 16:47:50 +00:00
The scripts installing dependencies are now copied and executed before copying the full source tree. This allows to cache the dependency installation layers as long as these scripts remain unchanged. Previously, copying the entire repository invalidated the cache on every source change. While our CI intentionally doesn't preserve cached layers across independent runs, the changes in this patch help with local testing when investigating issues. Examples: - sudo -E make -C scripts/ci alpine GCC=1 - sudo -E make -C scripts/ci alpine CLANG=1 Suggested-by: Andrei Vagin <avagin@google.com> Signed-off-by: Radostin Stoyanov <rstoyanov@fedoraproject.org>
25 lines
851 B
Cheetah
25 lines
851 B
Cheetah
ARG CC=gcc
|
|
|
|
COPY contrib/dependencies/apt-cross-packages.sh /criu/contrib/dependencies/apt-cross-packages.sh
|
|
COPY contrib/apt-install /criu/contrib/apt-install
|
|
WORKDIR /criu
|
|
RUN /criu/contrib/apt-install "$CC" && /criu/contrib/dependencies/apt-packages.sh
|
|
|
|
COPY . /criu
|
|
|
|
RUN uname -m && setarch linux32 uname -m && setarch --list
|
|
|
|
RUN make mrproper && date && \
|
|
# Check single object build
|
|
setarch linux32 make -j $(nproc) CC="$CC" criu/parasite-syscall.o && \
|
|
# Compile criu
|
|
setarch linux32 make -j $(nproc) CC="$CC" && \
|
|
date && \
|
|
# Check that "make mrproper" works
|
|
setarch linux32 make mrproper && ! git clean -ndx --exclude=scripts/build \
|
|
--exclude=.config --exclude=test | grep .
|
|
|
|
# Compile tests
|
|
RUN date && setarch linux32 make -j $(nproc) CC="$CC" -C test/zdtm && date
|
|
|
|
#RUN make test/compel/handle_binary && ./test/compel/handle_binary
|