Changes between Version 67 and Version 68 of Developer/Simulators/QEMU


Ignore:
Timestamp:
Mar 27, 2018, 4:39:15 AM (22 months ago)
Author:
Amaan Cheval
Comment:

Instructions on booting UEFI firmware in QEMU through OVMF

Legend:

Unmodified
Added
Removed
Modified
  • Developer/Simulators/QEMU

    v67 v68  
    508508--[wiki:User:JoelSherrill Dr. Joel] 13:25, 10 March 2007 (CST)
    509509
     510=  QEMU and UEFI (using OVMF / EDK II)  =
     511
     512[https://github.com/tianocore/tianocore.github.io/wiki/How-to-build-OVMF OVMF Build instructions are available here]. Duplicated for completeness:
     513
     514
     515{{{
     516$ git clone git://github.com/tianocore/edk2.git
     517$ cd edk2
     518$ make -C BaseTools
     519$ . edksetup.sh
     520}}}
     521
     522Then edit `Conf/target.txt` to set the following values:
     523
     524{{{
     525ACTIVE_PLATFORM       = OvmfPkg/OvmfPkgX64.dsc
     526TARGET                = DEBUG
     527TARGET_ARCH           = X64
     528# You can use GCC46 as well, if you'd prefer
     529TOOL_CHAIN_TAG        = GCC5
     530}}}
     531
     532Then run `build` in the `edk2` directory - the output should list the location of the `OVMF.fd` file, which can be used with QEMU to boot into a UEFI shell [https://github.com/tianocore/tianocore.github.io/wiki/How-to-run-OVMF as instructed here].
     533
     534You can find the `OVMF.fd` file like this as well in the `edk2` directory:
     535
     536{{{
     537$ find . -name "*.fd"
     538./Build/OvmfX64/DEBUG_GCC5/FV/MEMFD.fd
     539./Build/OvmfX64/DEBUG_GCC5/FV/OVMF.fd <-- the file we're looking for
     540./Build/OvmfX64/DEBUG_GCC5/FV/OVMF_CODE.fd
     541./Build/OvmfX64/DEBUG_GCC5/FV/OVMF_VARS.fd
     542}}}
     543
     544And then to boot into a UEFI shell:
     545
     546{{{
     547qemu-system-x86_64 --bios /path/to/repo/edk2/Build/OvmfX64/DEBUG_GCC5/FV/OVMF.fd -net none
     548}}}
     549
     550**Note:** Remember to replace the path to `OVMF.fd` with the actual path!
     551
    510552=  Emulating Other Platforms with QEMU  =
    511553