I want to convert a uVision .uvprojx project to a csolution project with uv2csolution. But with the following settings in uVision
I get the following error message when compiling the csolution project:
[1/4] Building AS_ARM object CMakeFiles/TestProjekt.dir/C_/SOME_PATH/Test/RTE/Device/STM32L486JGYx/startup_stm32l486xx.o FAILED: CMakeFiles/TestProjekt.dir/C_/SOME_PATH/Test/RTE/Device/STM32L486JGYx/startup_stm32l486xx.o c:\SOME_OTHER_PATH\.vcpkg\artifacts\fd3d78d7\compilers.arm.armclang\6.20.0\bin\armclang.exe -Ic:/SOME_PATH/Test/RTE/_Target_1 -IC:/Users/USER/AppData/Local/Arm/packs/ARM/CMSIS/5.9.0/CMSIS/Core/Include -IC:/Users/USER/AppData/Local/Arm/packs/Keil/STM32L4xx_DFP/2.6.2/Drivers/CMSIS/Device/ST/STM32L4xx/Include -mcpu=Cortex-M4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard -Wa,armasm,--pd,"STM32L486xx SETA 1" -Wa,armasm,--pd,"_RTE_ SETA 1" -Wa,armasm,--pd,"CONFIG_PATH SETS config/Config.hpp" -g -O0 --target=arm-arm-none-eabi -c -masm=auto -o CMakeFiles/TestProjekt.dir/C_/SOME_PATH/Test/RTE/Device/STM32L486JGYx/startup_stm32l486xx.o C:/SOME_PATH/Test/RTE/Device/STM32L486JGYx/startup_stm32l486xx.s
Warning: A1950W: The legacy armasm assembler is deprecated. Consider using the armclang integrated assembler instead.
"<command line>", line 3 (column 18): Error: A1516E: Bad symbol 'config', not defined or external
3 00000000 CONFIG_PATH SETS config/Config.hpp
^
This error message when compiling the assembler file surprised me, because CONFIG_PATH=config/Config.hpp is actually only set for the C++ compiler and not for the assembler. So I took a closer look at the generated .cproject.yaml and the CONFIG_PATH shows up under the define section.
But according to https://github.com/Open-CMSIS-Pack/devtools/issues/607 everything listed under define is valid for C/C++ and the assembler. As a workaround it says that you have to use misc section. So if I move this manually from define to misc section the code compiles without any error.
Sorry for the inconvenience caused. I am glad to hear you found a way how to fix the problem in your converted project. We have a developer looking into solving this in the converter.
Type: Bug Report
Describe the bug
I want to convert a uVision .uvprojx project to a csolution project with uv2csolution. But with the following settings in uVision
I get the following error message when compiling the csolution project:
This error message when compiling the assembler file surprised me, because
CONFIG_PATH=config/Config.hpp
is actually only set for the C++ compiler and not for the assembler. So I took a closer look at the generated .cproject.yaml and the CONFIG_PATH shows up under thedefine
section.But according to https://github.com/Open-CMSIS-Pack/devtools/issues/607 everything listed under
define
is valid for C/C++ and the assembler. As a workaround it says that you have to usemisc
section. So if I move this manually fromdefine
tomisc
section the code compiles without any error.So until the
define-asm
section from https://github.com/Open-CMSIS-Pack/devtools/issues/607 is implemented, uv2csolution should put the defines into themisc
and not to thedefine
section.To Reproduce Steps to reproduce the behavior:
TestProject.uvprojx
and clickConvert µVision project to csolution
CMSIS
and then clickBuild