petalinux-config Menu Crashes with Segmentation Fault on CentOS 7.x - 2022.1 English

PetaLinux Tools Documentation: Reference Guide (UG1144)

Document ID
UG1144
Release Date
2022-04-26
Version
2022.1 English

The petalinux-config menu crashes with segmentation fault on CentOS 7.x as shown below. This is a known issue in 2020.x version of PetaLinux tools.

Figure 1. Segementation Fault on CentOS 7.x
$ petalinux-config INFO: Sourcing build tools awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) [INFO] Generating Kconfig for project awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk) [INFO] Menuconfig project

This issue is seen when you run petalinux-config with non-interactive mode.

$ petalinux-config --silentconfig
INFO: sourcing build tools
awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk)
awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk)
awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk)
awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk)
[INFO] silentconfig project
awk: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by awk)
ERROR: Failed to silentconfig project component
ERROR: Failed to config project.
$

Root Cause

In CentOS-7.x if you set LD_LIBRARY_PATH variable (example export LD_LIBRARY_PATH=/lib64:/usr/lib64:/usr/local/lib64) causes the petalinux-config menu to crash with segmentation fault. In Yocto, if you want to use any build host binaries or libraries you need to unset LD_LIBRARY_PATH. Once it goes to segmentation fault terminal, follow these steps to kill the seg fault terminal.

  1. Type reset and enter key. Now terminal will be blank.
  2. Press Ctrl+J same time.

    Now you should have a working terminal.

Solution

To work around this issue, follow these steps.

  1. Unset the LD_LIBRARY_PATH by running below command.
    $ unset LD_LIBRARY_PATH
  2. Source the PetaLinux tools.
    $ source /opt/xilinx/petalinux/petalinux-v<petalinux-version>/settings.sh
  3. Run menu config.
    $ petalinux-config