debugging STM32 makefile project on W10 WSL

Sysprogs forums Forums VisualGDB debugging STM32 makefile project on W10 WSL

This topic contains 29 replies, has 2 voices, and was last updated by  kentmartin99@gmail.com 2 weeks ago.

Viewing 15 posts - 16 through 30 (of 30 total)
  • Author
    Posts
  • #26380

    support
    Keymaster

    This is likely a VisualGDB bug caused by a recent change in the WSL path mapping logic.

    Please try the new build linked in our previous reply (VisualGDB-5.5.1.3339.msi). We have removed the Source Code Access page for Linux Subsystem projects there to avoid any confusion, so the bug should no longer trigger.

    #26381

    ok I have set up project as you have described with the new version of GDB.

    The result is the same:

    i.e.

    make

    arm-none-eabi-g++ build/obj/crt0_v7m.o build/obj/vectors.o build/obj/chcoreasm_v7m.o build/obj/canard.o build/obj/canard_stm32.o build/obj/crt1.o build/obj/chsys.o build/obj/chdebug.o build/obj/chtrace.o build/obj/chvt.o build/obj/chschd.o build/obj/chthreads.o build/obj/chtm.o build/obj/chstats.o build/obj/chregistry.o build/obj/chsem.o build/obj/chmtx.o build/obj/chcond.o build/obj/chevents.o build/obj/chmsg.o build/obj/chdynamic.o build/obj/chmboxes.o build/obj/chmemcore.o build/obj/chheap.o build/obj/chmempools.o build/obj/chfactory.o build/obj/chcore.o build/obj/chcore_v7m.o build/obj/osal.o build/obj/hal.o build/obj/hal_buffers.o build/obj/hal_queues.o build/obj/hal_mmcsd.o build/obj/hal_adc.o build/obj/hal_can.o build/obj/hal_crypto.o build/obj/hal_dac.o build/obj/hal_ext.o build/obj/hal_gpt.o build/obj/hal_i2c.o build/obj/hal_i2s.o build/obj/hal_icu.o build/obj/hal_mac.o build/obj/hal_mmc_spi.o build/obj/hal_pal.o build/obj/hal_pwm.o build/obj/hal_qspi.o build/obj/hal_rtc.o build/obj/hal_sdc.o build/obj/hal_serial.o build/obj/hal_serial_usb.o build/obj/hal_spi.o build/obj/hal_st.o build/obj/hal_uart.o build/obj/hal_usb.o build/obj/hal_wdg.o build/obj/nvic.o build/obj/stm32_isr.o build/obj/hal_lld.o build/obj/hal_adc_lld.o build/obj/hal_can_lld.o build/obj/hal_dac_lld.o build/obj/stm32_dma.o build/obj/hal_ext_lld.o build/obj/hal_pal_lld.o build/obj/hal_i2c_lld.o build/obj/hal_mac_lld.o build/obj/hal_usb_lld.o build/obj/hal_qspi_lld.o build/obj/hal_rtc_lld.o build/obj/hal_i2s_lld.o build/obj/hal_spi_lld.o build/obj/hal_sdc_lld.o build/obj/hal_st_lld.o build/obj/hal_gpt_lld.o build/obj/hal_icu_lld.o build/obj/hal_pwm_lld.o build/obj/hal_serial_lld.o build/obj/hal_uart_lld.o build/obj/hal_wdg_lld.o build/obj/chprintf.o build/obj/memstreams.o build/obj/nullstreams.o build/obj/syscalls.o build/obj/app_shared.o build/obj/board.o build/obj/main.o build/obj/libstdcpp.o build/obj/sys_console.o build/obj/sys.o build/obj/uavcan.o build/obj/ch.o build/obj/syscalls_cpp.o -mcpu=cortex-m4 -Wdouble-promotion -Wswitch-enum -Wfloat-equal -fno-strict-aliasing -fno-strict-overflow -Wno-implicit-fallthrough -falign-functions=16 -U__STRICT_ANSI__ -fno-exceptions -fno-unwind-tables -fno-stack-protector -fno-builtin-printf -fno-builtin-fprintf -fno-builtin-vprintf -fno-builtin-vfprintf -fno-builtin-puts -u_port_lock -u_port_unlock -u_exit -u_kill -u_getpid -uchThdExit -u__errno -fno-single-precision-constant -nodefaultlibs -lc -lgcc -lm -O0 -g3 -ffunction-sections -fdata-sections -fno-common -flto -mfloat-abi=hard -mfpu=fpv4-sp-d16 -fsingle-precision-constant -nostartfiles -L./ -Wl,-Map=build/kocherga_demo.map,–cref,–no-warn-mismatch,–library-path=/ld,–script=ld.ld,–gc-sections,–defsym=__process_stack_size__=0x1000,–defsym=__main_stack_size__=0x1000 -mno-thumb-interwork -mthumb -o build/kocherga_demo.elf
    make: arm-none-eabi-g++: Command not found
    chibios/os/common/startup/ARMCMx/compilers/GCC/rules.mk:258: recipe for target ‘build/kocherga_demo.elf’ failed
    make: *** [build/kocherga_demo.elf] Error 127
    ————————————————————-
    Command exited with code 2
    Executable: make
    Arguments:
    Directory: /mnt/c/Users/kentm/Documents/GITHUB/SW4STMWorkspace/kocherga-demo
    Command-line action failed

    ========== Project Build Summary ==========
    kocherga-demo-linux2 built in 00:02
    ========== Build: 0 Succeeded, 1 Failed ==========

     

    i.e. make: arm-none-eabi-g++: Command not found

    Can you please help to fix this problem.

     

    #26382

    support
    Keymaster

    This means that the gcc executable is not in the PATH variable.

    Please try running the “arm-none-eabi-g++” from the bash command line, take note of its location (directory containing the executable) and add the following environment variable to VisualGDB Project Properties -> Build -> Build Command -> Environment:

     

    #26383

    next time try

    Project Properties -> Build Settings-> Build Command -> Environment:

     

    Please stop omitting parts of the description , you have done this a number of times

     

    #26384

    and environment is hidden under a pulldown.

    You are making this harder than it needs to be

    #26385

    environment shows:

    LANG=en_US.UTF-8

    do you wish to keep this?

    if so , what is the separator?

     

    #26386

    is this correct:

    LANG=en_US.UTF-8; PATH=%PATH%:/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++

     

    please be more specific with an example please

     

    #26387

    is this correct

    LANG=en_US.UTF-8|PATH=%PATH%:/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++

     

    #26388

    make
    LANG = en_US.UTF-8 PATH = $PATH:/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++ DISPLAY = :10
    ————————————————————-
    Command exited with code 1
    Executable: make
    Arguments:
    Directory: /mnt/c/Users/kentm/Documents/GITHUB/SW4STMWorkspace/kocherga-demo
    Command-line action failed

    ========== Project Build Summary ==========
    kocherga-demo-linux2 built in 00:01
    ========== Build: 0 Succeeded, 1 Failed ==========

     

    it would appear not

     

    #26389

    I have tried many options but can’t seem to get the=is to work.

    Again please provide a sample

    I have tried:

    LANG=en_US.UTF-8|PATH=”%PATH%;/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++”

    LANG=en_US.UTF-8|PATH=%PATH%;/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++

    LANG=en_US.UTF-8|PATH=%PATH%:/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++

    LANG=en_US.UTF-8|PATH=%PATH%:”/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin//arm-none-eabi-g++”

     

    The path i found from “which” command from WSL terminal.

     

    #26390

    also tried

    LANG=en_US.UTF-8|PATH=%PATH%:/home/kentm/gcc-arm-none-eabi-7-2018-q2-update/bin/

    please advise what is wrong with commands

    #26391

    I removed the lang = … but odly it still shows up when I build again.

    Yes I have saved it, and changed the text slightly to ensure that it is getting updated when I build fine.

    But the Lang setting is getting added by your code somewhere behind the scenes.

     

    #26392

    I have wasted a lot of time again because of incomplete and incorrect information.

    Could you please provide correct complete information with a written example and try it yourself please.

     

    Thanks

    #26393

    support
    Keymaster

    Sorry, unfortunately it looks like the detail level you require is beyond what we can offer with our product support. VisualGDB is a productivity tool that automates common development tasks and provides convenient GUI for common routine operations. However, it still relies on the understanding of basic programming concepts and the ability to troubleshoot issues inside the code or build scripts that do not come from us.

    While we are happy to point to a VisualGDB setting that allows specifying the PATH variable, it is beyond the scope of our support to suggest a specific path string that will work with a specific project.

    We are sorry if this is not what you expected from our support, however we have to find a trade-off between covering underlying low-level tools while charging 10x-20x more per license, and restricting support to VisualGDB issues only while keeping our product price more affordable. We do offer paid consulting with hourly billing to bridge the gap between the 2 options, however it isn’t possible for us to provide this level of detail at the price of a regular license.

    #26396

    Hi,

    The error is because it does not accept the path string as you have specified, or for that matter at all.

    I have tried just adding PATH = %PATH%

    it fails with the same error.

    This is not a problem with the path on the machine but rather with the tool and or the way your specified the parameters.

    See below for the exact same error even if no path is added.

    “While we are happy to point to a VisualGDB setting that allows specifying the PATH variable, it is beyond the scope of our support to suggest a specific path string that will work with a specific project”

    I have asked for a generic solution not a specific one. I have detailed the results for countless entries including no path entry all with the same failure.

    You could easily just supply a sample showing the path to the root folder or even one with no extra path added as I have done, and check that it works.

    Please send me your name along with the contact information of your supervisor, or alternatively supply the simple information required or check that what you have supplied indeed does work.

    Thanks.

     

    make
    LANG = en_US.UTF-8 PATH = $PATH DISPLAY = :10
    ————————————————————-
    Command exited with code 1
    Executable: make
    Arguments:
    Directory: /mnt/c/Users/kentm/Documents/GITHUB/SW4STMWorkspace/kocherga-demo
    Command-line action failed

     

Viewing 15 posts - 16 through 30 (of 30 total)

You must be logged in to reply to this topic.