All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-networking][PATCH 1/2] tcpdump: upgrade 4.99.0 -> 4.99.1
@ 2022-01-30 14:39 Yi Zhao
  2022-01-30 14:39 ` [meta-networking][PATCH 2/2] tcpslice: upgrade 1.2a3 -> 1.5 Yi Zhao
  0 siblings, 1 reply; 2+ messages in thread
From: Yi Zhao @ 2022-01-30 14:39 UTC (permalink / raw)
  To: openembedded-devel

* Skip aclocal in do_configure
* Inherit pkgconfig then we can drop
  0001-aclocal.m4-Skip-checking-for-pcap-config.patch

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 ...cal.m4-Skip-checking-for-pcap-config.patch | 33 -------------------
 .../{tcpdump_4.99.0.bb => tcpdump_4.99.1.bb}  | 18 +++-------
 2 files changed, 5 insertions(+), 46 deletions(-)
 delete mode 100644 meta-networking/recipes-support/tcpdump/tcpdump/0001-aclocal.m4-Skip-checking-for-pcap-config.patch
 rename meta-networking/recipes-support/tcpdump/{tcpdump_4.99.0.bb => tcpdump_4.99.1.bb} (72%)

diff --git a/meta-networking/recipes-support/tcpdump/tcpdump/0001-aclocal.m4-Skip-checking-for-pcap-config.patch b/meta-networking/recipes-support/tcpdump/tcpdump/0001-aclocal.m4-Skip-checking-for-pcap-config.patch
deleted file mode 100644
index bb56c4d4c..000000000
--- a/meta-networking/recipes-support/tcpdump/tcpdump/0001-aclocal.m4-Skip-checking-for-pcap-config.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 867bf5c9d0fb64e1b4e64cb13b983674c270a6bf Mon Sep 17 00:00:00 2001
-From: Yi Fan Yu <yifan.yu@windriver.com>
-Date: Fri, 19 Feb 2021 00:52:35 -0500
-Subject: [PATCH] aclocal.m4: Skip checking for pcap-config
-
-Bitbake triggers an configure error
-saying we should look for pkg-config instead.
-
-Upstream-Status: Inappropriate [OE-Specific]
-
-Signed-off-by: Yi Fan Yu <yifan.yu@windriver.com>
----
- aclocal.m4 | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/aclocal.m4 b/aclocal.m4
-index bd4e27a5..136cb8ca 100644
---- a/aclocal.m4
-+++ b/aclocal.m4
-@@ -584,8 +584,8 @@ AC_DEFUN(AC_LBL_LIBPCAP,
-             # No pkg-config
-             # Look for an installed pcap-config.
-             #
--            AC_PATH_TOOL(PCAP_CONFIG, pcap-config)
--            if test -n "$PCAP_CONFIG" ; then
-+            # AC_PATH_TOOL(PCAP_CONFIG, pcap-config)
-+            if false; then
-                 #
-                 # Found - use it to get the include flags for
-                 # libpcap and the flags to link with libpcap.
--- 
-2.29.2
-
diff --git a/meta-networking/recipes-support/tcpdump/tcpdump_4.99.0.bb b/meta-networking/recipes-support/tcpdump/tcpdump_4.99.1.bb
similarity index 72%
rename from meta-networking/recipes-support/tcpdump/tcpdump_4.99.0.bb
rename to meta-networking/recipes-support/tcpdump/tcpdump_4.99.1.bb
index 97a9027af..322a826f0 100644
--- a/meta-networking/recipes-support/tcpdump/tcpdump_4.99.0.bb
+++ b/meta-networking/recipes-support/tcpdump/tcpdump_4.99.1.bb
@@ -24,15 +24,14 @@ SRC_URI = " \
     http://www.tcpdump.org/release/${BP}.tar.gz \
     file://add-ptest.patch \
     file://run-ptest \
-    file://0001-aclocal.m4-Skip-checking-for-pcap-config.patch \
 "
 
-SRC_URI[md5sum] = "b10aa2f497def7283bc060f626879ce5"
-SRC_URI[sha256sum] = "8cf2f17a9528774a7b41060323be8b73f76024f7778f59c34efa65d49d80b842"
+SRC_URI[md5sum] = "929a255c71a9933608bd7c31927760f7"
+SRC_URI[sha256sum] = "79b36985fb2703146618d87c4acde3e068b91c553fb93f021a337f175fd10ebe"
 
-UPSTREAM_CHECK_REGEX = "tcpdump-(?P<pver>\d+(\.(?!99)\d+)+)\.tar"
+UPSTREAM_CHECK_REGEX = "tcpdump-(?P<pver>\d+(\.\d+)+)\.tar"
 
-inherit autotools-brokensep ptest
+inherit autotools-brokensep pkgconfig ptest
 
 PACKAGECONFIG ?= "openssl"
 
@@ -42,14 +41,7 @@ PACKAGECONFIG[smi] = "--with-smi,--without-smi,libsmi"
 # Note: CVE-2018-10103 (SMB - partially fixed, but SMB printing disabled)
 PACKAGECONFIG[smb] = "--enable-smb,--disable-smb"
 
-EXTRA_AUTORECONF += "-I m4"
-
-do_configure:prepend() {
-    mkdir -p ${S}/m4
-    if [ -f aclocal.m4 ]; then
-        mv aclocal.m4 ${S}/m4
-    fi
-}
+EXTRA_AUTORECONF += "--exclude=aclocal"
 
 do_install:append() {
     # make install installs an unneeded extra copy of the tcpdump binary
-- 
2.25.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [meta-networking][PATCH 2/2] tcpslice: upgrade 1.2a3 -> 1.5
  2022-01-30 14:39 [meta-networking][PATCH 1/2] tcpdump: upgrade 4.99.0 -> 4.99.1 Yi Zhao
@ 2022-01-30 14:39 ` Yi Zhao
  0 siblings, 0 replies; 2+ messages in thread
From: Yi Zhao @ 2022-01-30 14:39 UTC (permalink / raw)
  To: openembedded-devel

* Update SRC_URI to official download page
* Drop patches which had been fixed upstream.
* Add UPSTREAM_CHECK_REGEX

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 .../tcpslice/tcpslice-1.2a3-time.patch        | 75 -------------------
 .../tcpslice/tcpslice-CVS.20010207-bpf.patch  | 15 ----
 .../recipes-support/tcpdump/tcpslice_1.2a3.bb | 36 ---------
 .../recipes-support/tcpdump/tcpslice_1.5.bb   | 25 +++++++
 4 files changed, 25 insertions(+), 126 deletions(-)
 delete mode 100644 meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-1.2a3-time.patch
 delete mode 100644 meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-CVS.20010207-bpf.patch
 delete mode 100644 meta-networking/recipes-support/tcpdump/tcpslice_1.2a3.bb
 create mode 100644 meta-networking/recipes-support/tcpdump/tcpslice_1.5.bb

diff --git a/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-1.2a3-time.patch b/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-1.2a3-time.patch
deleted file mode 100644
index 386b7f83a..000000000
--- a/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-1.2a3-time.patch
+++ /dev/null
@@ -1,75 +0,0 @@
-Upstream-Status: Pending [from tcpdump-4.1.1-1.fc14.src.rpm]
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
-
---- tcpslice-1.2a3.orig/search.c	2000-09-10 10:52:40.000000000 +0200
-+++ tcpslice-1.2a3/search.c	2006-07-28 14:56:55.000000000 +0200
-@@ -53,7 +53,7 @@
- /* Size of a packet header in bytes; easier than typing the sizeof() all
-  * the time ...
-  */
--#define PACKET_HDR_LEN (sizeof( struct pcap_pkthdr ))
-+#define PACKET_HDR_LEN (sizeof( struct pcap_sf_pkthdr ))
- 
- extern int snaplen;
- 
-@@ -111,16 +111,24 @@
- static void
- extract_header( pcap_t *p, u_char *buf, struct pcap_pkthdr *hdr )
- 	{
--	memcpy((char *) hdr, (char *) buf, sizeof(struct pcap_pkthdr));
-+	struct pcap_sf_pkthdr hdri;
-+
-+	memcpy((char *) &hdri, (char *) buf, sizeof(struct pcap_sf_pkthdr));
- 
- 	if ( pcap_is_swapped( p ) )
- 		{
--		hdr->ts.tv_sec = SWAPLONG(hdr->ts.tv_sec);
--		hdr->ts.tv_usec = SWAPLONG(hdr->ts.tv_usec);
--		hdr->len = SWAPLONG(hdr->len);
--		hdr->caplen = SWAPLONG(hdr->caplen);
-+		hdr->ts.tv_sec = SWAPLONG(hdri.ts.tv_sec);
-+		hdr->ts.tv_usec = SWAPLONG(hdri.ts.tv_usec);
-+		hdr->len = SWAPLONG(hdri.len);
-+		hdr->caplen = SWAPLONG(hdri.caplen);
-+		}
-+	else
-+		{
-+		hdr->ts.tv_sec = hdri.ts.tv_sec;
-+		hdr->ts.tv_usec = hdri.ts.tv_usec;
-+		hdr->len = hdri.len;
-+		hdr->caplen = hdri.caplen;
- 		}
--
- 	/*
- 	 * From bpf/libpcap/savefile.c:
- 	 *
---- tcpslice-1.2a3.orig/tcpslice.h	1995-11-02 00:40:53.000000000 +0100
-+++ tcpslice-1.2a3/tcpslice.h	2006-07-28 14:56:55.000000000 +0200
-@@ -20,6 +20,26 @@
-  */
- 
- 
-+#include <time.h>
-+/* #include <net/bpf.h> */
-+
-+/*
-+ * This is a timeval as stored in disk in a dumpfile.
-+ * It has to use the same types everywhere, independent of the actual
-+ * `struct timeval'
-+ */
-+
-+struct pcap_timeval {
-+    bpf_int32 tv_sec;           /* seconds */
-+    bpf_int32 tv_usec;          /* microseconds */
-+};
-+
-+struct pcap_sf_pkthdr {
-+    struct pcap_timeval ts;     /* time stamp */
-+    bpf_u_int32 caplen;         /* length of portion present */
-+    bpf_u_int32 len;            /* length this packet (off wire) */
-+};
-+
- time_t	gwtm2secs( struct tm *tm );
- 
- int	sf_find_end( struct pcap *p, struct timeval *first_timestamp,
diff --git a/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-CVS.20010207-bpf.patch b/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-CVS.20010207-bpf.patch
deleted file mode 100644
index 0a7359311..000000000
--- a/meta-networking/recipes-support/tcpdump/tcpslice/tcpslice-CVS.20010207-bpf.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Pending [from tcpdump-4.1.1-1.fc14.src.rpm]
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
-diff -ur tcpdump-3.8.1/tcpslice/tcpslice.c tcpdump-3.8.1.new/tcpslice/tcpslice.c
---- tcpslice/tcpslice.c	2004-01-15 17:35:53.000000000 +0100
-+++ tcpslice/tcpslice.c	2004-01-15 16:12:57.000000000 +0100
-@@ -35,7 +35,7 @@
- #include <sys/file.h>
- #include <sys/stat.h>
- 
--#include <net/bpf.h>
-+/* #include <net/bpf.h> */
- 
- #include <ctype.h>
- #ifdef HAVE_FCNTL_H
diff --git a/meta-networking/recipes-support/tcpdump/tcpslice_1.2a3.bb b/meta-networking/recipes-support/tcpdump/tcpslice_1.2a3.bb
deleted file mode 100644
index e65739a5c..000000000
--- a/meta-networking/recipes-support/tcpdump/tcpslice_1.2a3.bb
+++ /dev/null
@@ -1,36 +0,0 @@
-SUMMARY = "tcpslice"
-DESCRIPTION = "A tool for extracting parts of a tcpdump packet trace."
-HOMEPAGE = "http://www.tcpdump.org/related.html"
-SECTION = "net"
-
-LICENSE = "BSD-4-Clause"
-LIC_FILES_CHKSUM = "file://tcpslice.c;endline=20;md5=99519e2e5234d1662a4ce16baa62c64e"
-
-SRC_URI = "ftp://ftp.ee.lbl.gov/${BP}.tar.gz \
-           file://tcpslice-1.2a3-time.patch \
-           file://tcpslice-CVS.20010207-bpf.patch \
-           "
-SRC_URI[md5sum] = "e329cbeb7e589f132d92c3447c477190"
-SRC_URI[sha256sum] = "4096e8debc898cfaa16b5306f1c42f8d18b19e30e60da8d4deb781c8f684c840"
-
-inherit autotools-brokensep
-
-DEPENDS += "libpcap"
-
-# We do not want to autoreconf.  We must specify srcdir as ".".
-# We have to set the ac_cv_* cache variables as well as pass the normal
-# cross-compilation options to configure!
-#
-do_configure () {
-    oe_runconf \
-        --srcdir="." \
-        ac_cv_build=${BUILD_SYS} \
-        ac_cv_host=${HOST_SYS} \
-        ac_cv_target=${HOST_SYS}
-}
-
-do_install () {
-    mkdir -p ${D}/usr/sbin
-    install -c -m 555 tcpslice ${D}/usr/sbin
-}
-
diff --git a/meta-networking/recipes-support/tcpdump/tcpslice_1.5.bb b/meta-networking/recipes-support/tcpdump/tcpslice_1.5.bb
new file mode 100644
index 000000000..4909acdee
--- /dev/null
+++ b/meta-networking/recipes-support/tcpdump/tcpslice_1.5.bb
@@ -0,0 +1,25 @@
+SUMMARY = "tcpslice"
+DESCRIPTION = "A tool for extracting parts of a tcpdump packet trace."
+HOMEPAGE = "http://www.tcpdump.org/related.html"
+SECTION = "net"
+
+LICENSE = "BSD-4-Clause"
+LIC_FILES_CHKSUM = "file://tcpslice.c;endline=20;md5=99519e2e5234d1662a4ce16baa62c64e"
+
+SRC_URI = "http://www.tcpdump.org/release/${BP}.tar.gz \
+           "
+SRC_URI[md5sum] = "8907e60376e629f6e6ce2255988aaf47"
+SRC_URI[sha256sum] = "f6935e3e7ca00ef50c515d062fddd410868467ec5b6d8f2eca12066f8d91dda2"
+
+UPSTREAM_CHECK_REGEX = "tcpslice-(?P<pver>\d+(\.\d+)+)\.tar"
+
+inherit autotools-brokensep pkgconfig
+
+DEPENDS = "libpcap"
+
+EXTRA_AUTORECONF += "--exclude=aclocal"
+
+do_install () {
+    install -d ${D}${sbindir}
+    install -m 0755 tcpslice ${D}${sbindir}
+}
-- 
2.25.1



^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-30 14:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-30 14:39 [meta-networking][PATCH 1/2] tcpdump: upgrade 4.99.0 -> 4.99.1 Yi Zhao
2022-01-30 14:39 ` [meta-networking][PATCH 2/2] tcpslice: upgrade 1.2a3 -> 1.5 Yi Zhao

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.