[SOLVED] Embedded Studio 7.3.0 : Linking does not work when using RTT/Printf and manual linker script (prinops.c:(.text.libc.vfprintf_l+0x5c): undefined reference to `__SEGGER_RTL_vfprintf')

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] Embedded Studio 7.3.0 : Linking does not work when using RTT/Printf and manual linker script (prinops.c:(.text.libc.vfprintf_l+0x5c): undefined reference to `__SEGGER_RTL_vfprintf')

    Hello Forum,

    The title sums it up.

    I have a minimal project on a STM32 target (STM32F769I), along with J-Link base connected over JTAG.
    I have a printf call and this seems to cause some linking issues.

    I'm using GCC and a custom linker and startup files provided by STMicroelectronics with their HAL Drivers.

    Thank you !

    Full error message:

    Source Code

    1. C:/Program Files/SEGGER/SEGGER Embedded Studio for ARM 7.30/lib/libc_v7em_fpv5_d16_hard_t_le_eabi_balanced.a(prinops.o): in function `vfprintf_l':
    2. prinops.c:(.text.libc.vfprintf_l+0x5c): undefined reference to `__SEGGER_RTL_vfprintf'
    I'm using Segger Embedded Studio v7.3.0
  • Hello,

    Thank you for your inquiry.
    The recommended way to get started with Embedded Studio is to use the CPU Support Package for your device, create a new project for it and then add your third party sources to it.
    segger.com/products/developmen…o/technology/cpu-support/

    You can even import projects if needed:
    wiki.segger.com/Import_project…CubeMX_to_Embedded_Studio


    Many files e.g. startup files etc. are toolchain specific, so just simply replacing crucial files and hoping it will work is not a good strategy.

    Regarding the error message it is most likely that the library I/O is not set in your project:
    wiki.segger.com/Embedded_Studio_Library_IO


    However as mentioned above we recommend to set up your project differently so such things as printf simply work out of the box.

    Best regards,

    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.