commit:     97e2f3f2950f968d0cdea5eb7c310a353e4b62ba
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Tue Sep  1 10:54:27 2020 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Tue Sep  1 10:54:48 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=97e2f3f2

net-libs/libpcapnav: Do not build test programs in src_install

Package-Manager: Portage-3.0.5, Repoman-3.0.1
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 .../files/libpcapnav-0.8-noinst_test.patch         | 22 ++++++++++
 net-libs/libpcapnav/libpcapnav-0.8-r1.ebuild       | 49 ++++++++++++++++++++++
 2 files changed, 71 insertions(+)

diff --git a/net-libs/libpcapnav/files/libpcapnav-0.8-noinst_test.patch 
b/net-libs/libpcapnav/files/libpcapnav-0.8-noinst_test.patch
new file mode 100644
index 00000000000..7bac55b391e
--- /dev/null
+++ b/net-libs/libpcapnav/files/libpcapnav-0.8-noinst_test.patch
@@ -0,0 +1,22 @@
+--- a/test/Makefile.am
++++ b/test/Makefile.am
+@@ -5,7 +5,7 @@
+ 
+ INCLUDES = -I$(top_srcdir)/src
+ 
+-bin_PROGRAMS = pcapnav-test1 pcapnav-offsets \
++check_PROGRAMS = pcapnav-test1 pcapnav-offsets \
+       pcapnav-jump pcapnav-concat pcapnav-filespan
+ 
+ pcapnav_test1_SOURCES = pcapnav-test1.c
+@@ -23,10 +23,6 @@
+ pcapnav_filespan_SOURCES = pcapnav-filespan.c
+ pcapnav_filespan_LDADD = -L$(top_builddir)/src/ -lpcapnav -lpcap @PCN_LIBADD@
+ 
+-# don't install any of this stuff
+-install-binPROGRAMS:
+-uninstall-binPROGRAMS:
+-
+ EXTRA_DIST = \
+       run-tests.sh \
+       test1.trace test1-correct.be.trace test1-correct.le.trace

diff --git a/net-libs/libpcapnav/libpcapnav-0.8-r1.ebuild 
b/net-libs/libpcapnav/libpcapnav-0.8-r1.ebuild
new file mode 100644
index 00000000000..4ac67c9e2d3
--- /dev/null
+++ b/net-libs/libpcapnav/libpcapnav-0.8-r1.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools
+
+DESCRIPTION="Libpcap wrapper library to navigate to arbitrary packets in a 
tcpdump trace file"
+HOMEPAGE="http://netdude.sourceforge.net/";
+SRC_URI="mirror://sourceforge/netdude/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~sparc ~x86"
+IUSE="doc static-libs"
+
+DEPEND="net-libs/libpcap"
+RDEPEND="${DEPEND}"
+RESTRICT="test"
+DOCS=( AUTHORS ChangeLog README )
+PATCHES=(
+       "${FILESDIR}"/${P}-includes.patch
+       "${FILESDIR}"/${P}-noinst_test.patch
+)
+
+src_prepare() {
+       default
+       eautoreconf
+}
+
+src_configure() {
+       econf $(use_enable static-libs static)
+}
+
+jer_src_compile() {
+       emake SUBDIRS="src docs"
+}
+
+src_install() {
+       default
+
+       rm -fr "${D}"/usr/share/gtk-doc
+
+       if use doc; then
+               docinto html
+               dodoc -r docs/*.css docs/html/*.html docs/images
+       fi
+
+       find "${ED}" -name '*.la' -delete || die
+}

Reply via email to