1.在Microsoft Store下載一個喜歡的Linux系統,我選擇Ubuntu 18.04.6 LTS
2.切換軟件鏡像源:https://mirrors.tuna.tsinghua.edu.cn/help/ubuntu/
3.按這個配置:https://blog.csdn.net/weixin_44139099/article/details/140681442
4.一定要安裝最新的nasm,否則會報錯。Build/EmulatorIA32/DEBUG_GCC5/IA32/MdePkg/Library/BaseLib/BaseLib/OUTPUT/Ia32/LongJump.iii:42: error: parser: instruction expected
安裝NASM
點擊查看代碼
wget http://www.nasm.us/pub/nasm/releasebuilds/2.15.05/nasm-2.15.05.tar.bz2
tar xfj nasm-2.15.05.tar.bz2
cd nasm-2.15.05/
./autogen.sh
./configure --prefix=/usr/local/
make
sudo make install
https://www.nasm.us/pub/nasm/releasebuilds/2.16.03/

5.在windows安裝vscode,再安裝wsl擴展,這樣就可以方便管理/編輯項目文檔了!


完美!

Intel UDK Debugger Tool&&GDB調試程序
1.Intel UDK Debugger Tool下載鏈接
unzip解壓完安裝:sudo chmod +x UDK_Debugger_Tool_v1_5_1.bin
2.GDB下載安裝:sudo apt isntall gdb
QEMU文檔-Machine Emulator and Virtualizer.
build -p edk2/OvmfPkg/OvmfPkgX64.dsc -t GCC5 -a X64 -b DEBUG時找不到build
source edksetup.sh
BBQ了 用QEMU調試時黑屏,原因是安裝的子系統沒有圖像界面哈哈哈!

WARNING: Image format was not specified for 'OVMF.fd' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. qemu-system-x86_64: warning: TCG doesn't support requested feature: CPUID.01H:ECX.vmx [bit 5] unknown keycodes (unnamed)', please report to qemu-devel@nongnu.org
發現按照書《UEFI編程實踐》里面的那種方法打開有問題,換另一種方法成功打開https://cn.linux-terminal.com/?p=8385
sudo qemu-system-x86_64 -bios OVMF.fd fat:rw:hda-contents/ -net non e -vga virtio -enable-kvm

浙公網安備 33010602011771號