Sysprogs forums › Forums › VisualGDB › VisualGDB stuck trying to build
- This topic has 8 replies, 2 voices, and was last updated 5 years, 4 months ago by support.
-
AuthorPosts
-
July 26, 2019 at 12:39 #25469tm123Participant
I have a project with .cpp files and one .s file and the compiler gets stuck building the assembly file. There is no error it just hangs on it. However it might be hanging on main.cpp because that’s the one Atollic hangs on as well and in VisualGDB in the output it doesn’t say 1>main.cpp it says 1>kernel_asm.s
The code compiles fine on Keil.
Any ideas?
July 26, 2019 at 12:43 #25470tm123ParticipantYeah it seems to be the assembly file this time. I emptied it and it “compiles” it.
July 26, 2019 at 13:05 #25471tm123ParticipantEven tried downgrading the ARM toolchain or using the latest one. Same thing.
July 26, 2019 at 13:27 #25473tm123ParticipantSwitched to make instead of msbuild and the output error was this
1>—— Build started: Project: EmbeddedProject2, Configuration: Debug Win32 ——
1>VisualGDB: Run “C:\SysGCC\arm-eabi\bin\make.exe CONFIG=Debug -j12” in directory “C:\Users\TM\source\repos\EmbeddedProject2\EmbeddedProject2” on local computer
1>C:/SysGCC/arm-eabi/bin/arm-eabi-g++.exe -ggdb -ffunction-sections -fno-exceptions -fno-rtti -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c EmbeddedProject2.cpp -o Debug/EmbeddedProject2.o -MD -MF Debug/EmbeddedProject2.dep
1>as -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c kernel_asm.s -o Debug/kernel_asm.o -MD -MF Debug/kernel_asm.dep
1>as: unrecognized option `-mcpu=cortex-m4′
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_pccard.c -o Debug/stm32f3xx_hal_pccard.o -MD -MF Debug/stm32f3xx_hal_pccard.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_pcd.c -o Debug/stm32f3xx_hal_pcd.o -MD -MF Debug/stm32f3xx_hal_pcd.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_pcd_ex.c -o Debug/stm32f3xx_hal_pcd_ex.o -MD -MF Debug/stm32f3xx_hal_pcd_ex.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_pwr.c -o Debug/stm32f3xx_hal_pwr.o -MD -MF Debug/stm32f3xx_hal_pwr.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_pwr_ex.c -o Debug/stm32f3xx_hal_pwr_ex.o -MD -MF Debug/stm32f3xx_hal_pwr_ex.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_rcc.c -o Debug/stm32f3xx_hal_rcc.o -MD -MF Debug/stm32f3xx_hal_rcc.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_rcc_ex.c -o Debug/stm32f3xx_hal_rcc_ex.o -MD -MF Debug/stm32f3xx_hal_rcc_ex.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_rtc.c -o Debug/stm32f3xx_hal_rtc.o -MD -MF Debug/stm32f3xx_hal_rtc.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_rtc_ex.c -o Debug/stm32f3xx_hal_rtc_ex.o -MD -MF Debug/stm32f3xx_hal_rtc_ex.dep
1>C:/SysGCC/arm-eabi/bin/arm-eabi-gcc.exe -ggdb -ffunction-sections -O0 -mcpu=cortex-m4 -mthumb -mfpu=fpv4-sp-d16 -mfloat-abi=hard -I. -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Inc/Legacy -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Device/ST/STM32F3xx/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Include -IC:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/CMSIS_HAL/Core/Include -DDEBUG=1 -DARM_MATH_CM4 -Dflash_layout -DSTM32F303K8 -DUSE_LEGACY -DSTM32F303x8 -DUSE_FULL_LL_DRIVER -c C:/Users/TM/AppData/Local/VisualGDB/EmbeddedBSPs/arm-eabi/com.sysprogs.arm.stm32/STM32F3xxxx/STM32F3xx_HAL_Driver/Src/stm32f3xx_hal_sdadc.c -o Debug/stm32f3xx_hal_sdadc.o -MD -MF Debug/stm32f3xx_hal_sdadc.dep
1>make: *** [Debug/kernel_asm.o] Error 1
1>make: *** Waiting for unfinished jobs….
1>————————————————————-
1>Command exited with code 2
1>Executable: C:\SysGCC\arm-eabi\bin\make.exe
1>Arguments: CONFIG=Debug -j12
1>Directory: C:\Users\TM\source\repos\EmbeddedProject2\EmbeddedProject2
1>VisualGDB : error : Command-line action failed
1>VisualGDB : error : Build has failed. See the Output window for more details.
1>H:\VS\MSBuild\Microsoft\VC\v160\Microsoft.MakeFile.Targets(44,5): error MSB3073: The command “”C:\Program Files (x86)\Sysprogs\VisualGDB\\VisualGDB.exe” /build “C:\Users\TM\source\repos\EmbeddedProject2\EmbeddedProject2\EmbeddedProject2.vcxproj” “/solution:C:\Users\TM\source\repos\EmbeddedProject2\EmbeddedProject2.sln” “/config:Debug” “/platform:Win32″” exited with code 1.
1>Done building project “EmbeddedProject2.vcxproj” — FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========- This reply was modified 5 years, 4 months ago by tm123.
July 26, 2019 at 16:24 #25478tm123ParticipantSo apparently it’s because Keil uses different assembly directives than GCC and I switched to the proper ones.
Now the issue is that Keil assembly allows you to access registers 8 to registers 12 using thumb mode but GCC doesn’t. And if you force arm mode it doesn’t compile because the processor won’t let it.
July 26, 2019 at 16:31 #25479tm123ParticipantProblem solved! I put the .thumb directive in the wrong place and needed .syntax unified to go with it;
I had to convert;
AREA |.text|, CODE, READONLY, ALIGN=2
THUMB
PRESERVE8To this;
.thumb
.syntax unified
.section .text, “ax”
.balign 4
.eabi_attribute Tag_ABI_align_preserved, 1It compiles now.
July 26, 2019 at 17:40 #25483supportKeymasterSorry for the delay and good to know it works. Just FYI, if you are using the STM32 libraries, ST typically provides Keil-compatible, GCC-compatible and IAR-compatible versions of the assembly files, so you can simply pick a GCC-compatible one instead of manually editing the file that uses the Keil syntax.
July 26, 2019 at 17:43 #25485tm123ParticipantGood to know but this is a file I wrote from scratch and I only ever used and learned to write ARM assembler using Keil.
July 26, 2019 at 17:48 #25487supportKeymasterThanks for clarifying this. In that case you would indeed need to edit the file manually.
-
AuthorPosts
- You must be logged in to reply to this topic.