public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/rain/files/, net-analyzer/rain/
@ 2020-01-31 14:09 Jeroen Roovers
  0 siblings, 0 replies; only message in thread
From: Jeroen Roovers @ 2020-01-31 14:09 UTC (permalink / raw
  To: gentoo-commits

commit:     71d53b4138dec0178ad8838b3e89f2ceaf9cba08
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 31 14:08:22 2020 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Fri Jan 31 14:09:07 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=71d53b41

net-analyzer/rain: Fix CFLAGS=-fno-common

Package-Manager: Portage-2.3.86, Repoman-2.3.20
Closes: https://bugs.gentoo.org/show_bug.cgi?id=706874
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 .../rain/files/rain-1.2.9_beta1-die-on-error.patch |  40 ++++++++
 .../rain/files/rain-1.2.9_beta1-fno-common.patch   | 111 +++++++++++++++++++++
 net-analyzer/rain/rain-1.2.9_beta1-r1.ebuild       |  37 +++++++
 3 files changed, 188 insertions(+)

diff --git a/net-analyzer/rain/files/rain-1.2.9_beta1-die-on-error.patch b/net-analyzer/rain/files/rain-1.2.9_beta1-die-on-error.patch
new file mode 100644
index 00000000000..ac73a0f5390
--- /dev/null
+++ b/net-analyzer/rain/files/rain-1.2.9_beta1-die-on-error.patch
@@ -0,0 +1,40 @@
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -15,22 +15,22 @@
+ 
+ all:
+ 	@echo Making all
+-	-$(CC) $(CFLAGS) -c source/rain_command_line.c
+-	-$(CC) $(CFLAGS) -c source/rain_defaults.c
+-	-$(CC) $(CFLAGS) -c source/rain_die.c
+-	-$(CC) $(CFLAGS) -c source/rain_icmp.c
+-	-$(CC) $(CFLAGS) -c source/rain_igmp.c
+-	-$(CC) $(CFLAGS) -c source/rain_inet_common.c
+-	-$(CC) $(CFLAGS) -c source/rain_mem.c
+-	-$(CC) $(CFLAGS) -c source/rain_resolv.c
+-	-$(CC) $(CFLAGS) -c source/rain_services.c
+-	-$(CC) $(CFLAGS) -c source/rain_signal.c
+-	-$(CC) $(CFLAGS) -c source/rain_string.c
+-	-$(CC) $(CFLAGS) -c source/rain_tcp.c
+-	-$(CC) $(CFLAGS) -c source/rain_udp.c
+-	-$(CC) $(CFLAGS) -c source/rain_main.c
++	$(CC) $(CFLAGS) -c source/rain_command_line.c
++	$(CC) $(CFLAGS) -c source/rain_defaults.c
++	$(CC) $(CFLAGS) -c source/rain_die.c
++	$(CC) $(CFLAGS) -c source/rain_icmp.c
++	$(CC) $(CFLAGS) -c source/rain_igmp.c
++	$(CC) $(CFLAGS) -c source/rain_inet_common.c
++	$(CC) $(CFLAGS) -c source/rain_mem.c
++	$(CC) $(CFLAGS) -c source/rain_resolv.c
++	$(CC) $(CFLAGS) -c source/rain_services.c
++	$(CC) $(CFLAGS) -c source/rain_signal.c
++	$(CC) $(CFLAGS) -c source/rain_string.c
++	$(CC) $(CFLAGS) -c source/rain_tcp.c
++	$(CC) $(CFLAGS) -c source/rain_udp.c
++	$(CC) $(CFLAGS) -c source/rain_main.c
+ 
+-	-$(CC) $(CFLAGS) $(LDFLAGS) -o rain rain_command_line.o rain_defaults.o rain_die.o rain_icmp.o rain_igmp.o rain_inet_common.o rain_main.o rain_mem.o rain_resolv.o rain_services.o rain_signal.o rain_string.o rain_tcp.o rain_udp.o
++	$(CC) $(CFLAGS) $(LDFLAGS) -o rain rain_command_line.o rain_defaults.o rain_die.o rain_icmp.o rain_igmp.o rain_inet_common.o rain_main.o rain_mem.o rain_resolv.o rain_services.o rain_signal.o rain_string.o rain_tcp.o rain_udp.o
+ 
+ 	@echo done.
+ 

diff --git a/net-analyzer/rain/files/rain-1.2.9_beta1-fno-common.patch b/net-analyzer/rain/files/rain-1.2.9_beta1-fno-common.patch
new file mode 100644
index 00000000000..06eb84fc2e7
--- /dev/null
+++ b/net-analyzer/rain/files/rain-1.2.9_beta1-fno-common.patch
@@ -0,0 +1,111 @@
+--- a/include/rain_inet_common.h
++++ b/include/rain_inet_common.h
+@@ -368,14 +368,14 @@
+ /* 
+  * global variables 
+  */
+-u_int16_t packetsize;
+-unsigned char      *buffer;   /* For holding packets. Declared globally to ensure it is freed when the program exits */
+-time_t          send_start;   /* for storing start and finish time of total packets sent */
+-time_t         send_finish;
+-unsigned long packets_sent;
+-u_short            verbose;
+-struct in_addr       group;  /* for ICMP gateway and IGMP group addresses */
+-int              sendflags;  /* stores flags for sendto(); Default is 0 */
++extern u_int16_t packetsize;
++extern unsigned char      *buffer;   /* For holding packets. Declared globally to ensure it is freed when the program exits */
++extern time_t          send_start;   /* for storing start and finish time of total packets sent */
++extern time_t         send_finish;
++extern unsigned long packets_sent;
++extern u_short            verbose;
++extern struct in_addr       group;  /* for ICMP gateway and IGMP group addresses */
++extern int              sendflags;  /* stores flags for sendto(); Default is 0 */
+ /*---------------------------*/
+ 
+ 
+--- a/source/rain_inet_common.c
++++ b/source/rain_inet_common.c
+@@ -17,6 +17,18 @@
+  *-------------------------------------------------*/
+ #include "rain_common.h"
+ 
++/* 
++ * global variables 
++ */
++u_int16_t packetsize;
++unsigned char      *buffer;   /* For holding packets. Declared globally to ensure it is freed when the program exits */
++time_t          send_start;   /* for storing start and finish time of total packets sent */
++time_t         send_finish;
++unsigned long packets_sent;
++u_short            verbose;
++struct in_addr       group;  /* for ICMP gateway and IGMP group addresses */
++int              sendflags;  /* stores flags for sendto(); Default is 0 */
++/*---------------------------*/
+ 
+ /*
+  * Internet checksum routine (RFC 1071) 
+--- a/include/rain_icmp.h
++++ b/include/rain_icmp.h
+@@ -20,7 +20,7 @@
+ 
+ 
+ 
+-unsigned char icmpinfo[56][56][56];
++extern unsigned char icmpinfo[56][56][56];
+ 
+ 
+ /* 
+--- a/source/rain_icmp.c
++++ b/source/rain_icmp.c
+@@ -17,6 +17,7 @@
+  *-------------------------------------------------*/
+ #include "rain_common.h"
+ 
++unsigned char icmpinfo[56][56][56];
+ 
+ /* 
+  * Prints all the ICMP type/code combinations 
+--- a/include/rain_igmp.h
++++ b/include/rain_igmp.h
+@@ -18,7 +18,7 @@
+ #ifndef _RAIN_IGMP_H
+ #define _RAIN_IGMP_H
+ 
+-unsigned char igmpinfo[56][56][5];
++extern unsigned char igmpinfo[56][56][5];
+ 
+ 
+ extern void print_igmp_info(void);
+--- a/source/rain_igmp.c
++++ b/source/rain_igmp.c
+@@ -17,7 +17,7 @@
+  *-------------------------------------------------*/
+ #include "rain_common.h"
+ 
+-	
++unsigned char igmpinfo[56][56][5];
+ 
+ /*
+  * Prints IGMP type/code descriptions
+--- a/include/rain_tcp.h
++++ b/include/rain_tcp.h
+@@ -20,7 +20,7 @@
+ #ifndef _RAIN_TCP_H
+ #define _RAIN_TCP_H
+ 
+-unsigned char tcpinfo[25];
++extern unsigned char tcpinfo[25];
+ 
+ extern void tcp_info_init(struct pkt_info_tcp *);
+ extern int tcp_shower_connect(struct sockaddr_in *, struct pkt_info *);
+--- a/source/rain_tcp.c
++++ b/source/rain_tcp.c
+@@ -17,7 +17,7 @@
+  *-------------------------------------------------*/
+ #include "rain_common.h"
+ 
+-
++unsigned char tcpinfo[25];
+ 
+ /* 
+  * tcp_info_init():

diff --git a/net-analyzer/rain/rain-1.2.9_beta1-r1.ebuild b/net-analyzer/rain/rain-1.2.9_beta1-r1.ebuild
new file mode 100644
index 00000000000..84351e1ba87
--- /dev/null
+++ b/net-analyzer/rain/rain-1.2.9_beta1-r1.ebuild
@@ -0,0 +1,37 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools
+
+MY_P=${P/_/}
+MY_P=${MY_P/-/_}
+DESCRIPTION="powerful tool for testing stability of utilizing IP protocols"
+HOMEPAGE="http://www.mirrors.wiretapped.net/security/packet-construction/rain/"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+SRC_URI="
+	mirror://ubuntu/pool/universe/r/${PN}/${MY_P}.orig.tar.gz
+	mirror://ubuntu/pool/universe/r/${PN}/${MY_P}-1.diff.gz
+"
+
+DOCS=( BUGS CHANGES README TODO )
+S="${WORKDIR}/${MY_P/_/-}"
+PATCHES=(
+	"${WORKDIR}"/${MY_P}-1.diff
+	"${FILESDIR}"/${P}-fno-common.patch
+	"${FILESDIR}"/${P}-gentoo.patch
+	"${FILESDIR}"/${P}-die-on-error.patch
+)
+
+src_prepare() {
+	default
+
+	eautoreconf
+}
+
+src_install() {
+	default
+	gunzip "${ED}"/usr/share/man/man1/${PN}.1.gz || die
+}


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2020-01-31 14:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-01-31 14:09 [gentoo-commits] repo/gentoo:master commit in: net-analyzer/rain/files/, net-analyzer/rain/ Jeroen Roovers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox