Skip to contentSkip to conversation

tcpdump, tcpreplay:relocate tcpdump and add tcpreplay recipe

PATCH In review [email protected] 3 participants 3 messages Nov 6, 2013 – Nov 7, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tcpdump, tcpreplay:relocate tcpdump and add tcpreplay recipe

From: Zongchun Yu <[email protected]>

*mv tcpdump from meta-oe to meta-networking
*add tcpreplay - a suite of GPLv3 licensed tools for UNIX operating systems which gives you the ability to use previously captured traffic in libpcap format to test a variety of network devices.

---
 .../0001-minimal-IEEE802.15.4-allowed.patch        |   22 +++++
 .../tcpdump/tcpdump-4.3.0/configure.patch          |   29 ++++++
 .../tcpdump/tcpdump-4.3.0/ipv6-cross.patch         |   41 +++++++++
 .../tcpdump-4.3.0/tcpdump_configure_no_-O2.patch   |   42 +++++++++
 .../recipes-support/tcpdump/tcpdump_4.3.0.bb       |   43 +++++++++
 .../files/tcpreplay-3.4.4-cross-compile.patch      |   92 ++++++++++++++++++++
 ...ay-3.4.4-fix-unable-to-link-libpcap-issue.patch |   17 ++++
 .../files/tcpreplay-3.4.4-no-bfp-support.patch     |   15 ++++
 .../recipes-support/tcpreplay/tcpreplay_3.4.4.bb   |   22 +++++
 .../packagegroups/packagegroup-cli-tools.bb        |    1 -
 .../0001-minimal-IEEE802.15.4-allowed.patch        |   22 -----
 .../tcpdump/tcpdump-4.3.0/configure.patch          |   29 ------
 .../tcpdump/tcpdump-4.3.0/ipv6-cross.patch         |   41 ---------
 .../tcpdump-4.3.0/tcpdump_configure_no_-O2.patch   |   42 ---------
 meta-oe/recipes-support/tcpdump/tcpdump_4.3.0.bb   |   43 ---------
 15 files changed, 323 insertions(+), 178 deletions(-)
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/0001-minimal-IEEE802.15.4-allowed.patch
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/configure.patch
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/ipv6-cross.patch
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/tcpdump_configure_no_-O2.patch
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpdump_4.3.0.bb
 create mode 100755 meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-cross-compile.patch
 create mode 100644 meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-fix-unable-to-link-libpcap-issue.patch
 create mode 100644 meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-no-bfp-support.patch
 create mode 100644 meta-networking/recipes-support/tcpreplay/tcpreplay_3.4.4.bb
 delete mode 100644 meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/0001-minimal-IEEE802.15.4-allowed.patch
 delete mode 100644 meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/configure.patch
 delete mode 100644 meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/ipv6-cross.patch
 delete mode 100644 meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/tcpdump_configure_no_-O2.patch
 delete mode 100644 meta-oe/recipes-support/tcpdump/tcpdump_4.3.0.bb
meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/0001-minimal-IEEE802.15.4-allowed.patch new file +22 -0
new file mode 100644
index 0000000..9d3d60d
@@ -0,0 +1,22 @@
+From: Sergey Lapin <[email protected]>
+Date: Wed, 28 Jan 2009 16:34:15 +0300
+Subject: [PATCH] minimal IEEE802.15.4 allowed
+
+---
+ tcpdump.c |    3 +++
+ 1 files changed, 3 insertions(+), 0 deletions(-)
+
+diff --git a/tcpdump.c b/tcpdump.c
+index 06683af..fbc944c 100644
+--- a/tcpdump.c
++++ b/tcpdump.c
+@@ -282,6 +282,9 @@ static struct printer printers[] = {
+ #ifdef DLT_MFR
+ 	{ mfr_if_print,		DLT_MFR },
+ #endif
++#ifdef DLT_IEEE802_15_4
++	{ raw_if_print, DLT_IEEE802_15_4 },
++#endif
+ #if defined(DLT_BLUETOOTH_HCI_H4_WITH_PHDR) && defined(HAVE_PCAP_BLUETOOTH_H)
+ 	{ bt_if_print,		DLT_BLUETOOTH_HCI_H4_WITH_PHDR},
+ #endif
meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/configure.patch new file +29 -0
new file mode 100644
index 0000000..3697420
@@ -0,0 +1,29 @@
+---
+ aclocal.m4   |    1 -
+ configure.in |    1 +
+ 2 files changed, 1 insertions(+), 1 deletions(-)
+
+diff --git a/aclocal.m4 b/aclocal.m4
+index 40b5866..0c662b0 100644
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -40,7 +40,6 @@ dnl
+ AC_DEFUN(AC_LBL_C_INIT_BEFORE_CC,
+     [AC_PREREQ(2.50)
+     AC_BEFORE([$0], [AC_LBL_C_INIT])
+-    AC_BEFORE([$0], [AC_PROG_CC])
+     AC_BEFORE([$0], [AC_LBL_FIXINCLUDES])
+     AC_BEFORE([$0], [AC_LBL_DEVEL])
+     AC_ARG_WITH(gcc, [  --without-gcc           don't use gcc])
+diff --git a/configure.in b/configure.in
+index 11257c9..7f9591c 100644
+--- a/configure.in
++++ b/configure.in
+@@ -19,6 +19,7 @@ AC_REVISION($Revision: 1.204 $)
+ AC_PREREQ(2.50)
+ AC_INIT(tcpdump.c)
+ 
++AC_PROG_CC
+ AC_CANONICAL_HOST
+ 
+ AC_LBL_C_INIT_BEFORE_CC(V_CCOPT, V_INCLS)
meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/ipv6-cross.patch new file +41 -0

41 lines not on this page · raw message

meta-networking/recipes-support/tcpdump/tcpdump-4.3.0/tcpdump_configure_no_-O2.patch new file +42 -0

42 lines not on this page · raw message

meta-networking/recipes-support/tcpdump/tcpdump_4.3.0.bb new file +43 -0

43 lines not on this page · raw message

meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-cross-compile.patch new file +92 -0

92 lines not on this page · raw message

meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-fix-unable-to-link-libpcap-issue.patch new file +17 -0
new file mode 100644
index 0000000..5f36c68
@@ -0,0 +1,17 @@
+Uptream-Status: Pending
+
+Signed-off-by: Zongchun Yu <[email protected]>
+
+Index: tcpreplay-3.4.4/configure.ac
+===================================================================
+--- tcpreplay-3.4.4.orig/configure.ac
++++ tcpreplay-3.4.4/configure.ac
+@@ -389,7 +389,7 @@ CFLAGS="$CFLAGS -I$LPCAPINCDIR"
+ AC_SEARCH_LIBS([pcap_close], [pcap],
+     LPCAPLIB="$LIBS",
+     AC_ERROR([Unable to link libpcap in ${foundpcap}]),
+-    -lnl)
++    -lnl-3)
+ 
+ AC_SUBST(LPCAPINC)
+ AC_SUBST(LPCAPLIB)
meta-networking/recipes-support/tcpreplay/files/tcpreplay-3.4.4-no-bfp-support.patch new file +15 -0
new file mode 100644
index 0000000..3c11c92
@@ -0,0 +1,15 @@
+Uptream-Status: Pending
+
+Signed-off-by: Zongchun Yu <[email protected]>
+
+--- a/configure.ac
++++ b/configure.ac
+@@ -758,6 +758,8 @@
+     AC_MSG_RESULT(no)
+ ])
+ 
++ac_cv_have_bpf=no
++
+ have_bpf=no
+ dnl Check for BSD's BPF
+ AC_CACHE_CHECK([for BPF device sending support], ac_cv_have_bpf,
meta-networking/recipes-support/tcpreplay/tcpreplay_3.4.4.bb new file +22 -0
new file mode 100644
index 0000000..d211888
@@ -0,0 +1,22 @@
+SUMMARY = "Use previously captured traffic to test network devices"
+
+HOMEPAGE = "http://tcpreplay.synfin.net/"
+SECTION = "console/network"
+
+LICENSE = "GPLv3"
+LIC_FILES_CHKSUM = "file://docs/LICENSE;md5=c33cccf72cc1603e8a72a84811ae3ac8"
+
+SRC_URI = "http://prdownloads.sourceforge.net/tcpreplay/${PV}/tcpreplay-${PV}.tar.gz \
+           file://tcpreplay-3.4.4-cross-compile.patch \
+           file://tcpreplay-3.4.4-no-bfp-support.patch \
+           file://tcpreplay-3.4.4-fix-unable-to-link-libpcap-issue.patch \
+           "
+SRC_URI[md5sum] = "22725feb9b2590809f9350308ec65180"
+SRC_URI[sha256sum] = "7a809c58ddec86407fd6e5597ac883d7874a19bea81d716bb2b1c6e3b0e7b58f"
+
+DEPENDS = "libpcap"
+
+EXTRA_OECONF += "--with-libpcap=${STAGING_DIR_HOST}/usr"
+
+inherit siteinfo autotools
+
meta-oe/recipes-core/packagegroups/packagegroup-cli-tools.bb +0 -1
index fa53a67..8807fd1 100644
@@ -45,7 +45,6 @@ RDEPENDS_${PN}-debug = "\
     s3c64xx-gpio \
     serial-forward \
     strace \
-    tcpdump \
 "
 
 RRECOMMENDS_${PN}-debug = "\
meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/0001-minimal-IEEE802.15.4-allowed.patch deleted +0 -22
deleted file mode 100644
index 9d3d60d..0000000
@@ -1,22 +0,0 @@
-From: Sergey Lapin <[email protected]>
-Date: Wed, 28 Jan 2009 16:34:15 +0300
-Subject: [PATCH] minimal IEEE802.15.4 allowed
-
----
- tcpdump.c |    3 +++
- 1 files changed, 3 insertions(+), 0 deletions(-)
-
-diff --git a/tcpdump.c b/tcpdump.c
-index 06683af..fbc944c 100644
---- a/tcpdump.c
-+++ b/tcpdump.c
-@@ -282,6 +282,9 @@ static struct printer printers[] = {
- #ifdef DLT_MFR
- 	{ mfr_if_print,		DLT_MFR },
- #endif
-+#ifdef DLT_IEEE802_15_4
-+	{ raw_if_print, DLT_IEEE802_15_4 },
-+#endif
- #if defined(DLT_BLUETOOTH_HCI_H4_WITH_PHDR) && defined(HAVE_PCAP_BLUETOOTH_H)
- 	{ bt_if_print,		DLT_BLUETOOTH_HCI_H4_WITH_PHDR},
- #endif
meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/configure.patch deleted +0 -29
deleted file mode 100644
index 3697420..0000000
@@ -1,29 +0,0 @@
----
- aclocal.m4   |    1 -
- configure.in |    1 +
- 2 files changed, 1 insertions(+), 1 deletions(-)
-
-diff --git a/aclocal.m4 b/aclocal.m4
-index 40b5866..0c662b0 100644
---- a/aclocal.m4
-+++ b/aclocal.m4
-@@ -40,7 +40,6 @@ dnl
- AC_DEFUN(AC_LBL_C_INIT_BEFORE_CC,
-     [AC_PREREQ(2.50)
-     AC_BEFORE([$0], [AC_LBL_C_INIT])
--    AC_BEFORE([$0], [AC_PROG_CC])
-     AC_BEFORE([$0], [AC_LBL_FIXINCLUDES])
-     AC_BEFORE([$0], [AC_LBL_DEVEL])
-     AC_ARG_WITH(gcc, [  --without-gcc           don't use gcc])
-diff --git a/configure.in b/configure.in
-index 11257c9..7f9591c 100644
---- a/configure.in
-+++ b/configure.in
-@@ -19,6 +19,7 @@ AC_REVISION($Revision: 1.204 $)
- AC_PREREQ(2.50)
- AC_INIT(tcpdump.c)
- 
-+AC_PROG_CC
- AC_CANONICAL_HOST
- 
- AC_LBL_C_INIT_BEFORE_CC(V_CCOPT, V_INCLS)
meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/ipv6-cross.patch deleted +0 -41

41 lines not on this page · raw message

meta-oe/recipes-support/tcpdump/tcpdump-4.3.0/tcpdump_configure_no_-O2.patch deleted +0 -42

42 lines not on this page · raw message

meta-oe/recipes-support/tcpdump/tcpdump_4.3.0.bb deleted +0 -43

43 lines not on this page · raw message

Signature · 1 line
1.7.9.7
#1 lore raw

Please use -M to get smaller diff.

Quoted 8 lines · On Wed, Nov 6, 2013 at 5:40 AM, <[email protected]> wrote:

From: Zongchun Yu <[email protected]>

*mv tcpdump from meta-oe to meta-networking
*add tcpreplay - a suite of GPLv3 licensed tools for UNIX operating systems which gives you the ability to use previously captured traffic in libpcap format to test a variety of network devices.

#2 lore raw
Quoted 1 line

Please use -M to get smaller diff.

Hello Martin.

Thanks for your reminder. I have send one new patch to you and the mail list.

But I don’t know why the patch is rejected by the mail list? It is ok before.

If you have suggestion. Please reply to me directly.

Best Regards

Zongchun