1 |
commit: cd138d3f292983c6b2edac56b139bdb98009e3af |
2 |
Author: Jeroen Roovers <jer <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jan 31 22:24:40 2020 +0000 |
4 |
Commit: Jeroen Roovers <jer <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jan 31 22:25:05 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cd138d3f |
7 |
|
8 |
net-analyzer/netwatch: Fix CFLAGS=-fno-common |
9 |
|
10 |
Package-Manager: Portage-2.3.86, Repoman-2.3.20 |
11 |
Closes: https://bugs.gentoo.org/show_bug.cgi?id=707410 |
12 |
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org> |
13 |
|
14 |
.../files/netwatch-1.3.0.1-fno-common.patch | 44 +++++++++++++++++++ |
15 |
net-analyzer/netwatch/netwatch-1.3.0.1-r4.ebuild | 50 ++++++++++++++++++++++ |
16 |
2 files changed, 94 insertions(+) |
17 |
|
18 |
diff --git a/net-analyzer/netwatch/files/netwatch-1.3.0.1-fno-common.patch b/net-analyzer/netwatch/files/netwatch-1.3.0.1-fno-common.patch |
19 |
new file mode 100644 |
20 |
index 00000000000..02331e7deea |
21 |
--- /dev/null |
22 |
+++ b/net-analyzer/netwatch/files/netwatch-1.3.0.1-fno-common.patch |
23 |
@@ -0,0 +1,44 @@ |
24 |
+--- a/dispdata.c |
25 |
++++ b/dispdata.c |
26 |
+@@ -173,7 +173,6 @@ |
27 |
+ extern int simchange; |
28 |
+ extern int simfwdir; |
29 |
+ extern int simarr[8]; |
30 |
+-char *simfmt; |
31 |
+ extern int iseth; |
32 |
+ extern int nw_logall; |
33 |
+ extern char nw_allname[256]; |
34 |
+--- a/netwatch.c |
35 |
++++ b/netwatch.c |
36 |
+@@ -161,6 +161,9 @@ |
37 |
+ char mylog[MAXFILENAME] = "/root/.log"; |
38 |
+ char specconfigfile[MAXFILENAME] = "/root/.netwatch.conf"; |
39 |
+ |
40 |
++struct port_info *tcp_port_types[TCPHASH]; |
41 |
++struct port_info *udp_port_types[UDPHASH]; |
42 |
++ |
43 |
+ int fdlog; |
44 |
+ |
45 |
+ #if defined(_LINUX_IF_ETHER_H) || defined(_NETINET_IF_ETHER_H) |
46 |
+--- a/netwatch.h |
47 |
++++ b/netwatch.h |
48 |
+@@ -209,16 +209,17 @@ |
49 |
+ }; |
50 |
+ |
51 |
+ #define TCPHASH 1786 |
52 |
+-struct port_info *tcp_port_types[TCPHASH]; |
53 |
++extern struct port_info *tcp_port_types[TCPHASH]; |
54 |
+ |
55 |
+ #define UDPHASH 1786 |
56 |
+-struct port_info *udp_port_types[UDPHASH]; |
57 |
++extern struct port_info *udp_port_types[UDPHASH]; |
58 |
+ |
59 |
+ int hashport( int port, int hash); |
60 |
+ void initlist(struct port_info *first[], int hash); |
61 |
+ char *searchlist(struct port_info *first[], int port, int hash); |
62 |
+ char *servicenm( char *s, int port); |
63 |
+ |
64 |
++extern char *simfmt; |
65 |
+ |
66 |
+ |
67 |
+ struct hostinfo { |
68 |
|
69 |
diff --git a/net-analyzer/netwatch/netwatch-1.3.0.1-r4.ebuild b/net-analyzer/netwatch/netwatch-1.3.0.1-r4.ebuild |
70 |
new file mode 100644 |
71 |
index 00000000000..df6024cd653 |
72 |
--- /dev/null |
73 |
+++ b/net-analyzer/netwatch/netwatch-1.3.0.1-r4.ebuild |
74 |
@@ -0,0 +1,50 @@ |
75 |
+# Copyright 1999-2020 Gentoo Authors |
76 |
+# Distributed under the terms of the GNU General Public License v2 |
77 |
+ |
78 |
+EAPI=7 |
79 |
+inherit autotools |
80 |
+ |
81 |
+MY_PV=$(ver_cut 1-3)-$(ver_cut 4) |
82 |
+ |
83 |
+DESCRIPTION="Ethernet/PPP IP Packet Monitor" |
84 |
+HOMEPAGE="http://www.slctech.org/~mackay/netwatch.html" |
85 |
+SRC_URI="http://www.slctech.org/~mackay/NETWATCH/${PN}-${MY_PV}.tgz" |
86 |
+ |
87 |
+LICENSE="GPL-2" |
88 |
+SLOT="0" |
89 |
+KEYWORDS="~amd64 ~x86" |
90 |
+IUSE="doc" |
91 |
+ |
92 |
+RDEPEND="sys-libs/ncurses" |
93 |
+DEPEND=" |
94 |
+ ${RDEPEND} |
95 |
+ sys-kernel/linux-headers |
96 |
+ virtual/pkgconfig |
97 |
+" |
98 |
+PATCHES=( |
99 |
+ "${FILESDIR}"/${P}-append_ldflags.patch |
100 |
+ "${FILESDIR}"/${P}-open.patch |
101 |
+ "${FILESDIR}"/${P}-fix-fortify.patch |
102 |
+ "${FILESDIR}"/${P}-do-not-call.patch |
103 |
+ "${FILESDIR}"/${P}-includes.patch |
104 |
+ "${FILESDIR}"/${P}-tinfo.patch |
105 |
+ "${FILESDIR}"/${P}-fno-common.patch |
106 |
+) |
107 |
+S=${WORKDIR}/${PN}-$(ver_cut 1-3) |
108 |
+ |
109 |
+src_prepare() { |
110 |
+ default |
111 |
+ eautoreconf |
112 |
+} |
113 |
+ |
114 |
+src_install() { |
115 |
+ dosbin netresolv netwatch |
116 |
+ |
117 |
+ doman netwatch.1 |
118 |
+ dodoc BUGS CHANGES README* TODO |
119 |
+ |
120 |
+ if use doc; then |
121 |
+ docinto html |
122 |
+ dodoc NetwatchKeyCommands.html |
123 |
+ fi |
124 |
+} |