From: "Alex Bennée" <alex.bennee@linaro.org>
To: Richard Henderson <richard.henderson@linaro.org>
Cc: marex@denx.de, crwulff@gmail.com, qemu-devel@nongnu.org,
laurent@vivier.eu
Subject: Re: [PATCH 1/9] tests/docker: Add debian-nios2-cross image
Date: Thu, 14 Oct 2021 18:25:46 +0100 [thread overview]
Message-ID: <87tuhito6u.fsf@linaro.org> (raw)
In-Reply-To: <71e6a11a-2c64-24e2-1883-2c352475fd9a@linaro.org>
Richard Henderson <richard.henderson@linaro.org> writes:
> On 10/12/21 10:03 AM, Alex Bennée wrote:
>> We need^H^H^H^H (might need, see bellow) a separate patch with:
>> docker-image-debian10: NOUSER=1
>> to ensure the images we base our "handbuilt" compilers on don't
>> include
>> a potentially clashing uid (which should only be added for local
>> builds).
>
> I think we ought to push this further back into docker.py.
>
> I think that we should always have a separate image without the user
> installed. When asking for a build with user installed, copy the
> nouser image (perhaps cached) and simply add the user.
>
>> We need to split this like in hexagon and have a second stage which does
>> a:
>> COPY --from=0 /usr/local /usr/local
>> This will limit the size of the final image (and also avoid
>> duplicting
>> the UID in the hexagon build).
>
> What are we eliminating from the image with the second FROM, since we
> then go back and add in all the build-dep for qemu.
>
> There are one or two extra packages required for building gcc itself
> (e.g. libmpc) but they're not large. Where does the major savings
> come from?
Hmm that is curious:
$ docker history registry.gitlab.com/qemu-project/qemu/qemu/debian-nios2-cross:latest
...
<missing> 2 weeks ago RUN /bin/sh -c id rth 2>/dev/null || useradd… 330kB buildkit.dockerfile.v0
<missing> 2 weeks ago LABEL com.qemu./home/rth/qemu/git-alt/tests/… 0B buildkit.dockerfile.v0
<missing> 2 weeks ago LABEL com.qemu.dockerfile-checksum=fc3e779ae… 0B buildkit.dockerfile.v0
<missing> 2 weeks ago ENV PATH=/usr/local/sbin:/usr/local/bin:/usr… 0B buildkit.dockerfile.v0
<missing> 2 weeks ago RUN /bin/sh -c cd /root && ./build-toolchain… 973MB buildkit.dockerfile.v0
<missing> 2 weeks ago ADD build-toolchain.sh /root/build-toolchain… 2.14kB buildkit.dockerfile.v0
<missing> 2 weeks ago RUN /bin/sh -c apt update && DEBIAN_FRON… 17.3MB buildkit.dockerfile.v0
<missing> 2 weeks ago /bin/sh -c #(nop) LABEL com.qemu.dockerfile… 0B
<missing> 2 weeks ago /bin/sh -c apt update && DEBIAN_FRONTEND… 715MB
<missing> 2 weeks ago /bin/sh -c cat /etc/apt/sources.list | sed "… 854B
<missing> 2 weeks ago /bin/sh -c #(nop) CMD ["bash"] 0B
<missing> 2 weeks ago /bin/sh -c #(nop) ADD file:99db7cfe7952a1c7a… 69.2MB
yet with the split build:
$ docker image history qemu/debian-nios2-cross:latest
IMAGE CREATED CREATED BY SIZE COMMENT
24fbdeba931c 4 hours ago LABEL com.qemu./home/alex.bennee/lsrc/qemu.g… 0B buildkit.dockerfile.v0
<missing> 4 hours ago LABEL com.qemu.dockerfile-checksum=e7d3631e6… 0B buildkit.dockerfile.v0
<missing> 4 hours ago ENV PATH=/usr/local/sbin:/usr/local/bin:/usr… 0B buildkit.dockerfile.v0
<missing> 4 hours ago COPY /usr/local /usr/local # buildkit 1.77GB buildkit.dockerfile.v0
<missing> 4 hours ago RUN /bin/sh -c apt update && DEBIAN_FRON… 781MB buildkit.dockerfile.v0
<missing> 4 hours ago RUN /bin/sh -c cat /etc/apt/sources.list | s… 854B buildkit.dockerfile.v0
<missing> 7 months ago /bin/sh -c #(nop) CMD ["bash"] 0B
<missing> 7 months ago /bin/sh -c #(nop) ADD file:3c32f1cd03198e141… 69.2MB
which makes it look like the artefacts are bigger than the whole build.
--
Alex Bennée
next prev parent reply other threads:[~2021-10-15 13:27 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-01 15:33 [PATCH 0/9] nios2: Enable cross compile and fix signals Richard Henderson
2021-10-01 15:33 ` [PATCH 1/9] tests/docker: Add debian-nios2-cross image Richard Henderson
2021-10-12 17:03 ` Alex Bennée
2021-10-12 18:24 ` Richard Henderson
2021-10-12 18:33 ` Alex Bennée
2021-10-14 9:34 ` Alex Bennée
2021-10-14 17:17 ` Richard Henderson
2021-10-14 17:25 ` Alex Bennée [this message]
2021-10-01 15:33 ` [PATCH 1/2] tests/docker: Remove fedora-i386-cross from DOCKER_PARTIAL_IMAGES Richard Henderson
2021-10-14 9:35 ` Alex Bennée
2021-10-01 15:33 ` [PATCH 2/9] linux-user/nios2: Properly emulate EXCP_TRAP Richard Henderson
2021-10-14 9:36 ` Alex Bennée
2021-10-01 15:33 ` [PATCH 2/2] tests/docker: Fix fedora-i386-cross Richard Henderson
2021-10-14 9:38 ` Alex Bennée
2021-10-01 15:33 ` [PATCH 3/9] linux-user/nios2: Fixes for signal frame setup Richard Henderson
2021-10-14 9:43 ` Alex Bennée
2021-10-01 15:33 ` [PATCH 4/9] linux-user/elfload: Rename ARM_COMMPAGE to HI_COMMPAGE Richard Henderson
2021-10-12 6:11 ` Laurent Vivier
2021-10-01 15:33 ` [PATCH 5/9] linux-user/nios2: Map a real kuser page Richard Henderson
2021-10-01 15:33 ` [PATCH 6/9] linux-user/nios2: Fix EA vs PC confusion Richard Henderson
2021-10-01 15:33 ` [PATCH 7/9] linux-user/nios2: Fix sigmask in setup_rt_frame Richard Henderson
2021-10-12 6:16 ` Laurent Vivier
2021-10-01 15:33 ` [PATCH 8/9] linux-user/nios2: Use set_sigmask in do_rt_sigreturn Richard Henderson
2021-10-12 6:29 ` Laurent Vivier
2021-10-01 15:33 ` [PATCH 9/9] tests/tcg: Enable container_cross_cc for nios2 Richard Henderson
2021-10-11 19:06 ` [PATCH 0/9] nios2: Enable cross compile and fix signals Richard Henderson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87tuhito6u.fsf@linaro.org \
--to=alex.bennee@linaro.org \
--cc=crwulff@gmail.com \
--cc=laurent@vivier.eu \
--cc=marex@denx.de \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.