Aarch64-none-linux-gnu-gcc: not found

Hi,
i am using colibri-imx6ull SOM and trying to create the costume linux by using “Build U-Boot From Source Code | Toradex Developer Center
right now i am in the phase of host image creation in host device,
while i am trying to follow the same i am facing the following issue


lcl@lcl-Latitude-5430:~/workdir/u-boot$ make mrproper
/bin/sh: 1: aarch64-none-linux-gnu-gcc: not found
make: aarch64-none-linux-gnu-gcc: No such file or directory
/bin/sh: 1: aarch64-none-linux-gnu-gcc: not found
dirname: missing operand
Try ‘dirname --help’ for more information.

i followed all the steps as per website mentioned above.

lcl@lcl-Latitude-5430:~/workdir/u-boot$ sudo apt-get install gcc-aarch64-linux-gnu
Reading package lists… Done
Building dependency tree… Done
Reading state information… Done
gcc-aarch64-linux-gnu is already the newest version (4:11.2.0-1ubuntu1).
The following packages were automatically installed and are no longer required:
libflashrom1 libftdi1-2 libllvm13
Use ‘sudo apt autoremove’ to remove them.
0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

but still no use,
thanks in advance.

host configurations:

lcl@lcl-Latitude-5430:~/workdir/u-boot$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.4 LTS
Release: 22.04
Codename: jammy

Hi, I’m the Toradex AI Assistant. I’m in early beta, and I would appreciate your feedback.
The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello,

It appears that the aarch64-none-linux-gnu-gcc compiler is not being found in your PATH, even though you have installed the gcc-aarch64-linux-gnu package. This discrepancy is because the package you installed provides the compiler with a slightly different name. The aarch64-none-linux-gnu-gcc is typically used for bare-metal development, while gcc-aarch64-linux-gnu is targeted for Linux kernel and application development.

To resolve this issue, you can create a symbolic link in a directory that’s in your PATH, or you can directly use the gcc-aarch64-linux-gnu-gcc command if adjusting your build scripts is feasible. Here’s how you can create a symbolic link:

  1. First, find out where gcc-aarch64-linux-gnu-gcc is located:

    which gcc-aarch64-linux-gnu-gcc
    

    This command should return the path to the compiler, something like /usr/bin/gcc-aarch64-linux-gnu-gcc.

  2. Create a symbolic link to aarch64-none-linux-gnu-gcc in a directory that’s in your PATH, such as /usr/local/bin:

    sudo ln -s /usr/bin/gcc-aarch64-linux-gnu-gcc /usr/local/bin/aarch64-none-linux-gnu-gcc
    

    Make sure to replace /usr/bin/gcc-aarch64-linux-gnu-gcc with the actual path if it’s different.

  3. Verify that the symbolic link works:

    aarch64-none-linux-gnu-gcc --version
    

    This command should now return the version of the GCC compiler.

Alternatively, if your build process allows for specifying the compiler, you could directly use gcc-aarch64-linux-gnu-gcc instead of aarch64-none-linux-gnu-gcc.

Please note, for the Colibri iMX6ULL, which is based on an ARM Cortex-A7 architecture, you might not need the aarch64-none-linux-gnu-gcc compiler, as it is an ARMv7 architecture, not ARMv8 (Aarch64). Ensure you’re using the correct cross-compiler for your target architecture. For ARMv7, the toolchain prefix would typically be arm-linux-gnueabihf- instead of aarch64-none-linux-gnu-.

Best regards,
Toradex AI Assistant

Please, also check if these links can help you solve your problem:

High performance, low power Embedded Computing Systems | Toradex Developer Center.

thanks issue solved