Menu ▾ ▴

#4 Builderror on Ubuntu 12.04 (amd64)

v1.0_(example)
closed-invalid
None
5
2013-05-29
2012-09-05
No

Builderrors worked around by removing -Wshadow (error: declaration of ‘index’ shadows a global declaration) and adding -D_BSD_SOURCE (s6_addr32 not working otherwise) to AM_CFLAGS.

Discussion

  • Sebastien Vincent

    Can you post full compilation logs ?

     
  • Mikael Magnusson

     
  • Mikael Magnusson

     
  • Mikael Magnusson

     
  • Mikael Magnusson

    Logs uploaded

     
  • Sebastien Vincent

    It is strange because the code don't use s6_addr32. Can you post your /usr/include/netinet/in.h, please ?

     
  • Mikael Magnusson

    You find it at: svn cat svn://svn.eglibc.org/trunk/libc/inet/netinet/in.h

    #ifdef __GNUC__
    # define IN6_IS_ADDR_UNSPECIFIED(a) \
    (__extension__ \
    ({ const struct in6_addr *__a = (const struct in6_addr *) (a); \
    __a->s6_addr32[0] == 0 \
    && __a->s6_addr32[1] == 0 \
    && __a->s6_addr32[2] == 0 \
    && __a->s6_addr32[3] == 0; }))
    ...

     
  • Sebastien Vincent

    OK, I understand now.

    It seems that the IN6_ADDR_* macro are defined with s6_addr32 if __GNUC__ is used (which is always the case for gcc) and the s6_addr32 in in6_addr structure are only defined if __USE_MISC or __USE_GNU.

    So it seems eglic has introduced this "bug" recently. Can you report that to them or Ubuntu team ?

    TurnServer respects the ISO C99 and POSIX standard and I don't want to use GNU or other non-standard extension (__BSD_SOURCE), so I will try to see if something can be done to override this in the TurnServer code.

     
  • Mikael Magnusson

    Do you have a reference to the part of the ISO C99 or POSIX standard defining the IN6_ADDR_* macros in that case?

     
  • Sebastien Vincent

    It is defined in the RFC 3493

    "
    As the API matured and stabilized, it was incorporated into the Open
    Group's Networking Services (XNS) specification, issue 5.2, which was
    subsequently incorporated into a joint Open Group/IEEE/ISO standard
    [3].
    ...
    ...
    [3] IEEE Std. 1003.1-2001 Standard for Information Technology --
    Portable Operating System Interface (POSIX). Open Group
    Technical Standard: Base Specifications, Issue 6, December 2001.
    ISO/IEC 9945:2002. http://www.opengroup.org/austin
    "

     
  • Mikael Magnusson

    Reported as Ubuntu bug #1086787: https://bugs.launchpad.net/bugs/1086787

     
  • Sebastien Vincent

    I have report the problem on eglibc mailing-list with a patch: http://www.eglibc.org/archives/patches/msg01251.html.

     
  • Sebastien Vincent

    I finally decided to modify source code to make it possible to compile on recent glibc (now 2.17 on Debian testing), by adding the _SVID_SOURCE compilation flag.

    Fix is in SVN revision 235.

     
  • Sebastien Vincent

    • status: open --> accepted
    • assigned_to: Sebastien Vincent
    • Group: --> v1.0_(example)
     
  • Sebastien Vincent

    • status: accepted --> closed-invalid
     

Log in to post a comment.