Sysprogs forums › Forums › VisualGDB › Errors after Mbed update to 5.9.2
- This topic has 4 replies, 2 voices, and was last updated 6 years, 5 months ago by support.
-
AuthorPosts
-
July 8, 2018 at 19:52 #21305kuczaParticipant
Hi, did someone try to build Mbed OS application after updating it to the newest 5.9.2 version? I have project with Mbed 5.6.3r3 and I can compile it without any problems. But after updating I get strange errors:
Severity Code Description Project File Line Suppression State
Error ‘$$com’ was not declared in this scope MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error [Clang IntelliSense] Error: token is not a valid binary operator in a preprocessor subexpression MbedDemo c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\mbed_error.h 43
Error [Clang IntelliSense] Error: use of undeclared identifier ‘filename’ MbedDemo c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\mbed_error.h 821
Error [Clang IntelliSense] Error: use of undeclared identifier ‘len$$’ MbedDemo c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\mbed_error.h 821
Error [Clang IntelliSense] Error: use of undeclared identifier ‘error’ MbedDemo c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\mbed_error.h 821
Error [Clang IntelliSense] Error: use of undeclared identifier ‘$$com’ MbedDemo c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\mbed_error.h 821
Error [Clang IntelliSense] Error: token is not a valid binary operator in a preprocessor subexpression c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\NonCopyable.h 19
Error [Clang IntelliSense] Error: token is not a valid binary operator in a preprocessor subexpression c:\users\kucza\appdata\local\visualgdb\embeddedbsps\arm-eabi\com.sysprogs.arm.mbed\platform\NonCopyable.h 161
Error token “.” is not valid in preprocessor expressions MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error token “.” is not valid in preprocessor expressions MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error token “.” is not valid in preprocessor expressions MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error ‘error’ was not declared in this scope MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error ‘filename’ was not declared in this scope MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1
Error ‘len$$’ was not declared in this scope MbedDemo D:\OTTO\VGDB\MbedDemo\MbedDemo\<command-line> 1July 8, 2018 at 19:53 #21306supportKeymasterHi,
This might be caused by changes to some mbed components. Please try opening VisualGDB Project Properties on the first page and then either change the MCU forth and back, or click “Regenerate MCU-specific files”. This should automatically update all project properties and remove any deprecated settings.
July 9, 2018 at 08:51 #21308kuczaParticipantI can confirm that after Regenerate MCU-specific files i was able to compile project with new Mbed OS. However it doesn’t work like on older OS version. After run it stuck in Reset_Handler of startup_stm32f407xx.S file. Default linker scrip (in attachment) is:
C:/Users/kucza/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.mbed/targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F407xG/device/TOOLCHAIN_GCC_ARM/STM32F407XG.ld
Is is proper one? Whay is the RAM shortned by 0x188?
RAM (rwx) : ORIGIN = 0x20000188, LENGTH = 128k – 0x188
July 9, 2018 at 08:59 #21309kuczaParticipantLinker script in txt format.
Attachments:
You must be logged in to view attached files.July 9, 2018 at 20:27 #21321supportKeymasterHi,
We have quickly rechecked the “blinking LED” project on the DISCO_V407VG target, but could not reproduce the crash. The linker scripts generally come directly from the mbed distro and are outside our control, so we are not able to offer any more backward compatibility than mbed itself does, sorry.
Please try checking whether a basic “blinking LED” project works with your device. If not, this could be a compatibility issue between the toolchain and the mbed BSP, so installing the latest ARM toolchain might fix this.
If the “Blinking LED” project works, please try comparing the initialization code of both projects to see if any of your code could be relying on the old linker script.
Another way to pinpoint this would be to try building your project with mbed-cli and then debugging it via Quick Debug (or by replacing the ELF file and not rebuilding the VisualGDB project). If the project built with mbed-cli works and the one built with VisualGDB doesn’t, this is likely our bug and we should be able to fix it if you could let us know more details (e.g. map files for both projects).
-
AuthorPosts
- You must be logged in to reply to this topic.