Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
Jonathan Nieder wrote: --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: Debian Acpi Team pkg-acpi-de...@lists.alioth.debian.org Uploaders: Michael Meskes mes...@debian.org, Loic Minier l...@dooz.org Standards-Version: 3.9.1 -Build-Depends: debhelper (= 5) +Build-Depends: debhelper (= 5), dpkg (= 1.15.7) This should say: Build-Depends: debhelper (= 5), dpkg-dev (= 1.15.7) Sorry about that. Jonathan -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: [Pkg-acpi-devel] Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
How about this patch? I prefer fixing the bug over working around it. Even makes the patch smaller: --- acpid-2.0.8.orig/kacpimon/libnetlink.c +++ acpid-2.0.8/kacpimon/libnetlink.c @@ -518,7 +518,7 @@ int addraw_l(struct nlmsghdr *n, int maxlen, const void *data, int len) { - if ((int)NLMSG_ALIGN(n-nlmsg_len) + NLMSG_ALIGN(len) maxlen) { + if ((int)NLMSG_ALIGN(n-nlmsg_len) + (int)NLMSG_ALIGN(len) maxlen) { fprintf(stderr, addraw_l ERROR: message exceeded bound of %d\n,maxlen); return -1; } Michael -- Michael Meskes Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) Michael at BorussiaFan dot De, Meskes at (Debian|Postgresql) dot Org Jabber: michael.meskes at googlemail dot com VfL Borussia! Força Barça! Go SF 49ers! Use Debian GNU/Linux, PostgreSQL -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
Hi, Michael Meskes wrote: I prefer fixing the bug over working around it. Even makes the patch smaller: I should mention that gcc-4.6 gives another warning[1]. In general I think -Werror is a good tool for development but not so good when autobuilding, since warnings can subtly vary from version to version and platform to platform. My patch also mixed in a vaguely related feature --- namely, support for DEB_BUILD_OPTIONS, DEB_CFLAGS_APPEND, and buildflags.conf. Fixing warnings is good, too. :) Thanks for your work, Jonathan [1] See http://lists.debian.org/debian-devel-announce/2011/02/msg00012.html -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions
user debian-...@lists.debian.org clone 616194 -1 severity -1 important retitle -1 acpid: will FTBFS with gcc-4.6 (error: variable ‘type’ set but not used [-Werror=unused-but-set-variable]) usertags -1 - ftbfs-gcc-4.5 ftbfs-gcc-4.4 block 615157 by -1 quit Michael Meskes wrote: * Make both sides of the comparison signed so the package builds again. (Closes: #616194) Thanks! Cloning for the part that is suppressed by Bug#615157. Would you like the general build brittleness (use of -Werror) and lack of support for policy §4.9.1's DEB_BUILD_OPTIONS to be tracked separately? I'm leaving it as one bug for now for simplicity. -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
I should mention that gcc-4.6 gives another warning[1]. In general I Sorry, I didn't see that as I dn't use gcc-4.6. think -Werror is a good tool for development but not so good when autobuilding, since warnings can subtly vary from version to version and platform to platform. Which is why I think it should stay in there. We build on way more systems than upstream probably can, so keeping -Werror in will help the package. My patch also mixed in a vaguely related feature --- namely, support for DEB_BUILD_OPTIONS, DEB_CFLAGS_APPEND, and buildflags.conf. Valid point. Michael -- Michael Meskes Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) Michael at BorussiaFan dot De, Meskes at (Debian|Postgresql) dot Org Jabber: michael.meskes at googlemail dot com VfL Borussia! Força Barça! Go SF 49ers! Use Debian GNU/Linux, PostgreSQL -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
Michael Meskes wrote: Sorry, I didn't see that as I dn't use gcc-4.6. No problem; I should have mentioned it before. Which is why I think it should stay in there. We build on way more systems than upstream probably can, so keeping -Werror in will help the package. Fair enough. Now that gcc-4.6 has nicely parseable warnings, I wonder if buildds could grep for the string '[-W' so package maintainers could subscribe using a new PTS keyword to learn when their supposedly warning-free package acquires a warning. Roger et al, does that sound interesting to you? Is buildd the place to implement this sort of thing? Thanks for your thoughtfulness. Jonathan -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#616194: acpid: FTBFS (error: comparison between signed and unsigned integer expressions)
Source: acpid Version: 1:2.0.7-1 Severity: serious User: debian-...@lists.debian.org Usertags: ftbfs-gcc-4.6 ftbfs-gcc-4.5 ftbfs-gcc-4.4 Tags: patch Hi, Trying to build from source (first with gcc-4.6 as gcc and cc, then gcc-4.5, then gcc-4.4): | $ debian/rules build | cc -g -O2 -Wall -Wextra -Wundef -Wshadow -Werror -c -o libnetlink.o libnetlink.c | cc1: warnings being treated as errors | libnetlink.c: In function ‘addraw_l’: | libnetlink.c:521: error: comparison between signed and unsigned | make[1]: *** [libnetlink.o] Error 1 | make[1]: Leaving directory `/tmp/acpid-2.0.8/kacpimon' | make: *** [build] Error 2 How about this patch? Signed-off-by: Jonathan Nieder jrnie...@gmail.com --- debian/changelog | 11 +++ debian/control |2 +- debian/rules |8 ++-- 3 files changed, 18 insertions(+), 3 deletions(-) diff --git a/debian/changelog b/debian/changelog index 1d9ee9e..09e9bae 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,14 @@ +acpid (1:2.0.8-2) UNRELEASED; urgency=low + + * Do not pass -Werror to gcc at build time. (Otherwise, the +package fails to build from source.) + * Allow build flags to be customized by setting +DEB_BUILD_OPTIONS=noopt or DEB_CFLAGS_APPEND=-Werror in the +build-time environment. + * Build-Depends: dpkg-dev (= 1.15.7) for dpkg-buildflags. + + -- Jonathan Nieder jrnie...@gmail.com Thu, 03 Mar 2011 00:17:43 -0600 + acpid (1:2.0.8-1) unstable; urgency=low * Imported Upstream version 2.0.8 diff --git a/debian/control b/debian/control index 176adea..312f410 100644 --- a/debian/control +++ b/debian/control @@ -5,7 +5,7 @@ Maintainer: Debian Acpi Team pkg-acpi-de...@lists.alioth.debian.org Uploaders: Michael Meskes mes...@debian.org, Loic Minier l...@dooz.org Standards-Version: 3.9.1 -Build-Depends: debhelper (= 5) +Build-Depends: debhelper (= 5), dpkg (= 1.15.7) Vcs-Git: git://git.debian.org/git/pkg-acpi/acpid.git Vcs-Browser: http://git.debian.org/?p=pkg-acpi/acpid.git Homepage: http://acpid.sourceforge.net/ diff --git a/debian/rules b/debian/rules index 9f6fd7f..68b8328 100755 --- a/debian/rules +++ b/debian/rules @@ -1,11 +1,15 @@ #!/usr/bin/make -f +cflags := -W -Wall -Wundef -Wshadow -D_GNU_SOURCE \ + $(shell dpkg-buildflags --get CFLAGS) \ +-fno-strict-aliasing + build: dh_testdir chmod g-s -R * - $(MAKE) + $(MAKE) CFLAGS='$(cflags) $$(DEFS)' $(MAKE) man - (cd kacpimon; $(MAKE)) + (cd kacpimon; $(MAKE) CFLAGS='$(cflags) $$(DEFS)') clean: dh_testdir -- 1.7.4.1 -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org