Undefined reference to `_sbrk'

Sysprogs forums Forums VisualGDB Undefined reference to `_sbrk'

Tagged: ,

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #11603
    ArneLaug
    Participant

    Hi

    I am trying to test a HR project “out-of-the-box”.

    I use the NRF52832__XXAA template. Compiling seems to be fine, excepts that I had to add: -mfpu=fpv4-sp-d16.

    When It comes to loading a got a problem that I don’t understand. This is the error message:

    “1>c:/gcc/gcc-arm-none-eabi-5_4-2016q3-20160926-win32/bin/../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/lib/armv7e-m/fpu\libc.a(lib_a-sbrkr.o): In function `_sbrk_r’:
    1>sbrkr.c : error : undefined reference to `_sbrk'”

    Any idea how I can fix this?

    Regards Arne

     

    #11605
    support
    Keymaster

    Hi,

    Please open VisualGDB Project Properties and check the “Provide default stubs for system calls” checkbox on the first page. This will include default implementations for functions like _sbrk() to your project.

    #11611
    ArneLaug
    Participant

    Hi

    Sorry I couldn’t find the “Provide default stubs for system calls” checkbox on the first page (or any other pages).

    Please see the attached image.

    Arne

     

    #11618
    support
    Keymaster

    Hi,

    Looks like the image did not get uploaded properly. Could you please try attaching it to the post via the “attachments” button below?

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.