mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-20 09:39:08 +00:00
kernel: Improve kconfig Docker file
Be a bit more verbose and error on error. Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This commit is contained in:
parent
aec0d5a702
commit
0f5825fc32
@ -15,7 +15,8 @@ ARG KERNEL_VERSIONS
|
|||||||
COPY / /
|
COPY / /
|
||||||
|
|
||||||
# Unpack kernels (download if not present)
|
# Unpack kernels (download if not present)
|
||||||
RUN for VERSION in ${KERNEL_VERSIONS}; do \
|
RUN set -e && for VERSION in ${KERNEL_VERSIONS}; do \
|
||||||
|
echo "Downloading/Unpacking $VERSION" && \
|
||||||
KERNEL_SOURCE=https://www.kernel.org/pub/linux/kernel/v4.x/linux-${VERSION}.tar.xz && \
|
KERNEL_SOURCE=https://www.kernel.org/pub/linux/kernel/v4.x/linux-${VERSION}.tar.xz && \
|
||||||
[ -f sources/linux-${VERSION}.tar.xz ] || curl -fSLo sources/linux-${VERSION}.tar.xz ${KERNEL_SOURCE} && \
|
[ -f sources/linux-${VERSION}.tar.xz ] || curl -fSLo sources/linux-${VERSION}.tar.xz ${KERNEL_SOURCE} && \
|
||||||
tar xf sources/linux-${VERSION}.tar.xz; \
|
tar xf sources/linux-${VERSION}.tar.xz; \
|
||||||
@ -24,8 +25,9 @@ RUN for VERSION in ${KERNEL_VERSIONS}; do \
|
|||||||
# Apply patches to all kernels and move config files into place
|
# Apply patches to all kernels and move config files into place
|
||||||
RUN for VERSION in ${KERNEL_VERSIONS}; do \
|
RUN for VERSION in ${KERNEL_VERSIONS}; do \
|
||||||
SERIES=${VERSION%.*}.x && \
|
SERIES=${VERSION%.*}.x && \
|
||||||
|
echo "Patching $VERSION" && \
|
||||||
cd /linux-${VERSION} && \
|
cd /linux-${VERSION} && \
|
||||||
for patch in /patches-${SERIES}/*.patch; do \
|
set -e && for patch in /patches-${SERIES}/*.patch; do \
|
||||||
echo "Applying $patch" && \
|
echo "Applying $patch" && \
|
||||||
patch -p1 < "$patch"; \
|
patch -p1 < "$patch"; \
|
||||||
done && \
|
done && \
|
||||||
|
Loading…
Reference in New Issue
Block a user