summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-benchmark/iperf2
diff options
context:
space:
mode:
Diffstat (limited to 'meta-oe/recipes-benchmark/iperf2')
-rw-r--r--meta-oe/recipes-benchmark/iperf2/iperf2/0001-Detect-bool-definition-considering-stdbool.h-being-p.patch58
-rw-r--r--meta-oe/recipes-benchmark/iperf2/iperf2_2.0.13.bb4
2 files changed, 61 insertions, 1 deletions
diff --git a/meta-oe/recipes-benchmark/iperf2/iperf2/0001-Detect-bool-definition-considering-stdbool.h-being-p.patch b/meta-oe/recipes-benchmark/iperf2/iperf2/0001-Detect-bool-definition-considering-stdbool.h-being-p.patch
new file mode 100644
index 000000000..45c69ca06
--- /dev/null
+++ b/meta-oe/recipes-benchmark/iperf2/iperf2/0001-Detect-bool-definition-considering-stdbool.h-being-p.patch
@@ -0,0 +1,58 @@
1From 6df092a4153c6c37cfaddcabf2cd25a910a7f6e1 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Mon, 2 Sep 2019 15:40:52 -0700
4Subject: [PATCH] Detect bool definition considering stdbool.h being present
5
6This helps in defining the value correctly on different platforms e.g.
7clang/libc++ depends on the definition coming from stdbool.h
8current builds fail to compile therefore
9
10TMPDIR/work/cortexa7t2hf-neon-vfpv4-yoe-linux-gnueabi/iperf2/2.0.13-r0/recipe-sysroot/usr/include/c++/v1/type_traits:742:29: error: redefinition of '__libcpp_is_integral<int>'
11template <> struct __libcpp_is_integral<int> : public true_type {};
12 ^~~~~~~~~~~~~~~~~~~~~~~~~
13
14Signed-off-by: Khem Raj <raj.khem@gmail.com>
15---
16 m4/dast.m4 | 7 ++++++-
17 1 file changed, 6 insertions(+), 1 deletion(-)
18
19--- a/m4/dast.m4
20+++ b/m4/dast.m4
21@@ -11,7 +11,12 @@ AH_TEMPLATE([false])
22
23 AC_DEFUN(DAST_CHECK_BOOL, [
24
25-AC_CHECK_SIZEOF(bool)
26+if test "$ac_cv_header_stdbool_h" = yes; then
27+ AC_CHECK_SIZEOF(bool,,[#include <stdbool.h>])
28+else
29+ AC_CHECK_SIZEOF(bool)
30+fi
31+
32 if test "$ac_cv_sizeof_bool" = 0 ; then
33 AC_DEFINE(bool, int)
34 fi
35--- a/configure.ac
36+++ b/configure.ac
37@@ -113,7 +113,7 @@ AC_SEARCH_LIBS([socket], [socket], [],
38
39 dnl Checks for header files.
40 AC_HEADER_STDC
41-AC_CHECK_HEADERS([arpa/inet.h libintl.h net/ethernet.h net/if.h linux/ip.h linux/udp.h linux/if_packet.h linux/filter.h netdb.h netinet/in.h stdlib.h string.h strings.h sys/socket.h sys/time.h syslog.h unistd.h signal.h ifaddrs.h])
42+AC_CHECK_HEADERS([arpa/inet.h libintl.h net/ethernet.h net/if.h linux/ip.h linux/udp.h linux/if_packet.h linux/filter.h netdb.h netinet/in.h stdbool.h stdlib.h string.h strings.h sys/socket.h sys/time.h syslog.h unistd.h signal.h ifaddrs.h])
43
44 dnl ===================================================================
45 dnl Checks for typedefs, structures
46--- a/include/util.h
47+++ b/include/util.h
48@@ -56,7 +56,9 @@
49 #ifdef HAVE_CONFIG_H
50 #include "config.h"
51 #endif
52-
53+#ifdef HAVE_STDBOOL_H
54+# include <stdbool.h>
55+#endif
56 #ifdef __cplusplus
57 extern "C" {
58 #endif
diff --git a/meta-oe/recipes-benchmark/iperf2/iperf2_2.0.13.bb b/meta-oe/recipes-benchmark/iperf2/iperf2_2.0.13.bb
index 2bd552d1d..4a520e3be 100644
--- a/meta-oe/recipes-benchmark/iperf2/iperf2_2.0.13.bb
+++ b/meta-oe/recipes-benchmark/iperf2/iperf2_2.0.13.bb
@@ -4,7 +4,9 @@ SECTION = "console/network"
4LICENSE = "BSD-2-Clause" 4LICENSE = "BSD-2-Clause"
5LIC_FILES_CHKSUM = "file://COPYING;md5=e136a7b2560d80bcbf0d9b3e1356ecff" 5LIC_FILES_CHKSUM = "file://COPYING;md5=e136a7b2560d80bcbf0d9b3e1356ecff"
6 6
7SRC_URI = " ${SOURCEFORGE_MIRROR}/${BPN}/iperf-${PV}.tar.gz" 7SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/iperf-${PV}.tar.gz \
8 file://0001-Detect-bool-definition-considering-stdbool.h-being-p.patch \
9"
8 10
9SRC_URI[md5sum] = "31ea1c6d5cbf80b16ff3abe4288dad5e" 11SRC_URI[md5sum] = "31ea1c6d5cbf80b16ff3abe4288dad5e"
10SRC_URI[sha256sum] = "c88adec966096a81136dda91b4bd19c27aae06df4d45a7f547a8e50d723778ad" 12SRC_URI[sha256sum] = "c88adec966096a81136dda91b4bd19c27aae06df4d45a7f547a8e50d723778ad"