cancel
Showing results for 
Search instead for 
Did you mean: 

STM32MP1 ecosystem 3.10 Developer package kernel fails to build on Ubuntu 21.10 (glibc 3.22 not found)

debugging
Lead

make ARCH=arm uImage vmlinux dtbs LOADADDR=0xC2000040

 GEN    Makefile

 HOSTCC scripts/mod/mk_elfconfig

/media/user/H3D1P2/Tools/STM32MP1/STM_ECO_3.10/Developer-Package/SDK/sysroots/x86_64-ostl_sdk-linux/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so: error loading plugin: /media/user/H3D1P2/Tools/STM32MP1/STM_ECO_3.10/Developer-Package/SDK/sysroots/x86_64-ostl_sdk-linux/lib/libc.so.6: version `GLIBC_2.33' not found (required by /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so)

collect2: error: ld returned 1 exit status

make[2]: *** [scripts/Makefile.host:95: scripts/mod/mk_elfconfig] Error 1

make[1]: *** [/media/user/H3D1P2/Tools/STM32MP1/STM_ECO_3.10/Developer-Package/stm32mp1-openstlinux-5.10-dunfell-mp1-21-11-17/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.10.61-stm32mp-r2-r0/linux-5.10.61/Makefile:1214: prepare0] Error 2

make: *** [/media/user/H3D1P2/Tools/STM32MP1/STM_ECO_3.10/Developer-Package/stm32mp1-openstlinux-5.10-dunfell-mp1-21-11-17/sources/arm-ostl-linux-gnueabi/linux-stm32mp-5.10.61-stm32mp-r2-r0/linux-5.10.61/Makefile:185: __sub-make] Error 2

sudo apt-get install libc6

Reading package lists... Done

Building dependency tree... Done

Reading state information... Done

libc6 is already the newest version (2.34-0ubuntu3).

0 upgraded, 0 newly installed, 0 to remove and 0 not upgrad

Linux H3U1 5.13.0-28-lowlatency #31-Ubuntu SMP PREEMPT Thu Jan 13 18:29:33 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

1 ACCEPTED SOLUTION

Accepted Solutions
Kevin HUBER
ST Employee

Hello @debugging​ ,

At this time, we only support up to Ubuntu 20.04 as explained on the wiki: https://wiki.st.com/stm32mpu/wiki/PC_prerequisites#Recommended_PC_configurations

Here, if you have done all the steps, the error seems related to the content that you put in bold.

version `GLIBC_2.33' not found (required by /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so)

Our Developer Package is made to use glibc v2.33 and by looking at your traces, the v2.34 is installed on your machine.

Can you try to install glibc v2.33 on your machine and make a symbolic link on this version, to use it by default instead of 2.34.

Otherwise, I recommend you if possible to go back to Ubuntu 20.04, because on 21.10, you will surely encounter other problems.

Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

View solution in original post

3 REPLIES 3
Kevin HUBER
ST Employee

Hello @debugging​ ,

Be sure to have made the source of the SDK environment script before trying to build:

https://wiki.st.com/stm32mpu/wiki/Getting_started/STM32MP1_boards/STM32MP157x-DK2/Develop_on_Arm%C2%AE_Cortex%C2%AE-A7/Install_the_SDK#

PC $> cd $HOME/STM32MPU_workspace/STM32MP15-Ecosystem-v3.1.0/Developer-Package 
PC $> source SDK/environment-setup-cortexa7t2hf-neon-vfpv4-ostl-linux-gnueabi

And before building you have to prepare the linux sources as specified in the getting started, in the part 1.1.1.2.3.3 Prepare the Linux® kernel source code of:

https://wiki.st.com/stm32mpu/wiki/Getting_started/STM32MP1_boards/STM32MP157x-DK2/Develop_on_Arm%C2%AE_Cortex%C2%AE-A7/Modify,_rebuild_and_reload_the_Linux%C2%AE_kernel#

This tutorial had been test with Ubuntu 20.04, please tell me if you still have some errors after my recommendation.

Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
debugging
Lead

Yes , those steps were done and the result shows the error when building the kernel

echo $ARCH

arm

$ echo $CROSS_COMPILE

arm-ostl-linux-gnueabi-

$CC --version

arm-ostl-linux-gnueabi-gcc (GCC) 9.3.0

Copyright (C) 2019 Free Software Foundation, Inc.

This is free software; see the source for copying conditions. There is NO

warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

echo $OECORE_SDK_VERSION

3.1.11-openstlinux-5.10-dunfell-mp1-21-11-17

Kevin HUBER
ST Employee

Hello @debugging​ ,

At this time, we only support up to Ubuntu 20.04 as explained on the wiki: https://wiki.st.com/stm32mpu/wiki/PC_prerequisites#Recommended_PC_configurations

Here, if you have done all the steps, the error seems related to the content that you put in bold.

version `GLIBC_2.33' not found (required by /usr/lib/gcc/x86_64-linux-gnu/11/liblto_plugin.so)

Our Developer Package is made to use glibc v2.33 and by looking at your traces, the v2.34 is installed on your machine.

Can you try to install glibc v2.33 on your machine and make a symbolic link on this version, to use it by default instead of 2.34.

Otherwise, I recommend you if possible to go back to Ubuntu 20.04, because on 21.10, you will surely encounter other problems.

Regards,

Kevin

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.