Source
FROM scratch AS build
ARG VERSION
COPY --from=stagex/core-busybox . /
COPY --from=stagex/core-binutils . /
COPY --from=stagex/core-musl . /
COPY --from=stagex/core-make . /
COPY --from=stagex/core-tar . /
COPY --from=stagex/core-lzip . /
COPY --from=stagex/core-gcc . /
ADD fetch/ed-${VERSION}.tar.lz .
RUN tar --lzip -xf ed-${VERSION}.tar.lz
WORKDIR /ed-${VERSION}
RUN --network=none <<-EOF
set -ex
./configure \
--prefix=/usr \
--bindir=/usr/bin \
--mandir=/usr/share/man
make -j "$(nproc)"
make DESTDIR="/rootfs" install
EOF
FROM stagex/core-filesystem AS package
COPY --from=build /rootfs/ /