LWIP STM Build Issues

Sysprogs forums Forums VisualGDB LWIP STM Build Issues

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #9933
    dbeyzade
    Participant

    I am trying to get LWIP to build for my custom board project using STM32 platform and having issues. As a test I tried recreating the tutorial here:

    http://visualgdb.com/tutorials/arm/stm32/lwip/

    When I build I am receiving the same errors as my custom project relating to incomplete type ‘struct timeval’ and various other issues relating to time.h

    Could someone else please try and see if they have the same issue following the tutorial steps?

    Thank you

     

    Daniel

    #9935
    support
    Keymaster

    Hi,

    We have encountered this problem while testing our BSP and it is normally resolved by adding ‘LWIP_TIMEVAL_PRIVATE=0’ to the preprocessor macro list.

    VisualGDB should do this automatically when you create a new lwIP-based project. If this does not happen, please let us know.

    #9940
    dbeyzade
    Participant

    I have added this and it has no effect on either my own project, or following your tutorial. Any further help appreciated.

    Daniel

    #9944
    support
    Keymaster

    Hi,

    It is hard to give any detailed hints without knowing the exact errors you encounter. The general advice would be to understand what causes the error message and how to modify the configuration (or patch the source) to eliminate it. E.g. some of the timeval problems happen because of this definition (that can be located by viewing the ‘output window’ and locating the ‘previous definition’ line):

    #ifndef LWIP_TIMEVAL_PRIVATE
    #define LWIP_TIMEVAL_PRIVATE 1
    #endif
    
    #if LWIP_TIMEVAL_PRIVATE
    struct timeval {
      long    tv_sec;         /* seconds */
      long    tv_usec;        /* and microseconds */
    };
    #endif /* LWIP_TIMEVAL_PRIVATE */

    Defining LWIP_TIMEVAL_PRIVATE=0 effectively disables the conflicting definition. If you are getting a different error and still cannot pinpoint it, please let us know the details and we will point you to the right direction.

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