mirror of https://github.com/acidanthera/audk.git
OvmfPkg/build.sh: Enable flash for QEMU >= 1.6
If the QEMU version is found to be >= 1.6, then automatically enable flash (using the QEMU pflash command line parameter). QEMU supports flash since 1.2, but only if KVM is disabled. As of QEMU 1.6, flash support should also be enabled when KVM is used. Therefore it is safest to only enable flash for QEMU 1.6 and newer. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14842 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
bc9be821c7
commit
d48ec970ad
|
@ -179,6 +179,14 @@ if [ -z "$PLATFORMFILE" ]; then
|
|||
PLATFORMFILE=$WORKSPACE/OvmfPkg/OvmfPkg$Processor.dsc
|
||||
fi
|
||||
|
||||
if [[ "$RUN_QEMU" == "yes" ]]; then
|
||||
qemu_version=$($QEMU_COMMAND -version 2>&1 | tail -1 | awk '{print $4}')
|
||||
case $qemu_version in
|
||||
1.[6-9].*|1.[1-9][0-9].*|2.*.*)
|
||||
ENABLE_FLASH=yes
|
||||
;;
|
||||
esac
|
||||
|
||||
ADD_QEMU_HDA=yes
|
||||
for arg in "$@"
|
||||
do
|
||||
|
@ -189,6 +197,7 @@ do
|
|||
;;
|
||||
esac
|
||||
done
|
||||
fi
|
||||
|
||||
#
|
||||
# Uncomment this block for parameter parsing debug
|
||||
|
|
Loading…
Reference in New Issue