UEFI build problems

I’m trying to build UEFI for AGX Orin for Jetpack 5 using this guide: Build with docker · NVIDIA/edk2-nvidia Wiki · GitHub

ubuntu@op-00200310-1:~$ . ./edkprep.sh
ubuntu@op-00200310-1:~$ edk2_docker init_edkrepo_conf
'/etc/edkrepo_skel/.edkrepo' -> '/home/ubuntu/.edkrepo'
'/etc/edkrepo_skel/.edkrepo/edkrepo.cfg' -> '/home/ubuntu/.edkrepo/edkrepo.cfg'
'/etc/edkrepo_skel/.edkrepo/edkrepo_user.cfg' -> '/home/ubuntu/.edkrepo/edkrepo_user.cfg'
Initialized edkrepo
ubuntu@op-00200310-1:~$ edk2_docker edkrepo manifest-repos add nvidia https://github.com/NVIDIA/edk2-edkrepo-manifest.git main nvidia
/opt/venv/lib/python3.10/site-packages/edkrepo/edkrepo_entry_point.py:16: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81.
  import pkg_resources
ubuntu@op-00200310-1:~$ cd build/
ubuntu@op-00200310-1:~/build$ edk2_docker edkrepo clone stable202210 NVIDIA-Platforms stable202210
/opt/venv/lib/python3.10/site-packages/edkrepo/edkrepo_entry_point.py:16: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81.
  import pkg_resources
Cloning global manifest repository to: /home/ubuntu/.edkrepo/edk2-edkrepo-manifest-main from: https://github.com/tianocore/edk2-edkrepo-manifest.git
Cloning global manifest repository to: /home/ubuntu/.edkrepo/nvidia from: https://github.com/NVIDIA/edk2-edkrepo-manifest.git
Verifying the global manifest repository entry for project: NVIDIA-Platforms

Cloning from: https://github.com/NVIDIA/edk2.git
Cloning from: https://github.com/NVIDIA/edk2-non-osi.git
Cloning from: https://github.com/NVIDIA/edk2-platforms.git
Cloning from: https://github.com/NVIDIA/edk2-nvidia.git
Cloning from: https://github.com/NVIDIA/edk2-nvidia-non-osi.git
Initializing/Updating submodules, done.
Submodule path 'ArmPkg/Library/ArmSoftFloatLib/berkeley-softfloat-3': checked out 'b64af41c3276f97f0e181920400ee056b9c88037'
Submodule path 'BaseTools/Source/C/BrotliCompress/brotli': checked out 'f4153a09f87cbb9c826d8fc12c74642bb2d879ea'
Submodule path 'CryptoPkg/Library/OpensslLib/openssl': checked out '98acb6b02839c609ef5b837794e08d906d965335'
Submodule path 'MdeModulePkg/Library/BrotliCustomDecompressLib/brotli': checked out 'f4153a09f87cbb9c826d8fc12c74642bb2d879ea'
Submodule path 'MdeModulePkg/Universal/RegularExpressionDxe/oniguruma': checked out 'abfc8ff81df4067f309032467785e06975678f0d'
Submodule path 'RedfishPkg/Library/JsonLib/jansson': checked out 'e9ebfa7e77a6bee77df44e096b100e7131044059'
Submodule path 'UnitTestFrameworkPkg/Library/CmockaLib/cmocka': checked out '1cc9cde3448cdd2e000886a26acf1caac2db7cf1'
Performing sparse checkout...
- /home/ubuntu/build/stable202210/edk2-platforms
ubuntu@op-00200310-1:~/build$ cd stable202210/
ubuntu@op-00200310-1:~/build/stable202210$ ls edk2-nvidia/Platform/NVIDIA/
HostBasedTests  NVIDIA.common.dsc.inc  NVIDIA.fvmain.fdf.inc        StandaloneMm.common.fdf.inc
Jetson          NVIDIA.common.fdf.inc  StandaloneMm.common.dsc.inc  StandaloneMmOptee
ubuntu@op-00200310-1:~/build/stable202210$ find . -name DefConfigs -print
ubuntu@op-00200310-1:~/build/stable202210$

Next step would have been configuring with an initial defconfig. However, the directory edk2-nvidia/Platform/NVIDIA/Tegra/DefConfigs does not exist. find . -name DefConfigs -print does not find any such directory in the whole build directory.

Where is my mistake?

*** Please note that this reply is generated by LLM automatically ***

Based on the provided context, it appears that you are trying to build UEFI for Jetson AGX Orin using the NVIDIA EDK2 repository and the guide provided on the NVIDIA EDK2 wiki on GitHub.

The issue you are facing is that the directory edk2/nvidia/Platform/NVIDIA/Tegra/DefConfigs does not exist in your build directory. This directory is supposed to contain the initial defconfig files for the Tegra platform.

To resolve this issue, you can try the following steps:

  1. Check the repository version: Make sure that you are using the correct version of the NVIDIA EDK2 repository. The guide on the NVIDIA EDK2 wiki on GitHub mentions that the repository should be checked out at the jetpack-5.1 branch.
  2. Verify the directory structure: Check the directory structure of your build directory to ensure that it matches the expected structure. The edk2/nvidia/Platform/NVIDIA/Tegra/DefConfigs directory should be present in the repository.
  3. Run the git submodule update command: If you are using a submodule-based repository, run the git submodule update command to ensure that all submodules are initialized and updated.
  4. Check for missing files: If the directory is still missing, check if the files are present in the repository but not in your local build directory. You can try running the git ls-files command to check if the files are present in the repository.

Comparison with other Jetson modules:

  • The issue you are facing is specific to the Jetson AGX Orin module and the NVIDIA EDK2 repository.
  • Other Jetson modules, such as the Jetson Orin NX and Jetson Orin Nano, may have different directory structures and build processes.
  • However, the general steps to resolve the issue, such as checking the repository version and directory structure, can be applied to other Jetson modules as well.

In summary, the issue you are facing is likely due to a missing directory or files in your build directory. By checking the repository version, verifying the directory structure, and running the git submodule update command, you should be able to resolve the issue and proceed with building UEFI for Jetson AGX Orin.

*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***

git submodule update didn’t help.

Hi fchkjwlsq,

What’s the exact Jetpack version in use?

For Jetpack 5.x, you can simply run the following command to build UEFI source.

$ edk2_docker edk2-nvidia/Platform/NVIDIA/Jetson/build.sh

Ok, did work. Now, where do i set the target system (Xavier NX/AGX Xavier/Orin Nano-NX/AG Orin)?

Actually, they use the same UEFI binary(i.e. bootloader/uefi_jetson.bin) for these 4 SoMs.