[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: suggested fix



On 21/06/12 11:14, Steven Chamberlain wrote:
> On 21/06/12 08:57, Nicholas Bamber wrote:
>> 3.) You seem to see it fit to willfully cause an FTBS on Hurd, to make a
>> point.
> 
> To willfully allow an existing FTBFS on GNU/Hurd, to become a more
> explanatory FTBFS, which would someday go away and keep the intended
> functionality once the cause had been resolved in its build-deps.
> 
>> So I have raised a bug: #678358 to address the underlying issue.
> 
> Yes that was the nice thing to do here, thanks.
> 
>> * use #if defined(AF_LINK) && !defined(__GNU__) in  both places as that
>> is as close to a feature check as we can get
> 
> I'm fine with that, as it would be consistent, and it addresses the most
> important point which was the original test for (k)FreeBSD being too
> specific.
> 
> Regards,

Jamie,
	I have uploaded an NMU with a 2-day delay. The final diff is attached.
Given such a long and protracted discussion I hope you appreciate the
fix and incorporate it into your code as soon as possible. But of course
if you  have an issue with it you can still intervene.
diff -Nru pmacct-0.14.0/debian/changelog pmacct-0.14.0/debian/changelog
--- pmacct-0.14.0/debian/changelog	2012-05-24 08:11:21.000000000 +0100
+++ pmacct-0.14.0/debian/changelog	2012-06-21 12:39:45.000000000 +0100
@@ -1,3 +1,11 @@
+pmacct (0.14.0-1.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Added patch to handle AF_LINK on hurd and kfreebsd
+    platforms (Closes: #675836)
+
+ -- Nicholas Bamber <nicholas@periapt.co.uk>  Thu, 21 Jun 2012 12:39:40 +0100
+
 pmacct (0.14.0-1) unstable; urgency=low
 
   * New upstream release
diff -Nru pmacct-0.14.0/debian/control pmacct-0.14.0/debian/control
--- pmacct-0.14.0/debian/control	2012-02-10 02:33:51.000000000 +0000
+++ pmacct-0.14.0/debian/control	2012-06-21 11:43:56.000000000 +0100
@@ -2,7 +2,7 @@
 Section: net
 Priority: optional
 Maintainer: Jamie Wilkinson <jaq@debian.org>
-Build-Depends: debhelper (>= 7), zlib1g-dev, libpcap-dev, libpq-dev, libmysqlclient-dev, libsqlite3-dev
+Build-Depends: debhelper (>= 7), zlib1g-dev, libpcap-dev, libpq-dev, libmysqlclient-dev, libsqlite3-dev, kfreebsd-kernel-headers[kfreebsd-any]
 Standards-Version: 3.8.3
 
 Package: pmacct
diff -Nru pmacct-0.14.0/debian/patches/af_link.patch pmacct-0.14.0/debian/patches/af_link.patch
--- pmacct-0.14.0/debian/patches/af_link.patch	1970-01-01 01:00:00.000000000 +0100
+++ pmacct-0.14.0/debian/patches/af_link.patch	2012-06-21 11:54:28.000000000 +0100
@@ -0,0 +1,32 @@
+Author: Nicholas Bamber <nicholas@periapt.co.uk>
+Subject: Problems with the sockaddr_dl structure
+ The first issue is that on kfreebsd platforms,
+ where AF_LINK is legitimately defined, the definition
+ of sockaddr_dl is in net/if_dl.h which the upstream source
+ does not #include. The second issue is that Hurd also
+ defines AF_LINK but does not actually implement
+ that functionality - #678358. Bug #678375 was raised
+ to clear this up when it is sorted out in Hurd.
+Bug-Debian: http://bugs.debian.org/675836
+Last-Update: 2012-06-21
+--- a/src/isis/sockunion.c
++++ b/src/isis/sockunion.c
+@@ -27,6 +27,18 @@
+ #include "prefix.h"
+ #include "sockunion.h"
+ 
++/* As per #678358, Hurd defines AF_LINK but does not
++ * provide the functionality. When that bug is fixed
++ * These three lines could be removed and #678375 closed.
++ */
++#ifdef __GNU__
++#undef AF_LINK
++#endif
++
++#ifdef AF_LINK
++#include <net/if_dl.h>
++#endif
++
+ const char *
+ inet_sutop (union sockunion *su, char *str)
+ {
diff -Nru pmacct-0.14.0/debian/patches/series pmacct-0.14.0/debian/patches/series
--- pmacct-0.14.0/debian/patches/series	1970-01-01 01:00:00.000000000 +0100
+++ pmacct-0.14.0/debian/patches/series	2012-06-21 11:31:02.000000000 +0100
@@ -0,0 +1 @@
+af_link.patch

Reply to: