Re: [EXTERNAL] Re: [edk2-discuss] 回复: [edk2-discuss] edk2 build error


Bret Barkelew
 

Happy to help. Can you send the full console output including your original command?
Thanks!

- Bret

From: Mohammad Younas Khan Pathan via groups.io<mailto:pmdyounaskhan786=gmail.com@groups.io>
Sent: Thursday, March 4, 2021 6:23 AM
To: Feng, Bob C<mailto:bob.c.feng@intel.com>
Cc: discuss@edk2.groups.io<mailto:discuss@edk2.groups.io>; alexgdi@outlook.com<mailto:alexgdi@outlook.com>
Subject: [EXTERNAL] Re: [edk2-discuss] 回复: [edk2-discuss] edk2 build error

The mu_nasm dependency issue is resolved with below cmd:

stuart_update -c .pytool/CISettings.py


I am facing another error if I try stuart_build (for EmulatorPkg) or
running BaseTools/Edk2ToolsBuild.py for VS2019:

*ERROR - We were not able to find on the keys requested from vcvarsall.*
* ValueError: Missing keys when querying vcvarsall: ['WINDOWSSDKVERSION',
'WINDOWSSDKBINPATH', 'UNIVERSALCRTSDKDIR', 'WINDOWSLIBPATH', 'PATH',
'VCTOOLSINSTALLDIR', 'EXTENSIONSDKDIR', 'UCRTVERSION',
'WINDOWSSDKVERBINPATH', 'WINDOWSSDKDIR']*

Do we need to do any setup for these variables?

Thank you,
Younas.

On Thu, 4 Mar 2021 at 19:24, Feng, Bob C <bob.c.feng@intel.com> wrote:

OvmfPkg\Platform\ReadMe.md describes the instruction of using Pytools to
build OvmfPkg in details. Those instruction can also apply to EmulatorPkg
Build.

This command is to init and update the edk2 submodules
stuart_setup -c OvmfPkg/PlatformCI/PlatformBuild.py
TOOL_CHAIN_TAG=<TOOL_CHAIN_TAG> -a <TARGET_ARCH>

This command is to install the nasm and iasl
stuart_update -c OvmfPkg/PlatformCI/PlatformBuild.py
TOOL_CHAIN_TAG=<TOOL_CHAIN_TAG> -a <TARGET_ARCH>

This command is to build BaseTools C tools and set the necessary
environment variable
python BaseTools/Edk2ToolsBuild.py -t <ToolChainTag>

This command is to OvmfPkg
stuart_build -c OvmfPkg/PlatformCI/PlatformBuild.py -a IA32
TOOL_CHAIN_TAG=<TOOL_CHAIN_TAG>


Thanks,
Bob

-----Original Message-----
From: discuss@edk2.groups.io <discuss@edk2.groups.io> On Behalf Of
Mohammad Younas Khan Pathan
Sent: Thursday, March 4, 2021 7:07 PM
To: alexgdi@outlook.com
Cc: discuss@edk2.groups.io
Subject: Re: [edk2-discuss] 回复: [edk2-discuss] edk2 build error

Alex,
I tried that cmd, but it gives below error: NASM is installed and kept
with NASM_PREFIX env variable.

ERROR - Dependency 'mu_nasm' is not met!
Traceback (most recent call last):
File "c:\python\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "c:\python\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Python\Scripts\stuart_build.exe\__main__.py", line 7, in
<module>
File

"c:\python\lib\site-packages\edk2toolext\invocables\edk2_platform_build.py",
line 113, in main
Edk2PlatformBuild().Invoke()
File
"c:\python\lib\site-packages\edk2toolext\base_abstract_invocable.py", line
122, in Invoke
raise RuntimeError("SDE is not current. Please update your env before
running this tool.")
RuntimeError: SDE is not current. Please update your env before running
this tool.

Have you got any errors like this?

Thank you,
Younas.

On Thu, 4 Mar 2021 at 16:06, <alexgdi@outlook.com> wrote:

On Thu, Mar 4, 2021 at 02:27 AM, Mohammad Younas Khan Pathan wrote:


cmd: python BaseTools/Edk2ToolsBuild.py -t <ToolChainTag> #
ToolChainTag
It is not necessary to compile BaseTools. If you want to build
EmulatorPkg try this instruction
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Ftianocore%2Fedk2%2Fblob%2Fmaster%2FEmulatorPkg%2FPlatformCI%2FR&;data=04%7C01%7Cbret.barkelew%40microsoft.com%7Cbbcdf46a0d0f4e50b30f08d8df192459%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637504646368276783%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=sa0LlLWD7dEFVUzRTHER%2FYOzHUM%2FoGnDQpdT4t6o1Zc%3D&amp;reserved=0
eadMe.md
and use MSVC 2019 compiler

for example

stuart_build -c EmulatorPkg/PlatformCI/PlatformBuild.py
TOOL_CHAIN_TAG=VS2019 -a X64

...








Join discuss@edk2.groups.io to automatically receive all group messages.