Skip to main content
Associate
July 25, 2023
Question

compilation error after update to V 1.13.0

  • July 25, 2023
  • 3 replies
  • 3035 views

Since the latest update to STM32Cube V 1.13.0 I get an error during compilation of sysmem.c:

error: unknown type name 'caddr_t'

The reason seems to be a missing path to sys/types.h. At least adding

#include <sys/types.h>

to my code solves the problem.But I don't like editing system code.Is there any better solution?
    This topic has been closed for replies.

    3 replies

    RhSilicon
    Lead
    July 25, 2023

    When a bug occurs with the Arduino IDE, many users stop using that version. They use the previous version until a new version is released. Maybe that's the case this time with the STM32CubeIDE. I've seen other similar bug reports here.

    HoffartAuthor
    Associate
    July 25, 2023

    I just noticed that the function called inside sysmem.c is nowhere called.

    Deleting the file solves the problem - it seems it is not needed any more.

    Semer CHERNI
    ST Employee
    July 26, 2023

    Hello @RhSilicon 

    Yes indeed the GCC version was upgraded from GCC10 to GCC11 with the STM32CubeIDE 1.13.0.

    You are right with the solution you have proposed of changing the caddr_t to void* or include the <sys/types.h> to sysmem.c.

    With this been said, I will raise the issue internally to review it and provide a permanent solution.

    KR,
    Semer.

    To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
    RhSilicon
    Lead
    July 27, 2023

    "You are right with the solution you have proposed of changing the caddr_t to void* or include the <sys/types.h> to sysmem.c."

    Hi, I believe there was some mistake in the forum when mentioning the OP, I ended up being mentioned, but I am not the author of the mentioned proposal. Thanks.

    Piranha
    Principal III
    July 27, 2023

    There is a mistake and it even has a name...