diff options
Diffstat (limited to 'net-wireless/airtraf')
-rw-r--r-- | net-wireless/airtraf/airtraf-1.1-r4.ebuild | 54 | ||||
-rw-r--r-- | net-wireless/airtraf/files/airtraf-1.1-fno-common.patch | 21 |
2 files changed, 75 insertions, 0 deletions
diff --git a/net-wireless/airtraf/airtraf-1.1-r4.ebuild b/net-wireless/airtraf/airtraf-1.1-r4.ebuild new file mode 100644 index 000000000000..c0d5978fdf85 --- /dev/null +++ b/net-wireless/airtraf/airtraf-1.1-r4.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit toolchain-funcs + +DESCRIPTION="AirTraf 802.11b Wireless traffic sniffer" +LICENSE="GPL-2" +HOMEPAGE="http://www.elixar.com/" +SRC_URI="http://www.elixar.com/${P}.tar.gz" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" + +RDEPEND=" + net-libs/libpcap + sys-libs/ncurses:= +" +DEPEND=" + ${RDEPEND} + virtual/pkgconfig +" +PATCHES=( + "${FILESDIR}"/${P}-sniffd.patch + "${FILESDIR}"/${P}-off-by-one.patch + "${FILESDIR}"/${P}-fprintf-format.patch + "${FILESDIR}"/${P}-fno-common.patch +) + +src_prepare() { + default + + sed -i \ + -e '/^LIBS/s|=.*|= $(shell $(PKG_CONFIG) --libs panel)|' \ + src/libncurses/Makefile || die + sed -i \ + -e 's|-lpanel -lncurses|$(shell $(PKG_CONFIG) --libs ncurses panel)|' \ + src/sniffd/Makefile || die + tc-export PKG_CONFIG +} + +src_compile() { + # parallel make (bug #297331) + emake -C src -j1 \ + CC=$(tc-getCC) \ + CXX=$(tc-getCXX) \ + CFLAGS="${CFLAGS}" \ + CXXFLAGS="${CXXFLAGS}" \ + LDFLAGS="${LDFLAGS}" +} + +src_install () { + dobin src/airtraf + dodoc Authors COMPATIBILITY docs/airtraf_doc.html +} diff --git a/net-wireless/airtraf/files/airtraf-1.1-fno-common.patch b/net-wireless/airtraf/files/airtraf-1.1-fno-common.patch new file mode 100644 index 000000000000..9945f170d53d --- /dev/null +++ b/net-wireless/airtraf/files/airtraf-1.1-fno-common.patch @@ -0,0 +1,21 @@ +--- a/src/sniffd/capture_engine.c ++++ b/src/sniffd/capture_engine.c +@@ -52,7 +52,6 @@ + FILE * capture_stream; + FILE * error_stream; + +-char atime[TIME_TARGET_MAX]; + + + //////////////////////////////////////////////////////////////////////// +--- a/src/libcommon/logger.h ++++ b/src/libcommon/logger.h +@@ -33,6 +33,8 @@ + #ifndef __logger_h__ + #define __logger_h__ + ++extern char atime[TIME_TARGET_MAX]; ++ + int init_log(int, char*); + int write_log(int, char*); + void flush_log(int); |