mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-17 02:39:08 -07:00
net-analyzer/labrea: Fix building against libpcap-1.9.0 (bug #661892).
Package-Manager: Portage-2.3.43, Repoman-2.3.10
This commit is contained in:
42
net-analyzer/labrea/files/labrea-2.5-pcap_open.patch
Normal file
42
net-analyzer/labrea/files/labrea-2.5-pcap_open.patch
Normal file
@@ -0,0 +1,42 @@
|
||||
--- a/src/pcaputil.c
|
||||
+++ b/src/pcaputil.c
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "pcaputil.h"
|
||||
|
||||
pcap_t *
|
||||
-pcap_open(char *device)
|
||||
+labrea_pcap_open(char *device)
|
||||
{
|
||||
char ebuf[PCAP_ERRBUF_SIZE];
|
||||
pcap_t *pcap;
|
||||
--- a/src/lbio.c
|
||||
+++ b/src/lbio.c
|
||||
@@ -190,7 +190,7 @@
|
||||
/*
|
||||
* Open the WinPcap device for sniffing
|
||||
*/
|
||||
- if ((io.pcap = pcap_open(io.adapter_name_list[j])) == NULL) {
|
||||
+ if ((io.pcap = labrea_pcap_open(io.adapter_name_list[j])) == NULL) {
|
||||
warnx("*** Couldn't open WinPcap adapter" );
|
||||
return(-1);
|
||||
}
|
||||
@@ -286,7 +286,7 @@
|
||||
util_clean_exit(1);
|
||||
|
||||
} else { /* open Unix pcap device for sniffing */
|
||||
- if ((io.pcap = pcap_open(io.ifent->intf_name)) == NULL) {
|
||||
+ if ((io.pcap = labrea_pcap_open(io.ifent->intf_name)) == NULL) {
|
||||
warnx("*** Couldn't open pcap device for sniffing" );
|
||||
util_clean_exit(1);
|
||||
}
|
||||
--- a/inc/pcaputil.h
|
||||
+++ b/inc/pcaputil.h
|
||||
@@ -15,7 +15,7 @@
|
||||
#endif
|
||||
|
||||
|
||||
-pcap_t * pcap_open(char *device);
|
||||
+pcap_t * labrea_pcap_open(char *device);
|
||||
int pcap_dloff(pcap_t *pcap);
|
||||
int pcap_filter(pcap_t *pcap, const char *fmt, ...);
|
||||
void pcap_stat (pcap_t *pd);
|
||||
45
net-analyzer/labrea/labrea-2.5-r3.ebuild
Normal file
45
net-analyzer/labrea/labrea-2.5-r3.ebuild
Normal file
@@ -0,0 +1,45 @@
|
||||
# Copyright 1999-2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
inherit autotools
|
||||
|
||||
DESCRIPTION="'Sticky' Honeypot and IDS"
|
||||
HOMEPAGE="http://labrea.sourceforge.net/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}-stable-1.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~x86"
|
||||
|
||||
DEPEND="
|
||||
net-libs/libpcap
|
||||
>=dev-libs/libdnet-1.7
|
||||
"
|
||||
RDEPEND="
|
||||
${DEPEND}
|
||||
"
|
||||
|
||||
MY_P="${P}-stable-1"
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
DOCS=( AUTHORS ChangeLog README TODO NEWS )
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${P}-stable-1-incdir.patch
|
||||
"${FILESDIR}"/${P}-pcap_open.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
newdoc INSTALL README.first
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
ewarn "Before using this package READ the INSTALL and README"
|
||||
ewarn "as the author states that it can cause serious problems on your network"
|
||||
}
|
||||
Reference in New Issue
Block a user