Bug 76138 - Build failure on i386, powerpc: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
Summary: Build failure on i386, powerpc: error: comparison between signed and unsigned...
Status: RESOLVED WORKSFORME
Alias: None
Product: nice
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: Other All
: medium major
Assignee: Olivier Crête
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-13 18:51 UTC by Dominique Leuenberger
Modified: 2015-03-28 00:05 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Dominique Leuenberger 2014-03-13 18:51:10 UTC
Nice 0.1.5 fails to build on 32bit architecture:

make[1]: Entering directory '/home/abuild/rpmbuild/BUILD/libnice-0.1.5/agent'
  CC       pseudotcp.lo
pseudotcp.c: In function 'pseudo_tcp_socket_get_next_clock':
pseudotcp.c:949:33: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
   if (*timeout == 0 || *timeout < now)
                                 ^
pseudotcp.c:194:39: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                       ^
pseudotcp.c:953:16: note: in expansion of macro 'min'
     *timeout = min (*timeout, now + CLOSED_TIMEOUT);
                ^
pseudotcp.c:194:60: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                                            ^
pseudotcp.c:953:16: note: in expansion of macro 'min'
     *timeout = min (*timeout, now + CLOSED_TIMEOUT);
                ^
pseudotcp.c:194:39: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                       ^
pseudotcp.c:957:14: note: in expansion of macro 'min'
   *timeout = min (*timeout, now + DEFAULT_TIMEOUT);
              ^
pseudotcp.c:194:60: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                                            ^
pseudotcp.c:957:14: note: in expansion of macro 'min'
   *timeout = min (*timeout, now + DEFAULT_TIMEOUT);
              ^
pseudotcp.c:194:39: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                       ^
pseudotcp.c:960:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->t_ack + priv->ack_delay);
                ^
pseudotcp.c:194:60: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                                            ^
pseudotcp.c:960:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->t_ack + priv->ack_delay);
                ^
pseudotcp.c:194:39: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                       ^
pseudotcp.c:963:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->rto_base + priv->rx_rto);
                ^
pseudotcp.c:194:60: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                                            ^
pseudotcp.c:963:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->rto_base + priv->rx_rto);
                ^
pseudotcp.c:194:39: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                       ^
pseudotcp.c:966:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->lastsend + priv->rx_rto);
                ^
pseudotcp.c:194:60: error: signed and unsigned type in conditional expression [-Werror=sign-compare]
 #  define min(first, second) ((first) < (second) ? (first) : (second))
                                                            ^
pseudotcp.c:966:16: note: in expansion of macro 'min'
     *timeout = min(*timeout, priv->lastsend + priv->rx_rto);
                ^
cc1: all warnings being treated as errors
Makefile:501: recipe for target 'pseudotcp.lo' failed
make[1]: *** [pseudotcp.lo] Error 1
make[1]: Leaving directory '/home/abuild/rpmbuild/BUILD/libnice-0.1.5/agent'
Makefile:411: recipe for target 'all' failed
Comment 1 Simon McVittie 2014-03-31 08:31:40 UTC
Debian's i386, kfreebsd-i386, hurd-i386 and powerpc autobuilders had the same build failure. Logs available from <https://buildd.debian.org/status/package.php?p=libnice>.

i386: https://buildd.debian.org/status/fetch.php?pkg=libnice&arch=i386&ver=0.1.5-1&stamp=1395850406

powerpc: https://buildd.debian.org/status/fetch.php?pkg=libnice&arch=powerpc&ver=0.1.5-1&stamp=1395850382
Comment 2 Simon McVittie 2014-03-31 08:41:17 UTC
I think this might only be a build failure (and not just a warning) because

    LIBNICE_RELEASE="no"

was not changed to "yes" in configure.ac when doing the 0.1.5 release.

I don't know whether the warnings also indicate a real bug, though.
Comment 3 Olivier Crête 2014-03-31 18:03:56 UTC
For my own reference, full build log in i386:
https://buildd.debian.org/status/fetch.php?pkg=libnice&arch=i386&ver=0.1.5%2Brc20140331-0exp1&stamp=1396287999
Comment 4 Olivier Crête 2014-03-31 21:48:18 UTC
These should be fixed in git master.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.