1 |
commit: 3f98aec59be6928f3b01c157fb7b60656162e815 |
2 |
Author: Peter Levine <plevine457 <AT> gmail <DOT> com> |
3 |
AuthorDate: Sun May 28 03:06:55 2017 +0000 |
4 |
Commit: David Seifert <soap <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jul 30 09:41:52 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3f98aec5 |
7 |
|
8 |
net-analyzer/sancp: Fix building with GCC-6 |
9 |
|
10 |
Bug: https://bugs.gentoo.org/show_bug.cgi?id=594728 |
11 |
Package-Manager: Portage-2.3.6, Repoman-2.3.2 |
12 |
Closes: https://github.com/gentoo/gentoo/pull/4784 |
13 |
|
14 |
net-analyzer/sancp/files/sancp-1.6.1-gcc6.patch | 26 +++++++++++++++++++++++++ |
15 |
net-analyzer/sancp/sancp-1.6.1-r4.ebuild | 1 + |
16 |
2 files changed, 27 insertions(+) |
17 |
|
18 |
diff --git a/net-analyzer/sancp/files/sancp-1.6.1-gcc6.patch b/net-analyzer/sancp/files/sancp-1.6.1-gcc6.patch |
19 |
new file mode 100644 |
20 |
index 00000000000..e56d7114468 |
21 |
--- /dev/null |
22 |
+++ b/net-analyzer/sancp/files/sancp-1.6.1-gcc6.patch |
23 |
@@ -0,0 +1,26 @@ |
24 |
+--- a/pcapFileHandle.h |
25 |
++++ b/pcapFileHandle.h |
26 |
+@@ -16,7 +16,12 @@ |
27 |
+ |
28 |
+ #define PCAP_HEADER_SIZE 24 |
29 |
+ |
30 |
+-const char pcap_header[] = { 0xd4,0xc3,0xb2,0xa1,0x02,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x4e,0x00,0x00,0x01,0x00,0x00,0x00 }; |
31 |
++const char pcap_header[] = { |
32 |
++ (char) 0xd4,(char) 0xc3,(char) 0xb2,(char) 0xa1,(char) 0x02,(char) 0x00, |
33 |
++ (char) 0x04,(char) 0x00,(char) 0x00,(char) 0x00,(char) 0x00,(char) 0x00, |
34 |
++ (char) 0x00,(char) 0x00,(char) 0x00,(char) 0x00,(char) 0x20,(char) 0x4e, |
35 |
++ (char) 0x00,(char) 0x00,(char) 0x01,(char) 0x00,(char) 0x00,(char) 0x00 |
36 |
++}; |
37 |
+ |
38 |
+ class pcapFileHandle : public fileHandle { |
39 |
+ |
40 |
+--- a/sancp.h |
41 |
++++ b/sancp.h |
42 |
+@@ -223,7 +223,6 @@ |
43 |
+ #define R_URG 0x20 |
44 |
+ #define R_RES2 0x40 |
45 |
+ #define R_RES1 0x80 |
46 |
+-#define max(i,j) (((i)>(j)) ? (i) : (j)) |
47 |
+ #define SIZE_OF_CLASS_C 11 |
48 |
+ |
49 |
+ struct t_ports { |
50 |
|
51 |
diff --git a/net-analyzer/sancp/sancp-1.6.1-r4.ebuild b/net-analyzer/sancp/sancp-1.6.1-r4.ebuild |
52 |
index aa665e1ec71..4f1bfd0b4e9 100644 |
53 |
--- a/net-analyzer/sancp/sancp-1.6.1-r4.ebuild |
54 |
+++ b/net-analyzer/sancp/sancp-1.6.1-r4.ebuild |
55 |
@@ -37,6 +37,7 @@ src_prepare() { |
56 |
epatch "${DISTDIR}"/${PN}-1.6.1.fix200601.c.patch |
57 |
epatch "${DISTDIR}"/${PN}-1.6.1.fix200606.d.patch |
58 |
epatch "${FILESDIR}"/${P}-compiler.patch |
59 |
+ epatch "${FILESDIR}"/${P}-gcc6.patch |
60 |
|
61 |
tc-export CXX CC |
62 |
} |