summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Popov <pinkbyte@gentoo.org>2012-09-25 18:30:48 +0000
committerSergey Popov <pinkbyte@gentoo.org>2012-09-25 18:30:48 +0000
commit8c39b4ebff908f2d89014bcfca9c51284df6daca (patch)
tree414d7bba9c52cde304e8e6c8ff27323e4b6b376a /net-analyzer/nsat
parentDon't use $opts in init.d / conf.d, bug 436066 (diff)
downloadgentoo-2-8c39b4ebff908f2d89014bcfca9c51284df6daca.tar.gz
gentoo-2-8c39b4ebff908f2d89014bcfca9c51284df6daca.tar.bz2
gentoo-2-8c39b4ebff908f2d89014bcfca9c51284df6daca.zip
New revision with amd64 keyword and compatibility patch for it, wrt bug #389767. Thanks to Andrew Savchenko for provided patch
(Portage version: 2.2.0_alpha132/cvs/Linux x86_64)
Diffstat (limited to 'net-analyzer/nsat')
-rw-r--r--net-analyzer/nsat/ChangeLog11
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch33
-rw-r--r--net-analyzer/nsat/nsat-1.5-r1.ebuild66
3 files changed, 108 insertions, 2 deletions
diff --git a/net-analyzer/nsat/ChangeLog b/net-analyzer/nsat/ChangeLog
index af666776a9f5..a8a6ed7eaca0 100644
--- a/net-analyzer/nsat/ChangeLog
+++ b/net-analyzer/nsat/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-analyzer/nsat
-# Copyright 2002-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nsat/ChangeLog,v 1.17 2009/01/15 07:08:09 jer Exp $
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nsat/ChangeLog,v 1.18 2012/09/25 18:30:48 pinkbyte Exp $
+
+*nsat-1.5-r1 (25 Sep 2012)
+
+ 25 Sep 2012; Sergey Popov <pinkbyte@gentoo.org> +nsat-1.5-r1.ebuild,
+ +files/nsat-1.5-amd64-compat.patch:
+ New revision with amd64 keyword and compatibility patch for it, wrt bug
+ #389767. Thanks to Andrew Savchenko for provided patch
15 Jan 2009; Jeroen Roovers <jer@gentoo.org> nsat-1.5.ebuild:
Oops. Use eautoreconf, not eautoconf (bug #226585 again).
diff --git a/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch b/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch
new file mode 100644
index 000000000000..0fbb2ace4344
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch
@@ -0,0 +1,33 @@
+--- nsat/src/mod/xp_icmp_echo.c.orig 2002-02-07 20:14:20.000000000 +0300
++++ nsat/src/mod/xp_icmp_echo.c 2011-11-07 00:57:48.885372644 +0400
+@@ -90,7 +90,7 @@
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+
+- recv_pack = read_icmp(&res, ICMP_ECHOREPLY, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_ECHOREPLY, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
+--- nsat/src/mod/xp_icmp_infr.c.orig 2002-02-07 20:14:20.000000000 +0300
++++ nsat/src/mod/xp_icmp_infr.c 2011-11-07 01:09:43.192287799 +0400
+@@ -83,7 +83,7 @@
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+
+- recv_pack = read_icmp(&res, ICMP_IREQREPLY, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_IREQREPLY, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
+--- nsat/src/mod/xp_udp_probe.c.orig 2011-11-07 01:05:26.000000000 +0400
++++ nsat/src/mod/xp_udp_probe.c 2011-11-07 01:05:48.403407231 +0400
+@@ -92,7 +92,7 @@
+ #ifdef EBUG
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+- recv_pack = read_icmp(&res, ICMP_UNREACH, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_UNREACH, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
diff --git a/net-analyzer/nsat/nsat-1.5-r1.ebuild b/net-analyzer/nsat/nsat-1.5-r1.ebuild
new file mode 100644
index 000000000000..d8b50c8e0553
--- /dev/null
+++ b/net-analyzer/nsat/nsat-1.5-r1.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/nsat/nsat-1.5-r1.ebuild,v 1.1 2012/09/25 18:30:48 pinkbyte Exp $
+
+inherit eutils autotools
+
+WANT_AUTOCONF=2.5
+
+DESCRIPTION="Network Security Analysis Tool, an application-level network security scanner"
+HOMEPAGE="http://nsat.sourceforge.net/"
+SRC_URI="mirror://sourceforge/nsat/${P}.tgz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE="X"
+
+RDEPEND="X? ( x11-libs/libX11
+ dev-lang/tk )
+ net-libs/libpcap"
+
+DEPEND="$RDEPEND >=sys-devel/autoconf-2.58"
+
+S="${WORKDIR}/${PN}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ cp -va configure.in{,.orig}
+ epatch "${FILESDIR}"/${P}-configure.patch
+ # bug 128204
+ epatch "${FILESDIR}"/${P}-lvalue-gcc4.patch
+ epatch "${FILESDIR}"/${P}-strip.patch
+ # bug 389767
+ epatch "${FILESDIR}"/${P}-amd64-compat.patch
+
+ sed -i "s:^#CGIFile /usr/local/share/nsat/nsat.cgi$:#CGIFile /usr/share/nsat/nsat.cgi:g" \
+ nsat.conf
+ sed -i "s:/usr/local:/usr:g" Makefile.in
+ sed -i "s:/usr/local:/usr:g" tools/xnsat
+ sed -i -e "s:/usr/local/share/nsat/nsat.conf:/etc/nsat/nsat.conf:g" \
+ -e "s:/usr/local/share/nsat/nsat.cgi:/usr/share/nsat/nsat.cgi:g" \
+ src/lang.h
+
+ eautoreconf
+}
+
+src_compile() {
+ econf $( use_with X x ) || die
+
+ make|| die "compile problem"
+}
+
+src_install () {
+ dobin nsat smb-ns
+ use X && dobin tools/xnsat
+
+ insinto /usr/share/nsat
+ doins nsat.cgi
+
+ insinto /etc/nsat
+ doins nsat.conf
+
+ dodoc README doc/CHANGES
+ doman doc/nsat.8
+}