mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-07-27 20:07:25 +00:00
libnet: update to v1.2 release
The previous recipe was building a release candidate from 2014. Switch to the official git repo which is currently maintained and use the v1.2 release instead. The extra patch fixes build on musl. Signed-off-by: Beniamin Sandu <beniaminsandu@gmail.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
-58
@@ -1,58 +0,0 @@
|
|||||||
From ffd7fab744a9ad2893169a8fb6244074604d5d0d Mon Sep 17 00:00:00 2001
|
|
||||||
From: rofl0r <retnyg@gmx.net>
|
|
||||||
Date: Tue, 12 Aug 2014 21:51:39 +0200
|
|
||||||
Subject: [PATCH] Support musl libc, remove support for glibc < 2.1
|
|
||||||
|
|
||||||
Upstream-Status: Backport
|
|
||||||
|
|
||||||
The workarounds for glibc < 2.1 (was released february 1999) break the
|
|
||||||
build with musl libc.
|
|
||||||
|
|
||||||
It is very unlikely that 2.0 or earlier is still in use, and if so,
|
|
||||||
1) that's a big security hole
|
|
||||||
2) code wouldnt compile anyway since noone tested build in the last decade
|
|
||||||
3) user of it wouldn't expect anyway to get bleeding edge sw built on it,
|
|
||||||
so he would just use the latest version that works for him.
|
|
||||||
|
|
||||||
Closes #52
|
|
||||||
|
|
||||||
Signed-off-by: rofl0r <retnyg@gmx.net>
|
|
||||||
Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
|
|
||||||
---
|
|
||||||
libnet/src/libnet_link_linux.c | 11 -----------
|
|
||||||
1 file changed, 11 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/libnet_link_linux.c b/src/libnet_link_linux.c
|
|
||||||
index 054458d..3c6df3c 100644
|
|
||||||
--- a/src/libnet_link_linux.c
|
|
||||||
+++ b/src/libnet_link_linux.c
|
|
||||||
@@ -30,26 +30,15 @@
|
|
||||||
#include <sys/time.h>
|
|
||||||
|
|
||||||
#include <net/if.h>
|
|
||||||
-#if (__GLIBC__)
|
|
||||||
#include <netinet/if_ether.h>
|
|
||||||
#include <net/if_arp.h>
|
|
||||||
-#else
|
|
||||||
-#include <linux/if_arp.h>
|
|
||||||
-#include <linux/if_ether.h>
|
|
||||||
-#endif
|
|
||||||
|
|
||||||
#if (HAVE_PACKET_SOCKET)
|
|
||||||
#ifndef SOL_PACKET
|
|
||||||
#define SOL_PACKET 263
|
|
||||||
#endif /* SOL_PACKET */
|
|
||||||
-#if __GLIBC__ >= 2 && __GLIBC_MINOR >= 1
|
|
||||||
#include <netpacket/packet.h>
|
|
||||||
#include <net/ethernet.h> /* the L2 protocols */
|
|
||||||
-#else
|
|
||||||
-#include <asm/types.h>
|
|
||||||
-#include <linux/if_packet.h>
|
|
||||||
-#include <linux/if_ether.h> /* The L2 protocols */
|
|
||||||
-#endif
|
|
||||||
#endif /* HAVE_PACKET_SOCKET */
|
|
||||||
|
|
||||||
#include "../include/libnet.h"
|
|
||||||
--
|
|
||||||
1.9.1
|
|
||||||
|
|
||||||
+31
@@ -0,0 +1,31 @@
|
|||||||
|
From a1659e261888bdbed51803132d52d9a6c6803c8a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Joachim Nilsson <troglobit@gmail.com>
|
||||||
|
Date: Sat, 19 Oct 2019 12:26:26 +0200
|
||||||
|
Subject: [PATCH] Use standard int64_t instead of __int64_t for mingw cross
|
||||||
|
build
|
||||||
|
|
||||||
|
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
|
||||||
|
---
|
||||||
|
include/libnet/libnet-structures.h | 6 +++---
|
||||||
|
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/include/libnet/libnet-structures.h b/include/libnet/libnet-structures.h
|
||||||
|
index 6084caa..34fffc6 100644
|
||||||
|
--- a/include/libnet/libnet-structures.h
|
||||||
|
+++ b/include/libnet/libnet-structures.h
|
||||||
|
@@ -49,9 +49,9 @@ struct libnet_port_list_chain
|
||||||
|
/* libnet statistics structure */
|
||||||
|
struct libnet_stats
|
||||||
|
{
|
||||||
|
- __int64_t packets_sent; /* packets sent */
|
||||||
|
- __int64_t packet_errors; /* packets errors */
|
||||||
|
- __int64_t bytes_written; /* bytes written */
|
||||||
|
+ int64_t packets_sent; /* packets sent */
|
||||||
|
+ int64_t packet_errors; /* packets errors */
|
||||||
|
+ int64_t bytes_written; /* bytes written */
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
--
|
||||||
|
2.25.1
|
||||||
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
SUMMARY = "A packet dissection and creation library"
|
|
||||||
# libnet at packetfactory.net is dead
|
|
||||||
HOMEPAGE = "https://github.com/sam-github/libnet"
|
|
||||||
SECTION = "libs"
|
|
||||||
LICENSE = "BSD-2-Clause"
|
|
||||||
LIC_FILES_CHKSUM = "file://doc/COPYING;md5=3ec839e00408b484d33b472a86b7c266"
|
|
||||||
DEPENDS = "libpcap"
|
|
||||||
# There are major API changes beween libnet v1.0 and libnet v1.1
|
|
||||||
PROVIDES = "libnet-1.2rc2"
|
|
||||||
|
|
||||||
SRC_URI = "${SOURCEFORGE_MIRROR}/libnet-dev/${BPN}-${PV}.tar.gz \
|
|
||||||
file://0001-Support-musl-libc-remove-support-for-glibc-2.1.patch \
|
|
||||||
"
|
|
||||||
|
|
||||||
SRC_URI[md5sum] = "f051e6e5bdecddb90f77c701c2ca1804"
|
|
||||||
SRC_URI[sha256sum] = "72c380785ad44183005e654b47cc12485ee0228d7fa6b0a87109ff7614be4a63"
|
|
||||||
|
|
||||||
UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/libnet-dev/files/"
|
|
||||||
UPSTREAM_CHECK_REGEX = "libnet-(?P<pver>\d+(\.\d+)+-*[a-z]*\d*)\.tar"
|
|
||||||
|
|
||||||
S = "${WORKDIR}/${BPN}-${PV}"
|
|
||||||
|
|
||||||
inherit autotools binconfig
|
|
||||||
|
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
SUMMARY = "A packet dissection and creation library"
|
||||||
|
HOMEPAGE = "https://github.com/libnet/libnet"
|
||||||
|
|
||||||
|
SECTION = "libs"
|
||||||
|
|
||||||
|
LICENSE = "BSD-2-Clause"
|
||||||
|
LIC_FILES_CHKSUM = "file://LICENSE;md5=07f291bf6e78efa05cec668cf6a09acc"
|
||||||
|
|
||||||
|
DEPENDS = "libpcap"
|
||||||
|
|
||||||
|
SRC_URI = "git://github.com/libnet/libnet.git;protocol=https;branch=master \
|
||||||
|
file://0001-Use-standard-int64_t-instead-of-__int64_t-for-mingw-.patch"
|
||||||
|
|
||||||
|
SRC_URI[sha256sum] = "1e9e9054d688b059bcbaf878d8c4fbf69bfc0c9386cd4e7779fbb53339050d2e"
|
||||||
|
SRCREV = "deeeeaeb84f8bc5d2299913d4ccf53d0d4c26966"
|
||||||
|
|
||||||
|
S = "${WORKDIR}/git"
|
||||||
|
|
||||||
|
inherit autotools binconfig
|
||||||
Reference in New Issue
Block a user