qemu: Apply patches for specific versions.

Today we apply patches per base branch. Having
two qemu versions in a similar base version can make
can have problems if one of the trees already has a patch.
If a patch is needed only for one specific tag/commit
add only the patch to that version.

Signed-off-by: Carlos Venegas <jos.c.venegas.munoz@intel.com>
This commit is contained in:
Carlos Venegas 2021-03-19 16:14:21 +00:00
parent a09e58fa80
commit 98d01ce6b9
7 changed files with 3 additions and 0 deletions

View File

@ -59,9 +59,12 @@ ADD qemu /root/kata_qemu
ADD scripts/apply_patches.sh /root/apply_patches.sh ADD scripts/apply_patches.sh /root/apply_patches.sh
ADD static-build /root/static-build ADD static-build /root/static-build
RUN echo "Apply patches for base version"
RUN stable_branch=$(cat VERSION | awk 'BEGIN{FS=OFS="."}{print $1 "." $2 ".x"}') && \ RUN stable_branch=$(cat VERSION | awk 'BEGIN{FS=OFS="."}{print $1 "." $2 ".x"}') && \
/root/apply_patches.sh "/root/kata_qemu/patches/${stable_branch}" /root/apply_patches.sh "/root/kata_qemu/patches/${stable_branch}"
RUN echo "Apply patches for specific qemu version"
RUN /root/apply_patches.sh "/root/kata_qemu/patches/tag_patches/${QEMU_VERSION}"
RUN PREFIX="${PREFIX}" /root/configure-hypervisor.sh -s kata-qemu | xargs ./configure \ RUN PREFIX="${PREFIX}" /root/configure-hypervisor.sh -s kata-qemu | xargs ./configure \
--with-pkgversion=kata-static --with-pkgversion=kata-static