Facing compilation error while building SPE Firmware of release 32.5

Hi Jachen,

We are using Xavier NX board. we need to experiment the AON GPIO because we are going to use cortex for our real time application.

Please help to test this 32.5.

Getting the below compilation errors (download SPE firmware by https://developer.nvidia.com/embedded/L4T/r32_Release_v5.0/sources/T186/l4t_rt_aux_cpu_src.tbz2).

Followed this link to resolve error but still I see only one error: Xavier / TX2 SPE (Cortex-R5) Freeertos Compiling Process Record - Programmer Sought

Errors:
yyappan@ayyappan:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ make TARGET=t19x
mkdir -p /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x
CC clk.c
CC init_padctrl.c
CC spe-clk.c
CC spe-pm-sequencer.c
/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/soc/t19x/src/spe-pm-sequencer.c:63:34: error: redundant redeclaration of ‘tegra_hsp_id_top0’ [-Werror=redundant-decls]
63 | extern const struct tegra_hsp_id tegra_hsp_id_top0;
| ^~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/soc/t19x/src/spe-pm-sequencer.c:46:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/hsp-tegra-hw.h:36:34: note: previous declaration of ‘tegra_hsp_id_top0’ was here
36 | extern const struct tegra_hsp_id tegra_hsp_id_top0;
| ^~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/spe-pm-sequencer.o] Error 1

Regards,
Ayyappan R

Hello,
Have you ever made any change in SPE firmware?

Paste my local building script and result for your reference.

building-pc:~/Work/jetson_sdk/32.5/spe-fw.orig$ cat spe-firmware-build.sh
#!/bin/bash
set -e
export TOP=“${HOME}/Work/jetson_sdk/32.5/spe-fw.orig/l4t-rt”
export CROSS_COMPILE=“${HOME}/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”
export FREERTOS_DIR=${TOP}/FreeRTOSV8.1.2/FreeRTOS/Source
export FREERTOS_COMMON_DIR=${TOP}/freertos-common

To build for Jetson AGX

cd ${TOP}/rt-aux-cpu-demo && make -j8 bin_t19x && make docs

building-pc:~/Work/jetson_sdk/32.5/spe-fw.orig$ ./spe-firmware-build.sh
mkdir -p /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/out/t19x
CC clk.c
CC init_padctrl.c
CC spe-clk.c
CC spe-pm-sequencer.c
CC armv7-exceptions.S
CC newlib-syscalls.c
CC err-hook-printf.c
CC arm-vic.c
CC irqapi-vic.c
CC irqapi-cortex-r5.c
CC tke-tegra.c
CC cache-cortex-r5.c
CC armv7-exception.c
CC tke-tegra-udelay.c
CC hsp-tegra.c
CC debug.c
CC tegra-ivc.c
CC wake-tegra.c
CC ast-tegra.c
CC tke-tegra-ids.c
CC hsp-tegra-ids.c
CC ast-tegra-ids.c
CC irqapi-vic-ids.c
CC clk-tegra.c
CC portASM.S
CC list.c
CC heap_3.c
CC port.c
CC queue.c
CC tasks.c
CC timers.c
CC event_groups.c
CC ivc-echo-task.c
CC bpmp-ipc.c
CC interrupt.c
CC irq-handlers.S
CC ivc-channels.c
CC spe-vic.c
CC spe-pm.c
CC debug_init.c
CC ivc-channel-ids.c
CC boot.S
CC main.c
CC uart-tegra-ids.c
CC uart-tegra.c
CC combined-uart.c
CC combined-uart-ids.c
CC tegra-gpcdma.c
CC tegra-gpcdma-ids.c
CPP spe.ld.in
LINK spe.elf
OBJCOPY spe.bin
DISASM spe.dis
mkdir -p /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/out/docs
DOXYGEN /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/doxyfile
Searching for include files…
Searching for example files…
Searching for images…
Searching for files in directory /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/nvimages
Searching for dot files…
Searching for msc files…
Searching for dia files…
Searching for files to exclude
Searching INPUT for files to process…
Reading and parsing tag files
Parsing files
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/welcome.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/compile-flash.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/aodmic-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/can-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/devicetree-ivc.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/gpio.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/gte-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/i2c-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/spi-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/timer-app.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/uart.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/known_issues.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/faq.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/third_party_legal.md…
Reading /data/jetson_sdk/32.5/spe-fw.orig/l4t-rt/rt-aux-cpu-demo/doc/nvidia_legal.md…
Building group list…
Building directory list…
Building namespace list…
Building file list…
Building class list…
Associating documentation with classes…
Computing nesting relations for classes…
Building example list…
Searching for enumerations…
Searching for documented typedefs…
Searching for members imported via using declarations…
Searching for included using directives…
Searching for documented variables…
Building interface member list…
Building member list…
Searching for friends…
Searching for documented defines…
Computing class inheritance relations…
Computing class usage relations…
Flushing cached template relations that have become invalid…
Computing class relations…
Add enum values to enums…
Searching for member function documentation…
Creating members for template instances…
Building page list…
Search for main page…
Computing page relations…
Determining the scope of groups…
Sorting lists…
Freeing entry tree
Determining which enums are documented
Computing member relations…
Building full member lists recursively…
Adding members to member groups.
Computing member references…
Inheriting documentation…
Generating disk names…
Adding source references…
Adding xrefitems…
Sorting member lists…
Computing dependencies between directories…
Generating citations page…
Counting data structures…
Resolving user defined references…
Finding anchors and sections in the documentation…
Transferring function references…
Combining using relations…
Adding members to index pages…
Generating style sheet…
Generating search indices…
Generating example documentation…
Generating file sources…
Generating file documentation…
Generating page documentation…
Generating docs for page rt-compiling…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_aodmic-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_can-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_devicetree-ivc…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_gpio…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_gte-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_i2c-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_spi-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_timer-app…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_uart…
Generating docs for page rt-knownissues…
Generating docs for page rt-faq…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_third_party_legal…
Generating docs for page md__data_jetson_sdk_32.5_spe-fw.orig_l4t-rt_rt-aux-cpu-demo_doc_nvidia_legal…
Generating group documentation…
Generating class documentation…
Generating namespace index…
Generating graph info page…
Generating directory documentation…
Generating index page…
Generating page index…
Generating module index…
Generating namespace member index…
Generating annotated compound index…
Generating alphabetical compound index…
Generating hierarchical class index…
Generating member index…
Generating file index…
Generating file member index…
Generating example index…
finalizing index lists…
writing tag file…
lookup cache used 0/65536 hits=0 misses=0
finished…

No local changes… Just download and build…

Will try your script and let you know the results…

Hi Jachen,

I download the SPE firmware and compiled without any local changes and facing the below errors.

Logs:
ayyappan@ayyappan:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ cat compile.sh
#!/bin/bash
set -e
export TOP=${HOME}/nvidia/SPE/l4t-rt/
export CROSS_COMPILE=${HOME}/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-10-2020-q4-major/bin/arm-none-eabi-
export FREERTOS_DIR=${TOP}/FreeRTOSV8.1.2/FreeRTOS/Source
export FREERTOS_COMMON_DIR=${TOP}/freertos-common

make clean
make -j8 bin_t19x && make docs
ayyappan@ayyappan:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$
ayyappan@ayyappan:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ ./compile.sh
RMDIR t18x
RMDIR t19x
RMDIR docs
mkdir -p /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x
CC clk.c
CC init_padctrl.c
CC spe-clk.c
CC spe-pm-sequencer.c
CC armv7-exceptions.S
CC newlib-syscalls.c
CC err-hook-printf.c
CC arm-vic.c
CC irqapi-vic.c
CC irqapi-cortex-r5.c
CC tke-tegra.c
CC cache-cortex-r5.c
CC armv7-exception.c
CC tke-tegra-udelay.c
CC hsp-tegra.c
CC debug.c
CC tegra-ivc.c
CC wake-tegra.c
CC ast-tegra.c
CC tke-tegra-ids.c
CC hsp-tegra-ids.c
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:44:34: error: redundant redeclaration of ‘tegra_tke_id_timer0’ [-Werror=redundant-decls]
44 | extern const struct tegra_tke_id tegra_tke_id_timer0
| ^~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:32:34: note: previous declaration of ‘tegra_tke_id_timer0’ was here
32 | extern const struct tegra_tke_id tegra_tke_id_timer0;
| ^~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:54:34: error: redundant redeclaration of ‘tegra_tke_id_timer1’ [-Werror=redundant-decls]
54 | extern const struct tegra_tke_id tegra_tke_id_timer1
| ^~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:33:34: note: previous declaration of ‘tegra_tke_id_timer1’ was here
33 | extern const struct tegra_tke_id tegra_tke_id_timer1;
| ^~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:64:34: error: redundant redeclaration of ‘tegra_tke_id_timer2’ [-Werror=redundant-decls]
64 | extern const struct tegra_tke_id tegra_tke_id_timer2
| ^~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:34:34: note: previous declaration of ‘tegra_tke_id_timer2’ was here
34 | extern const struct tegra_tke_id tegra_tke_id_timer2;
| ^~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:74:34: error: redundant redeclaration of ‘tegra_tke_id_timer3’ [-Werror=redundant-decls]
74 | extern const struct tegra_tke_id tegra_tke_id_timer3
| ^~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:35:34: note: previous declaration of ‘tegra_tke_id_timer3’ was here
35 | extern const struct tegra_tke_id tegra_tke_id_timer3;
| ^~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:84:34: error: redundant redeclaration of ‘tegra_tke_id_noirq_timer0’ [-Werror=redundant-decls]
84 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer0
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:37:34: note: previous declaration of ‘tegra_tke_id_noirq_timer0’ was here
37 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer0;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:94:34: error: redundant redeclaration of ‘tegra_tke_id_noirq_timer1’ [-Werror=redundant-decls]
94 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer1
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:38:34: note: previous declaration of ‘tegra_tke_id_noirq_timer1’ was here
38 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer1;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:104:34: error: redundant redeclaration of ‘tegra_tke_id_noirq_timer2’ [-Werror=redundant-decls]
104 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer2
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:39:34: note: previous declaration of ‘tegra_tke_id_noirq_timer2’ was here
39 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer2;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:114:34: error: redundant redeclaration of ‘tegra_tke_id_noirq_timer3’ [-Werror=redundant-decls]
114 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer3
| ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/tke-tegra-ids.c:33:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/tke-tegra-hw.h:40:34: note: previous declaration of ‘tegra_tke_id_noirq_timer3’ was here
40 | extern const struct tegra_tke_id tegra_tke_id_noirq_timer3;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:44:34: error: redundant redeclaration of ‘tegra_hsp_id_top0’ [-Werror=redundant-decls]
44 | extern const struct tegra_hsp_id tegra_hsp_id_top0 attribute((alias(“tegra_hsp_ctx_top0”)));
| ^~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:31:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/hsp-tegra-hw.h:36:34: note: previous declaration of ‘tegra_hsp_id_top0’ was here
36 | extern const struct tegra_hsp_id tegra_hsp_id_top0;
| ^~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:58:34: error: redundant redeclaration of ‘tegra_hsp_id_aon’ [-Werror=redundant-decls]
58 | extern const struct tegra_hsp_id tegra_hsp_id_aon attribute((alias(“tegra_hsp_ctx_aon”)));
| ^~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:31:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/hsp-tegra-hw.h:35:34: note: previous declaration of ‘tegra_hsp_id_aon’ was here
35 | extern const struct tegra_hsp_id tegra_hsp_id_aon;
| ^~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:68:34: error: redundant redeclaration of ‘tegra_hsp_id_bpmp’ [-Werror=redundant-decls]
68 | extern const struct tegra_hsp_id tegra_hsp_id_bpmp attribute((alias(“tegra_hsp_ctx_bpmp”)));
| ^~~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:31:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/hsp-tegra-hw.h:37:34: note: previous declaration of ‘tegra_hsp_id_bpmp’ was here
37 | extern const struct tegra_hsp_id tegra_hsp_id_bpmp;
| ^~~~~~~~~~~~~~~~~
/home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:78:34: error: redundant redeclaration of ‘tegra_hsp_id_sce’ [-Werror=redundant-decls]
78 | extern const struct tegra_hsp_id tegra_hsp_id_sce attribute((alias(“tegra_hsp_ctx_sce”)));
| ^~~~~~~~~~~~~~~~
In file included from /home/ayyappan/nvidia/SPE/l4t-rt//freertos-common-t19x/code-soc/t194-aon/hsp-tegra-ids.c:31:
/home/ayyappan/nvidia/SPE/l4t-rt/freertos-common-t19x/include-soc/t194-aon/hsp-tegra-hw.h:38:34: note: previous declaration of ‘tegra_hsp_id_sce’ was here
38 | extern const struct tegra_hsp_id tegra_hsp_id_sce;
| ^~~~~~~~~~~~~~~~
CC ast-tegra-ids.c
cc1: all warnings being treated as errors
make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/tke-tegra-ids.o] Error 1
make: *** Waiting for unfinished jobs…
cc1: all warnings being treated as errors
make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/hsp-tegra-ids.o] Error 1
ayyappan@ayyappan:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$

Hello,
I guess the issue comes from different toolchain.
Yours:
${HOME}/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-10-2020-q4-major/bin/arm-none-eabi-
Mine:
Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”

Different version of GCC may result in different error level.
-Werror=redundant-decls may be skipped in 2014q3 gcc version.

Please follow the SPE doc exactly, which has been verified.

br
ChenJian

The tool chain you mentioned is not compiling with my code.

its throwing “gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc” not found error.

The same environment I just changed the tool-chain and export the new tool-chain path.

Is tool chain is 16 bit or 32 bit??

Can you zip your l4-rt folder and share so that i can try the same what you tried?

Below is the error snap:

Hello,
You can take a look at doc inside SPE source package. (l4t-rt/rt-aux-cpu-demo/doc/compile-flash.md)

Paste related contents here:

TOOLCHAIN PREREQUISITE#

You must download the external Toolchain. NVIDIA does not distribute this toolchain.

https://launchpad.net/gcc-arm-embedded/4.8/4.8-2014-q3-update

BUILD

Set the appropriate paths for the below variables:

export TOP=<path to root directory where rt-aux-cpu-demo, hwinc and freertos related sources/directories reside>
export CROSS_COMPILE=<path to installed cross compiler>/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-
export FREERTOS_DIR=${TOP}/FreeRTOSV8.1.2/FreeRTOS/Source
export FREERTOS_COMMON_DIR=${TOP}/freertos-common

cd rt-aux-cpu-demo

Please download the toolchain and setup the environment correctly.

br
Chenjian

you did not read my message correctly it seems.

What I mean is, If replace the tool-chain with “gcc-arm-none-eabi-10-2020-q4-major” its compiling.

Did you see my snap? I listed the path of the “arm-none-eabi-gcc”. The tool chain path is correct but still its not taking the right path.

I downloaded: https://launchpad.net/gcc-arm-embedded/4.8/4.8-2014-q3-update/+download/gcc-arm-none-eabi-4_8-2014q3-20140805-linux.tar.bz2

BTW, Facing the below errors while building the kernel.

Errors:
arch/arm64/boot/dts/Makefile:132: target ‘arch/arm64/boot/dts/ddot’ given more than once in the same rule

arch/arm64/boot/dts/Makefile:132: target ‘arch/arm64/boot/dts/ddot’ given more than once in the same rule

make[1]: *** No rule to make target ‘arch/arm64/boot/dts/…//hardware/nvidia/platform/t19x/mccoy/kernel-dts/tegra194-p2888-0004-e3900-0000.dts’, needed by ‘arch/arm64/boot/dts/ddot//hardware/nvidia/platform/t19x/mccoy/kernel-dts/tegra194-p2888-0004-e3900-0000.dtb’. Stop.

make[1]: *** Waiting for unfinished jobs…

DTC arch/arm64/boot/dts/ddot

cc1: fatal error: arch/arm64/boot/dts/…: No such file or directory

compilation terminated.

make[1]: *** [arch/arm64/boot/dts/Makefile:133: arch/arm64/boot/dts/ddot] Error 1

make: *** [arch/arm64/Makefile:154: dtbs] Error 2

Hello,
For kernel building, please file a new thread.
Let’s focus on SPE firmware building in this topic.

After downloading https://launchpad.net/gcc-arm-embedded/4.8/4.8-2014-q3-update/+download/gcc-arm-none-eabi-4_8-2014q3-20140805-linux.tar.bz2, you should extract the package and set the path correct.

Take my script as an example, the path is set by export CROSS_COMPILE=“${HOME}/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”

And the cross-compiler should look like:
$ ll ${HOME}/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-*
-rwxr-xr-x 1 chenjian chenjian 706600 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-addr2line*
-rwxr-xr-x 2 chenjian chenjian 734508 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ar*
-rwxr-xr-x 2 chenjian chenjian 1220908 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-as*
-rwxr-xr-x 2 chenjian chenjian 682080 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-c++*
-rwxr-xr-x 1 chenjian chenjian 705640 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-c++filt*
-rwxr-xr-x 1 chenjian chenjian 679840 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-cpp*
-rwxr-xr-x 1 chenjian chenjian 23728 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-elfedit*
-rwxr-xr-x 2 chenjian chenjian 682080 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-g++*
-rwxr-xr-x 2 chenjian chenjian 678464 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc*
-rwxr-xr-x 2 chenjian chenjian 678464 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-4.8.4*
-rwxr-xr-x 1 chenjian chenjian 23664 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-ar*
-rwxr-xr-x 1 chenjian chenjian 23632 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-nm*
-rwxr-xr-x 1 chenjian chenjian 23632 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-ranlib*
-rwxr-xr-x 1 chenjian chenjian 305276 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcov*
-rwxr-xr-x 1 chenjian chenjian 4079604 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gdb*
-rwxr-xr-x 1 chenjian chenjian 772072 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gprof*
-rwxr-xr-x 4 chenjian chenjian 1009260 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ld*
-rwxr-xr-x 4 chenjian chenjian 1009260 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ld.bfd*
-rwxr-xr-x 2 chenjian chenjian 718504 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-nm*
-rwxr-xr-x 2 chenjian chenjian 879688 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-objcopy*
-rwxr-xr-x 2 chenjian chenjian 1060776 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-objdump*
-rwxr-xr-x 2 chenjian chenjian 734508 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ranlib*
-rwxr-xr-x 1 chenjian chenjian 373956 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-readelf*
-rwxr-xr-x 1 chenjian chenjian 707752 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-size*
-rwxr-xr-x 1 chenjian chenjian 707016 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-strings*
-rwxr-xr-x 2 chenjian chenjian 879688 8月 5 2014 /home/chenjian/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-strip*

In your error log, the file does not exist. Most probably, the path is not correct. You can check it.

br
ChenJian

Please check the below logs:

ayyappan@ubuntu-22:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ cat compile.sh

#!/bin/bash

set -e

export TOP=“${HOME}/nvidia/SPE/l4t-rt”

export CROSS_COMPILE=“${HOME}/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”

export FREERTOS_DIR=${TOP}/FreeRTOSV8.1.2/FreeRTOS/Source

export FREERTOS_COMMON_DIR=${TOP}/freertos-common

To build for Jetson AGX

make clean

make -j8 bin_t19x && make docs

ayyappan@ubuntu-22:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ ls -l ${HOME}/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-*

-rwxr-xr-x 1 root root 706600 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-addr2line

-rwxr-xr-x 2 root root 734508 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ar

-rwxr-xr-x 2 root root 1220908 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-as

-rwxr-xr-x 2 root root 682080 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-c++

-rwxr-xr-x 1 root root 705640 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-c++filt

-rwxr-xr-x 1 root root 679840 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-cpp

-rwxr-xr-x 1 root root 23728 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-elfedit

-rwxr-xr-x 2 root root 682080 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-g++

-rwxr-xr-x 2 root root 678464 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc

-rwxr-xr-x 2 root root 678464 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-4.8.4

-rwxr-xr-x 1 root root 23664 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-ar

-rwxr-xr-x 1 root root 23632 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-nm

-rwxr-xr-x 1 root root 23632 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc-ranlib

-rwxr-xr-x 1 root root 305276 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcov

-rwxr-xr-x 1 root root 4079604 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gdb

-rwxr-xr-x 1 root root 772072 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gprof

-rwxr-xr-x 4 root root 1009260 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ld

-rwxr-xr-x 4 root root 1009260 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ld.bfd

-rwxr-xr-x 2 root root 718504 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-nm

-rwxr-xr-x 2 root root 879688 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-objcopy

-rwxr-xr-x 2 root root 1060776 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-objdump

-rwxr-xr-x 2 root root 734508 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-ranlib

-rwxr-xr-x 1 root root 373956 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-readelf

-rwxr-xr-x 1 root root 707752 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-size

-rwxr-xr-x 1 root root 707016 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-strings

-rwxr-xr-x 2 root root 879688 Aug 5 2014 /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-strip

ayyappan@ubuntu-22:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ ./compile.sh

RMDIR t18x

RMDIR t19x

RMDIR docs

mkdir -p /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x

CC clk.c

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/clk.o] Error 127

make: *** Waiting for unfinished jobs…

CC init_padctrl.c

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/init_padctrl.o] Error 127

CC spe-clk.c

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/spe-clk.o] Error 127

ayyappan@ubuntu-22:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$ ./compile.sh

RMDIR t18x

RMDIR t19x

RMDIR docs

mkdir -p /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x

CC clk.c

CC init_padctrl.c

make: *** No rule to make target ‘“/home/ayyappan/nvidia/SPE/l4t-rt”/freertos-common/code-common/armv7-exceptions.S’, needed by ‘/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/armv7-exceptions.o’. Stop.

make: *** Waiting for unfinished jobs…

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/clk.o] Error 127

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/init_padctrl.o] Error 127

CC spe-clk.c

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/spe-clk.o] Error 127

CC spe-pm-sequencer.c

make: “/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc: No such file or directory

make: *** [Makefile:370: /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/out/t19x/spe-pm-sequencer.o] Error 127

ayyappan@ubuntu-22:~/nvidia/SPE/l4t-rt/rt-aux-cpu-demo$

Hello,
The error is different from former error log.

Why an extra ‘"’ is in the path?
/home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”gcc

It should call /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-gcc

Maybe the character changes when copy/paste from browser?
Please check the script.

br
ChenJian

What do you see from:

ls -l /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-*

I think this extra is coming from the below env set which you gave
export CROSS_COMPILE=${HOME}/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-

I see below: for ls -l /home/ayyappan/nvidia/SPE/l4t-rt/rt-aux-cpu-demo/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-*

No.
Correct ‘"’ should not be included in string define.

There are lots of reference in internet, like
Bash Scripting - How to Initialize a String - GeeksforGeeks

You can add some debug code in the script, like echo to check the string. That should not be hard.

br
Chenjian

what is “No. and Correct ‘”’ should not be included in string define" ???

You have suggested the below and I just changed the path.

building-pc:~/Work/jetson_sdk/32.5/spe-fw.orig$ cat spe-firmware-build.sh
#!/bin/bash
set -e
export TOP=“${HOME}/Work/jetson_sdk/32.5/spe-fw.orig/l4t-rt”
export CROSS_COMPILE=“${HOME}/Tools/gcc-arm-none-eabi-4_8-2014q3/bin/arm-none-eabi-”
export FREERTOS_DIR=${TOP}/FreeRTOSV8.1.2/FreeRTOS/Source
export FREERTOS_COMMON_DIR=${TOP}/freertos-common

To build for Jetson AGX

cd ${TOP}/rt-aux-cpu-demo && make -j8 bin_t19x && make docs

Hello,
You can add some echo to check.
Like the link I listed, the string definition in bash script like:

a=“Hello”

echo $a

The result should be
Hello

Not
Hello"

You can also remove ‘"’ in the script.

br
Chenjian

I removed the “” from the script and check but the problem is same. I think that is not the issue.

Do I need to try this in sudo mode?

You can check the image below:

Hello,
That’s a good start, and at least, makefile is called correct bin.

You can try following:

  1. execute the xxx/xx-gcc directly, and check whether it has the same problem.
  2. run ldd xxx/xxx-gcc to check whether some so is missed.

br
Chenjian

This “gcc-arm-none-eabi-10.3-2021.10” tool chain is not giving the env issue but its throwing the other errors.

arch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory
aarch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory
aarch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory
aarch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory
aarch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory
aarch64-binfmt-P: Could not open ‘/lib/ld-linux-aarch64.so.1’: No such file or directory