[libnet-arp-perl] 01/04: add patch adding missing #include's on BSD

Damyan Ivanov dmn at moszumanska.debian.org
Tue Aug 19 07:28:27 UTC 2014


This is an automated email from the git hooks/post-receive script.

dmn pushed a commit to branch master
in repository libnet-arp-perl.

commit 4ec47926cdb73c689e9224c17466bfe3efebd52f
Author: Damyan Ivanov <dmn at debian.org>
Date:   Tue Aug 19 07:08:16 2014 +0000

    add patch adding missing #include's on BSD
    
    Fixes FTBFS on kfreebsd-* because of unknown uint64_t type.
    Closes:  #758283
---
 debian/patches/bsd-missing-includes.patch | 45 +++++++++++++++++++++++++++++++
 debian/patches/series                     |  1 +
 2 files changed, 46 insertions(+)

diff --git a/debian/patches/bsd-missing-includes.patch b/debian/patches/bsd-missing-includes.patch
new file mode 100644
index 0000000..26c6ae7
--- /dev/null
+++ b/debian/patches/bsd-missing-includes.patch
@@ -0,0 +1,45 @@
+Description: missing #include's on BSD
+ net/if_arp.h uses uint64_t but does not include stdint.h itself, probably to
+ avoid header pollution. The patch adds the missing include, replacing
+ <sys/types.h>. Without it we aren't able to build the package of kfreebsd
+ (that's Debian fith FreeBSD kernel) because of:
+   /usr/include/net/if_arp.h:130:2: error: unknown type name 'uint64_t'
+ <stdio.h> is added because of the usage of sprintf()
+ <string.h> is added because of the usage of strncpy()/malloc()/free()/strlen()
+ <stdlib.h> is added because of the usage of exit()
+ Without these gcc complains about incompatible implicit declaration of the
+ built-in functions.
+Author: Damyan Ivanov <dmn at debian.org>
+Bug-Debian: https://bugs.debian.org/758283
+
+--- a/arp_lookup_bsd.c
++++ b/arp_lookup_bsd.c
+@@ -22,13 +22,16 @@ See the GNU General Public License for m
+ #include <sys/socket.h>
+ #include <net/if_dl.h>
+ #include <net/route.h>
++#include <stdint.h>
+ #include <net/if_arp.h>
+ #include <net/if.h>
+ #include <netinet/in.h>
+ #include <netinet/if_ether.h>
+ #include <arpa/inet.h>
+ #include <sys/sysctl.h>
+-#include <sys/types.h>
++#include <stdio.h>
++#include <string.h>
++#include <stdlib.h>
+ #include "arp.h"
+ 
+ #define ROUNDUP(a) \
+--- a/send_packet_bsd.c
++++ b/send_packet_bsd.c
+@@ -24,6 +24,8 @@ See the GNU General Public License for m
+ #include <fcntl.h>
+ #include <net/bpf.h>
+ #include <net/if.h>
++#include <string.h>
++#include <stdio.h>
+ #include "arp.h"
+ 
+ int send_packet_bsd(const char *dev, u_char *packet, u_int packetsize)
diff --git a/debian/patches/series b/debian/patches/series
index 7ba7a93..4f2db20 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
 20skip_send_packet_test.patch
+bsd-missing-includes.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libnet-arp-perl.git



More information about the Pkg-perl-cvs-commits mailing list