Build Optimizations - 2020.2 English

PetaLinux Tools Documentation Reference Guide (UG1144)

Document ID
UG1144
Release Date
2020-11-24
Version
2020.2 English

This section describes the build optimization techniques with the PetaLinux tools.

Deselecting Default Components

You can deselect default components, if they are not needed. To disable the FSBL and PMU firmware for Zynq® UltraScale+™ MPSoC, deselect the following options in petalinux-config > Linux Components Selection.

  • FSBL > [ ] First Stage Boot Loader
  • PMUFW > [ ] PMU Firmware

Deselecting these components removes these components from the default build flow.

Local Mirror Servers

You can set internal mirrors on the NFS or web server which can speed up the builds. By default, PetaLinux uses sstate-cache and download mirrors from petalinux.xilinx.com. Follow these steps to work with local, NFS, or the internal webserver copy of sstate in PetaLinux. You can download the sstate from the download area along with PetaLinux.

Table 1. Local Mirror Servers
Server Description
downloads Source of download files are available in http://petalinux.xilinx.com/sswreleases/rel-v2020/downloads
aarch64 sstate mirrors for Zynq UltraScale+ MPSoC
arm sstate mirrors for Zynq-7000
mb-full sstate mirrors for MicroBlaze™ processors (full)
mb-lite sstate mirrors for MicroBlaze processors (lite)

Source Mirrors

You can set source mirrors through petalinux-config > Yocto-settings > Add pre-mirror URL. Select file://<local downloads path> for all projects. Save the configuration to use the download mirrors and verify the changes in build/conf/plnxtool.conf.

Reduce Build Time

To reduce the build time by disabling the network sstate feeds, de-select the petalinux-config > Yocto Settings > Enable Network sstate feeds.

Sstate Feeds

You can set sstate feeds through petalinux-config.

  • sstate feeds on NFS: Go to petalinux-config > Yocto Settings > Local sstate feeds settings and enter the full path of the sstate directory. By enabling this option, you can point to your own shared state which is available at a NFS/local mount point.

    For example, to enable, use /opt/petalinux/sstate-cache_2020/aarch64.

  • sstate feeds on webserver: Go to petalinux-config > Yocto Settings > Enable Network sstate feeds > Network sstate feeds URL and enter the URL for sstate feeds.