cancel
Showing results for 
Search instead for 
Did you mean: 

libtouchgfx-float-abi-hard.a cause build error in STM32CubeIDE

STran.2
Associate II

I followed instrunction in this online workshop STM32 Graphics Workshop - 10 TouchGFX lab temperature sensor display https://www.youtube.com/watch?v=rYrRjXyAYvs&list=PLnMKNibPkDnGNY9Ny4FWpM5bgC3b4XdbN&index=10

When I get to (minute 18:30) the step build in STM32CubeIDE I get this error list below. Please help.

17:31:33 **** Incremental Build of configuration Debug for project STM32H7B3I_DISCO ****

make -j4 all 

arm-none-eabi-g++ -o "STM32H7B3I_DISCO.elf" @"objects.list" -l:libtouchgfx-float-abi-hard.a -mcpu=cortex-m7 -T"C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\STM32H7B3LIHXQ_FLASH.ld" --specs=nosys.specs -Wl,-Map="STM32H7B3I_DISCO.map" -Wl,--gc-sections -static -L"C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc" -L"C:/_SandBox/2020_WShp_GFX/Lab/STM32H7BWorkshop2020_NSA/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc" -L"C:/STM32H7BWorkshop2020/DryRun/STM32H7BWorkshop2020/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc" -L"C:/_Temp/STM32H7BWorkshop2020/STM32H7BWorkshop2020/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc" -L"C:/STM32H7BWorkshop2020/STM32H7BWorkshop2020/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc" -L"C:/2020_ST_GFX_WS/STM32H7BWorkshop2020/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc" -LC:/TouchGFXProjects/STM32H7BWorkshop2020/Middlewares/ST/touchgfx/lib/core/cortex_m7/gcc --specs=nano.specs -mfpu=fpv5-d16 -mfloat-abi=hard -mthumb -Wl,--start-group -lc -lm -lstdc++ -lsupc++ -Wl,--end-group

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(LCD.o): In function `touchgfx::LCD::drawString(touchgfx::Rect, touchgfx::Rect const&, touchgfx::LCD::StringVisuals const&, unsigned short const*, ...)':

(.text._ZN8touchgfx3LCD10drawStringENS_4RectERKS1_RKNS0_13StringVisualsEPKtz+0x0): multiple definition of `touchgfx::LCD::drawString(touchgfx::Rect, touchgfx::Rect const&, touchgfx::LCD::StringVisuals const&, unsigned short const*, ...)'

Application/User/generated/Texts.o:C:/TouchGFXProjects/STM32H7BWorkshop2020/TouchGFX/generated/texts/src/Texts.cpp:51: first defined here

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(Font.o): In function `touchgfx::Font::getStringWidth(unsigned short const*, ...) const':

(.text._ZNK8touchgfx4Font14getStringWidthEPKtz+0x0): multiple definition of `touchgfx::Font::getStringWidth(unsigned short const*, ...) const'

Application/User/generated/Texts.o:C:/TouchGFXProjects/STM32H7BWorkshop2020/TouchGFX/generated/texts/src/Texts.cpp:14: first defined here

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(Font.o): In function `touchgfx::Font::getStringWidth(unsigned char, unsigned short const*, ...) const':

(.text._ZNK8touchgfx4Font14getStringWidthEhPKtz+0x0): multiple definition of `touchgfx::Font::getStringWidth(unsigned char, unsigned short const*, ...) const'

Application/User/generated/Texts.o:C:/TouchGFXProjects/STM32H7BWorkshop2020/TouchGFX/generated/texts/src/Texts.cpp:23: first defined here

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(Font.o):(.rodata._ZTVN8touchgfx4FontE+0x0): multiple definition of `vtable for touchgfx::Font'

Application/User/generated/Texts.o:(.rodata._ZTVN8touchgfx4FontE+0x0): first defined here

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(TextProvider.o): In function `touchgfx::TextProvider::initializeInternal()':

(.text._ZN8touchgfx12TextProvider18initializeInternalEv+0x0): multiple definition of `touchgfx::TextProvider::initializeInternal()'

Application/User/generated/Texts.o:C:/TouchGFXProjects/STM32H7BWorkshop2020/TouchGFX/generated/texts/src/Texts.cpp:46: first defined here

C:\TouchGFXProjects\STM32H7BWorkshop2020\STM32CubeIDE\Middlewares\ST\touchgfx\lib\core\cortex_m7\gcc\libtouchgfx-float-abi-hard.a(TextProvider.o): In function `touchgfx::TextProvider::getNextLigature(unsigned char)':

(.text._ZN8touchgfx12TextProvider15getNextLigatureEh+0x0): multiple definition of `touchgfx::TextProvider::getNextLigature(unsigned char)'

Application/User/generated/Texts.o:C:/TouchGFXProjects/STM32H7BWorkshop2020/TouchGFX/generated/texts/src/Texts.cpp:32: first defined here

Application/User/TouchGFX/target/generated/TouchGFXConfiguration.o:(.rodata._ZTV19FrontendApplication[_ZTV19FrontendApplication]+0x30): undefined reference to `touchgfx::Application::requestRedraw()'

Application/User/TouchGFX/target/generated/TouchGFXConfiguration.o:(.rodata._ZTV23FrontendApplicationBase[_ZTV23FrontendApplicationBase]+0x30): undefined reference to `touchgfx::Application::requestRedraw()'

Application/User/TouchGFX/target/generated/TouchGFXConfiguration.o:(.rodata._ZTVN8touchgfx14MVPApplicationE[_ZTVN8touchgfx14MVPApplicationE]+0x30): undefined reference to `touchgfx::Application::requestRedraw()'

collect2.exe: error: ld returned 1 exit status

make: *** [makefile:77: STM32H7B3I_DISCO.elf] Error 1

"make -j4 all" terminated with exit code 2. Build might be incomplete.

17:31:35 Build Failed. 6 errors, 0 warnings. (took 2s.49ms)

10 REPLIES 10

I did not try anymore to solve the error but I started a new project following the indication of the workshop with last firmware repository 1.08 , touchgfx 4.15 and idea 1.5 and it works. Cannot set the same clock setup.