• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1Developer's UEFI Emulation (DUET) on Edk2
2
3A. Build DUET image on Windows Platform
4========================================
51. Tools preparation
6
7  To build DUET image, Visual Studio is required:
8  1). Base on below link to create Visual Studio build environment.
9      https://github.com/tianocore/tianocore.github.io/wiki/Windows-systems
10
112. Build Duet Platform module
12
13  1). run cmd.exe to open command line window.
14  2). enter workspace root directory such as c:\edk2_tree
15  3). set the environment variable EDK_TOOLS_BIN to point at the BaseTools binaries directory
16      i.e., "set EDK_TOOLS_BIN=c:\edk2-BaseTools-win32"
17  4). run "edksetup.bat"
18  5). run "build -p DuetPkg\DuetPkgIa32.dsc -a IA32 -t VS2015x86" for IA32 architecture platform (using 64-bit VS2015 for example) or
19          "build -p DuetPkg\DuetPkgX64.dsc -a X64 -t VS2015x86" for X64 architecture platform.
20
21  NOTE: The post build script 'PostBuild.sh' will be automatically called after the build command.
22
23
24Create bootable disk
25======================
26
273. Create boot disk
28  The following steps are same for IA32 architecture platform or X64 architecture platform.
29
303.1 Create floppy boot disk
31  1). enter <Workspace>\DuetPkg directory.
32  2). Insert a floppy disk to drive
33  3). run "CreateBootDisk.bat floppy a: FAT12 IA32" if floppy drive is a: disk and Arch to boot is IA32.
34      or
35      run "CreateBootDisk.bat floppy a: FAT12 X64" if floppy drive is a: disk and Arch to boot is X64.
363.2 Create usb boot disk
37  1). enter <Workspace>\DuetPkg directory.
38  2). Plugin usb disk
39  3). run "CreateBootDisk.bat usb e: FAT16 IA32" if usb drive is e: and FAT format is FAT16 and Arch to boot is IA32.
40      or "CreateBootDisk.bat usb e: FAT16 X64" if usb drive is e: and FAT format is FAT16 and Arch to boot is X64.
41      or "CreateBootDisk.bat usb e: FAT32 IA32" if usb drive is e: and FAT format is FAT32 and Arch to boot is IA32.
42      or "CreateBootDisk.bat usb e: FAT32 X64" if usb drive is e: and FAT format is FAT32 and Arch to boot is X64.
43  4). UnPlug usb disk and plugin it again.
44  5). run "CreateBootDisk.bat usb e: FAT16 IA32 step2" if usb drive is e: and FAT format is FAT16 and Arch to boot is IA32.
45      or "CreateBootDisk.bat usb e: FAT16 X64 step2" if usb drive is e: and FAT format is FAT16 and Arch to boot is X64.
46      or "CreateBootDisk.bat usb e: FAT32 IA32 step2" if usb drive is e: and FAT format is FAT32 and Arch to boot is IA32.
47      or "CreateBootDisk.bat usb e: FAT32 X64 step2" if usb drive is e: and FAT format is FAT32 and Arch to boot is X64.
48
49B. Build DUET image on Linux Platform
50======================================
511. Tools preparation
52
53  To build DUET image, GCC installation (4.4+) is required:
54  1). Base on below link to create GCC build environment.
55      https://github.com/tianocore/tianocore.github.io/wiki/Using-EDK-II-with-Native-GCC
56
572. Build Duet Platform module
58
59  1). Open the terminal.
60  2). enter workspace root directory such as /edk2_tree
61  3). run ". edksetup.sh BaseTools"
62  4). run "build -p DuetPkg/DuetPkgIa32.dsc -a IA32 -t GCC49" for IA32 architecture platform (using GCC 4.9 for example) or
63          "build -p DuetPkg/DuetPkgX64.dsc -a X64 -t GCC49" for X64 architecture platform.
64
65  NOTE: The post build script 'PostBuild.sh' will be automatically called after the build command.
66        After post build action, you should check the size of EfiLdr at $WORKSPACE/Build/DuetPkgIA32(DuetPkgX64)/DEBUG_GCC49 directory, it must less than 470k.
67        If not, you should manually remove some unnecessary drivers at DuetPkg.fdf file.
68
693. Create bootable disk
70   The following steps are same for IA32 architecture platform or X64 architecture platform.
71
723.1 Create floppy boot disk
73  1). enter /edk2_tree/DuetPkg directory.
74  2). Insert a floppy disk to drive
75  3). run "CreateBootDisk.sh" to build floppy drive
76      such as "./CreateBootDisk.sh floppy /media/floppy0 /dev/fd0 FAT12 IA32"
77
783.2 Create usb boot disk
79  1). enter /edk2_tree/DuetPkg directory.
80  2). Plugin usb disk
81  3). run "CreateBootDisk.sh" to build usb drive
82      such as "./CreateBootDisk.sh usb /media/usb0 /dev/sdb0 FAT16 IA32"
83  4). UnPlug usb disk and plugin it again.
84  5). run "./CreateBootDisk.sh usb /media/usb0 /dev/sdb0 FAT16 IA32 step2"
85