Skip to content

Linker error after using "std::chrono::steady_clock::now()" #2129

Closed
@github-rkaiser

Description

@github-rkaiser

If a am using

#  include <chrono>
...
std::chrono::steady_clock::now()

with a H745ZI, C031C6 or L476RG, I get the linker error

ld.exe: m-none-eabi\lib\thumb\v6-m\nofp\libc_nano.a(libc_a-gettimeofdayr.o): in function _gettimeofday_r
gettimeofdayr.c*: (.text._gettimeofday_r+0xe): undefined reference to _gettimeofday
 
collect2.exe*: error: ld returned 1 exit status

Error linking for board Nucleo-64 (STMicroelectronics_Nucleo_64)
Debug build failed for project 'STM32-C031C6' 

Please add he missing function to the library.

Thanks
Richard

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions