Skip to contentSkip to conversation

Fixes with clang

PATCH In review Khem Raj 3 participants 18 messages Sep 14, 2015 – Sep 18, 2015

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

cover Fixes with clang

These fixes generic in nature helps improve the portability of patches and make them work on non GNU toolchain components

The following changes since commit 2c8c3d9c4b65d2a5c7976d530138ebcaac2b1447:

gcc: reformat 0063-nativesdk-gcc-support.patch (2015-09-12 23:01:31 +0100)

are available in the git repository at:

git://github.com/kraj/openembedded-core kraj/misc-fixes
https://github.com//tree/kraj/misc-fixes

Khem Raj (12):
xz: Correctly specify GPL-3.0 with autoconf exception
hostap-utils: Use C99 stddefs in defining local typedefs
xorg-driver: Fix logical && with bitwise and operation
qt4: Fix kmap2qmap build with clang
gummiboot: Fix build warnings seen with gcc5
gnu-efi, syslinux: Support gcc < 4.7
syslinux: Dont bypass gcc driver for dependency generation options
opkg: Include stdio.h for FILE definition
quota: Replace using -I= with STAGING_INCDIR
connman: Fix build with musl
waffle: upgrade waffle_1.5.1.bb -> waffle_1.5.2.bb
sysstat: Include needed headers explicitly

 .../gnu-efi/gnu-efi/gcc46-compatibility.patch      | 21 ++++++
 meta/recipes-bsp/gnu-efi/gnu-efi_3.0.3.bb          |  1 +
 ...-C-syntax-errors-for-function-declaration.patch | 74 +++++++++++++++++++
 meta/recipes-bsp/gummiboot/gummiboot_git.bb        |  3 +
 ...-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch | 36 +++++++++
 meta/recipes-bsp/hostap/hostap-utils.inc           |  4 +-
 meta/recipes-connectivity/connman/connman.inc      |  1 +
 ...acktrace-API-availability-before-using-it.patch | 55 ++++++++++++++
 ...resolve-musl-does-not-implement-res_ninit.patch | 77 ++++++++++++++++++++
 .../0003-Fix-header-inclusions-for-musl.patch      | 85 ++++++++++++++++++++++
 meta/recipes-connectivity/connman/connman_1.30.bb  |  3 +
 ...-include-stdio.h-for-getting-FILE-defined.patch | 45 ++++++++++++
 meta/recipes-devtools/opkg/opkg_0.3.0.bb           |  1 +
 .../syslinux/0010-gcc46-compatibility.patch        | 37 ++++++++++
 .../0011-mk-MMD-does-not-take-any-arguments.patch  | 33 +++++++++
 meta/recipes-devtools/syslinux/syslinux_6.03.bb    |  2 +
 .../quota/quota/remove_non_posix_types.patch       | 13 ++++
 meta/recipes-extended/quota/quota_4.02.bb          |  2 +-
 .../0001-Include-needed-headers-explicitly.patch   | 62 ++++++++++++++++
 meta/recipes-extended/sysstat/sysstat_11.1.5.bb    |  2 +
 meta/recipes-extended/xz/xz_5.2.1.bb               |  2 +-
 ...-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch | 54 ++++++++++++++
 .../waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb}    |  8 +-
 ...put_dpms-Replace-logical-with-bitwise-ope.patch | 31 ++++++++
 .../xorg-driver/xf86-video-omap_0.4.3.bb           |  2 +
 meta/recipes-qt/qt4/qt4-4.8.7.inc                  |  1 +
 .../0034-Fix-kmap2qmap-build-with-clang.patch      | 34 +++++++++
 27 files changed, 683 insertions(+), 6 deletions(-)
 create mode 100644 meta/recipes-bsp/gnu-efi/gnu-efi/gcc46-compatibility.patch
 create mode 100644 meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
 create mode 100644 meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch
 create mode 100644 meta/recipes-connectivity/connman/connman/0001-Detect-backtrace-API-availability-before-using-it.patch
 create mode 100644 meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch
 create mode 100644 meta/recipes-connectivity/connman/connman/0003-Fix-header-inclusions-for-musl.patch
 create mode 100644 meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch
 create mode 100644 meta/recipes-devtools/syslinux/syslinux/0010-gcc46-compatibility.patch
 create mode 100644 meta/recipes-devtools/syslinux/syslinux/0011-mk-MMD-does-not-take-any-arguments.patch
 create mode 100644 meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch
 create mode 100644 meta/recipes-graphics/waffle/waffle/0001-third_party-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch
 rename meta/recipes-graphics/waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb} (84%)
 create mode 100644 meta/recipes-graphics/xorg-driver/xf86-video-omap/0001-drmmode_output_dpms-Replace-logical-with-bitwise-ope.patch
 create mode 100644 meta/recipes-qt/qt4/qt4-4.8.7/0034-Fix-kmap2qmap-build-with-clang.patch
Signature · 1 line
2.5.2
author
#1 lore raw

PATCH 1/12 xz: Correctly specify GPL-3.0 with autoconf exception

There is m4/ax_pthread.m4 macro which uses GPL-3.0 with autoconf exception, there is no other occurance of GPL-3.0 use, lets mark the licence correctly.

---
 meta/recipes-extended/xz/xz_5.2.1.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-extended/xz/xz_5.2.1.bb +1 -1
index e0ae48f..cf7fba6 100644
@@ -6,7 +6,7 @@ SECTION = "base"
 # which is GPLv3 is an m4 macro which isn't shipped in any of our packages,
 # and the LGPL bits are under lib/, which appears to be used for libgnu, which
 # appears to be used for DOS builds. So we're left with GPLv2+ and PD.
-LICENSE = "GPLv2+ & GPLv3+ & LGPLv2.1+ & PD"
+LICENSE = "GPLv2+ & GPL-3.0-with-autoconf-exception & LGPLv2.1+ & PD"
 LICENSE_${PN} = "GPLv2+"
 LICENSE_${PN}-dev = "GPLv2+"
 LICENSE_${PN}-staticdev = "GPLv2+"
Signature · 1 line
2.5.2
author
#2 lore raw

PATCH 2/12 hostap-utils: Use C99 stddefs in defining local typedefs

The code is creating more abstract types which is nice however it should be using standard defines from stdint.h and not random defines to base its own type system

---
 ...-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch | 36 ++++++++++++++++++++++
 meta/recipes-bsp/hostap/hostap-utils.inc           |  4 ++-
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch
meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch new file +36 -0
new file mode 100644
index 0000000..b44dca3
@@ -0,0 +1,36 @@
+From 742fb110d9841a04b3ced256b0bf80ff304dcaff Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Mon, 31 Aug 2015 05:45:08 +0000
+Subject: [PATCH] Define _u32/__s32/__u16/__s16/__u8 in terms of c99 types
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ wireless_copy.h | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/wireless_copy.h b/wireless_copy.h
+index 8208258..1171a35 100644
+--- a/wireless_copy.h
++++ b/wireless_copy.h
+@@ -86,11 +86,11 @@
+ #else
+ #include <sys/types.h>
+ #include <net/if.h>
+-typedef __uint32_t __u32;
+-typedef __int32_t __s32;
+-typedef __uint16_t __u16;
+-typedef __int16_t __s16;
+-typedef __uint8_t __u8;
++typedef u_int32_t __u32;
++typedef int32_t __s32;
++typedef u_int16_t __u16;
++typedef int16_t __s16;
++typedef u_int8_t __u8;
+ #ifndef __user
+ #define __user
+ #endif /* __user */
+-- 
+2.5.1
+
meta/recipes-bsp/hostap/hostap-utils.inc +3 -1
index 89d977a..140321d 100644
@@ -10,7 +10,9 @@ SECTION = "kernel/userland"
 PR = "r4"
 
 SRC_URI = "http://hostap.epitest.fi/releases/hostap-utils-${PV}.tar.gz \
-	   file://hostap-fw-load.patch"
+           file://hostap-fw-load.patch \
+           file://0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch \
+"
 S = "${WORKDIR}/hostap-utils-${PV}"
 
 BINARIES = "hostap_crypt_conf hostap_diag hostap_fw_load hostap_io_debug \
Signature · 1 line
2.5.2
#3 lore raw

Re: [PATCH 02/12] hostap-utils: Use C99 stddefs in defining local typedefs

Quoted 3 lines · Khem Raj

The code is creating more abstract types which is nice however it should be using standard defines from stdint.h and not random defines to base its own type system

These types are not random. They are standard Linux kernel types used by headers exported to userspace and their definitions come from <linux/types.h>. These headers should not depend on libc headers like stdint.h.

Also, this file is actually a convenience copy of <linux/wireless.h> which should be used directly instead.

-Mikko

Quoted 72 lines
---
 ...-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch | 36 ++++++++++++++++++++++
 meta/recipes-bsp/hostap/hostap-utils.inc           |  4 ++-
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch
meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch new file +36 -0
new file mode 100644
index 0000000..b44dca3
@@ -0,0 +1,36 @@
+From 742fb110d9841a04b3ced256b0bf80ff304dcaff Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Mon, 31 Aug 2015 05:45:08 +0000
+Subject: [PATCH] Define _u32/__s32/__u16/__s16/__u8 in terms of c99 types
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ wireless_copy.h | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/wireless_copy.h b/wireless_copy.h
+index 8208258..1171a35 100644
+--- a/wireless_copy.h
++++ b/wireless_copy.h
+@@ -86,11 +86,11 @@
+ #else
+ #include <sys/types.h>
+ #include <net/if.h>
+-typedef __uint32_t __u32;
+-typedef __int32_t __s32;
+-typedef __uint16_t __u16;
+-typedef __int16_t __s16;
+-typedef __uint8_t __u8;
++typedef u_int32_t __u32;
++typedef int32_t __s32;
++typedef u_int16_t __u16;
++typedef int16_t __s16;
++typedef u_int8_t __u8;
+ #ifndef __user
+ #define __user
+ #endif /* __user */
+-- 
+2.5.1
+
meta/recipes-bsp/hostap/hostap-utils.inc +3 -1
index 89d977a..140321d 100644
@@ -10,7 +10,9 @@ SECTION = "kernel/userland"
 PR = "r4"
 
 SRC_URI = "http://hostap.epitest.fi/releases/hostap-utils-${PV}.tar.gz \
-	   file://hostap-fw-load.patch"
+           file://hostap-fw-load.patch \
+           file://0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch \
+"
 S = "${WORKDIR}/hostap-utils-${PV}"
 
 BINARIES = "hostap_crypt_conf hostap_diag hostap_fw_load hostap_io_debug \
Signature · 7 lines
2.5.2

-- 
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
author
#4 lore raw

Re: [PATCH 02/12] hostap-utils: Use C99 stddefs in defining local typedefs

Quoted 8 lines · On Mon, Sep 14, 2015 at 11:33 PM, <[email protected]> wrote:
Quoted 3 lines · Khem Raj

The code is creating more abstract types which is nice however it should be using standard defines from stdint.h and not random defines to base its own type system

These types are not random. They are standard Linux kernel types used by headers exported to userspace and their definitions come from <linux/types.h>. These headers should not depend on libc headers like stdint.h.

Right they are not random in general but they are randomly being redefined by the application,
if it should be using linux/types.h those are different types than what is being defined here. I have just
made the semantics of existing logic to be more c99 compliant.

Quoted 3 lines

Also, this file is actually a convenience copy of <linux/wireless.h> which should be used directly instead.

There must be a reason to make own copy. May be hostap-utils want to be portable to more than linux

Quoted 75 lines

-Mikko

Quoted 72 lines
---
 ...-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch | 36 ++++++++++++++++++++++
 meta/recipes-bsp/hostap/hostap-utils.inc           |  4 ++-
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch
meta/recipes-bsp/hostap/hostap-utils-0.4.7/0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch new file +36 -0
new file mode 100644
index 0000000..b44dca3
@@ -0,0 +1,36 @@
+From 742fb110d9841a04b3ced256b0bf80ff304dcaff Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Mon, 31 Aug 2015 05:45:08 +0000
+Subject: [PATCH] Define _u32/__s32/__u16/__s16/__u8 in terms of c99 types
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ wireless_copy.h | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/wireless_copy.h b/wireless_copy.h
+index 8208258..1171a35 100644
+--- a/wireless_copy.h
++++ b/wireless_copy.h
+@@ -86,11 +86,11 @@
+ #else
+ #include <sys/types.h>
+ #include <net/if.h>
+-typedef __uint32_t __u32;
+-typedef __int32_t __s32;
+-typedef __uint16_t __u16;
+-typedef __int16_t __s16;
+-typedef __uint8_t __u8;
++typedef u_int32_t __u32;
++typedef int32_t __s32;
++typedef u_int16_t __u16;
++typedef int16_t __s16;
++typedef u_int8_t __u8;
+ #ifndef __user
+ #define __user
+ #endif /* __user */
+--
+2.5.1
+
meta/recipes-bsp/hostap/hostap-utils.inc +3 -2
index 89d977a..140321d 100644
@@ -10,7 +10,9 @@ SECTION = "kernel/userland"
 PR = "r4"
 
 SRC_URI = "http://hostap.epitest.fi/releases/hostap-utils-${PV}.tar.gz \
-        file://hostap-fw-load.patch"
+           file://hostap-fw-load.patch \
+           file://0001-Define-_u32-__s32-__u16-__s16-__u8-in-terms-of-c99-t.patch \
+"
 S = "${WORKDIR}/hostap-utils-${PV}"
 
 BINARIES = "hostap_crypt_conf hostap_diag hostap_fw_load hostap_io_debug \
--

2.5.2

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#5 lore raw

Re: [PATCH 02/12] hostap-utils: Use C99 stddefs in defining local typedefs

Quoted 17 lines · Khem Raj
Quoted 8 lines · On Mon, Sep 14, 2015 at 11:33 PM, <[email protected]> wrote:
Quoted 3 lines · Khem Raj

The code is creating more abstract types which is nice however it should be using standard defines from stdint.h and not random defines to base its own type system

These types are not random. They are standard Linux kernel types used by headers exported to userspace and their definitions come from <linux/types.h>. These headers should not depend on libc headers like stdint.h.

Right they are not random in general but they are randomly being redefined by the application,
if it should be using linux/types.h those are different types than what is being defined here. I have just
made the semantics of existing logic to be more c99 compliant.

Quoted 1 line
Quoted 5 lines
Quoted 2 lines

Also, this file is actually a convenience copy of <linux/wireless.h> which should be used directly instead.

There must be a reason to make own copy. May be hostap-utils want to be portable to more than linux

A private copy of <linux/wireless.h> is only usefull with Linux kernel. Since mid 2000's Linux kernel has a way to properly export these headers to userspace. Thus the private copies should not be needed anymore.

-Mikko

author
#6 lore raw

PATCH 3/12 xorg-driver: Fix logical && with bitwise and operation

In reply to Khem Raj

This must have been a typo which is a bug infact we should have used bitwise & in first place.

---
 ...put_dpms-Replace-logical-with-bitwise-ope.patch | 31 ++++++++++++++++++++++
 .../xorg-driver/xf86-video-omap_0.4.3.bb           |  2 ++
 2 files changed, 33 insertions(+)
 create mode 100644 meta/recipes-graphics/xorg-driver/xf86-video-omap/0001-drmmode_output_dpms-Replace-logical-with-bitwise-ope.patch
meta/recipes-graphics/xorg-driver/xf86-video-omap/0001-drmmode_output_dpms-Replace-logical-with-bitwise-ope.patch new file +31 -0
new file mode 100644
index 0000000..41e77d3
@@ -0,0 +1,31 @@
+From fc653ca3b36435aea281ae409fb90f85e1bc0d81 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Mon, 7 Sep 2015 08:44:13 +0000
+Subject: [freedreno][PATCH] drmmode_output_dpms: Replace logical && with bitwise &
+ operation
+
+This is a mask calculation so bitbwise & should have been used
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Submitted
+
+ src/drmmode_display.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/drmmode_display.c b/src/drmmode_display.c
+index c3cf4f8..eb54b59 100644
+--- a/src/drmmode_display.c
++++ b/src/drmmode_display.c
+@@ -777,7 +777,7 @@ drmmode_output_dpms(xf86OutputPtr output, int mode)
+ 
+ 	for (i = 0; i < koutput->count_props; i++) {
+ 		props = drmModeGetProperty(drmmode->fd, koutput->props[i]);
+-		if (props && (props->flags && DRM_MODE_PROP_ENUM)) {
++		if (props && (props->flags & DRM_MODE_PROP_ENUM)) {
+ 			if (!strcmp(props->name, "DPMS")) {
+ 				mode_id = koutput->props[i];
+ 				drmModeFreeProperty(props);
+-- 
+2.5.1
+
meta/recipes-graphics/xorg-driver/xf86-video-omap_0.4.3.bb +2 -0
index 5f3a532..76682ed 100644
@@ -24,6 +24,8 @@ LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=10ce5de3b111315ea652a5f74ec0c602"
 DEPENDS += "virtual/libx11 libdrm xf86driproto"
 
+SRC_URI += "file://0001-drmmode_output_dpms-Replace-logical-with-bitwise-ope.patch"
+
 SRC_URI[md5sum] = "be35daf6fa4b75092cc4a8978c437bc5"
 SRC_URI[sha256sum] = "db1e0e69fd4c4c8fdca5ef2cb0447bccd7518a718495876a6904bef57b39986d"
 
Signature · 1 line
2.5.2
author
#7 lore raw

PATCH 4/12 qt4: Fix kmap2qmap build with clang

In reply to Khem Raj

Adapted and backported https://codereview.qt-project.org/#/c/107464/

Fixes errors like ../../include/QtCore/../../src/corelib/tools/qalgorithms.h:161:20:
error: call to function 'operator<' that is neither visible in the template definition nor found by argument-dependent lookup

        return (t1 < t2);
---
 meta/recipes-qt/qt4/qt4-4.8.7.inc                  |  1 +
 .../0034-Fix-kmap2qmap-build-with-clang.patch      | 34 ++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 meta/recipes-qt/qt4/qt4-4.8.7/0034-Fix-kmap2qmap-build-with-clang.patch
meta/recipes-qt/qt4/qt4-4.8.7.inc +1 -0
index 5257e76..d38637c 100644
@@ -25,6 +25,7 @@ SRC_URI = "http://download.qt-project.org/official_releases/qt/4.8/${PV}/qt-ever
            file://0030-aarch64_arm64_qatomic_support.patch \
            file://0031-aarch64_arm64_mkspecs.patch \
            file://0032-aarch64_add_header.patch \
+           file://0034-Fix-kmap2qmap-build-with-clang.patch \
            file://Fix-QWSLock-invalid-argument-logs.patch \
            file://add_check_for_aarch64_32.patch \
            file://g++.conf \
meta/recipes-qt/qt4/qt4-4.8.7/0034-Fix-kmap2qmap-build-with-clang.patch new file +34 -0
new file mode 100644
index 0000000..f47a1d9
@@ -0,0 +1,34 @@
+From: Samuel Gaist <[email protected]>
+Date: Wed, 4 Mar 2015 20:16:50 +0000 (+0100)
+Subject: Fix kmap2qmap build on OS X
+X-Git-Tag: v5.4.2~6
+X-Git-Url: https://codereview.qt-project.org/gitweb?p=qt%2Fqttools.git;a=commitdiff_plain;h=cf196a2565235f649b88fac55b53270bea23458d;hp=3070815a24239bd0f469bfeb8d0a1f091974e28e
+
+Fix kmap2qmap build on OS X
+
+Currently kmap2qmap fails to build on OS X (clang) This patch aims to
+fix this.
+
+Change-Id: I61c985dc7ad1f2486368c39aa976599d274942ab
+Reviewed-by: Friedemann Kleint <[email protected]>
+---
+Upstream-Status: Backport
+Index: qt-everywhere-opensource-src-4.8.7/tools/kmap2qmap/main.cpp
+===================================================================
+--- qt-everywhere-opensource-src-4.8.7.orig/tools/kmap2qmap/main.cpp
++++ qt-everywhere-opensource-src-4.8.7/tools/kmap2qmap/main.cpp
+@@ -385,9 +385,11 @@ static const int symbol_synonyms_size =
+ 
+ // makes the generated array in --header mode a bit more human readable
+ QT_BEGIN_NAMESPACE
+-static bool operator<(const QWSKeyboard::Mapping &m1, const QWSKeyboard::Mapping &m2)
+-{
+-    return m1.keycode != m2.keycode ? m1.keycode < m2.keycode : m1.modifiers < m2.modifiers;
++namespace QWSKeyboard {
++    static bool operator<(const Mapping &m1, const Mapping &m2)
++    {
++        return m1.keycode != m2.keycode ? m1.keycode < m2.keycode : m1.modifiers < m2.modifiers;
++    }
+ }
+ QT_END_NAMESPACE
+ 
Signature · 1 line
2.5.2
author
#8 lore raw

PATCH 5/12 gummiboot: Fix build warnings seen with gcc5

In reply to Khem Raj

gummiboot uses -mno-sse so we should disble using sse for mfpmath as well

Fix syntax errors in struct defines

---
 ...-C-syntax-errors-for-function-declaration.patch | 74 ++++++++++++++++++++++
 meta/recipes-bsp/gummiboot/gummiboot_git.bb        |  3 +
 2 files changed, 77 insertions(+)
 create mode 100644 meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch new file +74 -0
new file mode 100644
index 0000000..fa50bc4
@@ -0,0 +1,74 @@
+From 55957faf1272c8f5f304909faeebf647a78e3701 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Wed, 9 Sep 2015 07:19:45 +0000
+Subject: [PATCH] console: Fix C syntax errors for function declaration
+
+To address this, the semicolons after the function parameters should be
+replaced by commas, and the last one should be omitted
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ src/efi/console.c | 26 +++++++++++++-------------
+ 1 file changed, 13 insertions(+), 13 deletions(-)
+
+diff --git a/src/efi/console.c b/src/efi/console.c
+index 6206c80..66aa88f 100644
+--- a/src/efi/console.c
++++ b/src/efi/console.c
+@@ -27,8 +27,8 @@
+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL;
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_INPUT_RESET_EX)(
+-        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
+-        BOOLEAN ExtendedVerification;
++        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
++        BOOLEAN ExtendedVerification
+ );
+ 
+ typedef UINT8 EFI_KEY_TOGGLE_STATE;
+@@ -44,29 +44,29 @@ typedef struct {
+ } EFI_KEY_DATA;
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_INPUT_READ_KEY_EX)(
+-        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
+-        EFI_KEY_DATA *KeyData;
++        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
++        EFI_KEY_DATA *KeyData
+ );
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_SET_STATE)(
+-        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
+-        EFI_KEY_TOGGLE_STATE *KeyToggleState;
++        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
++        EFI_KEY_TOGGLE_STATE *KeyToggleState
+ );
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_KEY_NOTIFY_FUNCTION)(
+-        EFI_KEY_DATA *KeyData;
++        EFI_KEY_DATA *KeyData
+ );
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_REGISTER_KEYSTROKE_NOTIFY)(
+-        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
+-        EFI_KEY_DATA KeyData;
+-        EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction;
+-        VOID **NotifyHandle;
++        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
++        EFI_KEY_DATA KeyData,
++        EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,
++        VOID **NotifyHandle
+ );
+ 
+ typedef EFI_STATUS (EFIAPI *EFI_UNREGISTER_KEYSTROKE_NOTIFY)(
+-        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
+-        VOID *NotificationHandle;
++        struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
++        VOID *NotificationHandle
+ );
+ 
+ typedef struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL {
+-- 
+2.5.1
+
meta/recipes-bsp/gummiboot/gummiboot_git.bb +3 -0
index 91c3db9..376ab54 100644
@@ -13,6 +13,7 @@ PV = "48+git${SRCPV}"
 SRCREV = "2bcd919c681c952eb867ef1bdb458f1bc49c2d55"
 SRC_URI = "git://anongit.freedesktop.org/gummiboot \
            file://fix-objcopy.patch \
+           file://0001-console-Fix-C-syntax-errors-for-function-declaration.patch \
           "
 
 # Note: Add COMPATIBLE_HOST here is only because it depends on gnu-efi
@@ -28,6 +29,8 @@ EXTRA_OECONF = "--disable-manpages --with-efi-includedir=${STAGING_INCDIR} \
 
 EXTRA_OEMAKE += "gummibootlibdir=${libdir}/gummiboot"
 
+TUNE_CCARGS_remove = "-mfpmath=sse"
+
 do_deploy () {
         install ${B}/gummiboot*.efi ${DEPLOYDIR}
 }
Signature · 1 line
2.5.2
author
#9 lore raw

PATCH 6/12 gnu-efi, syslinux: Support gcc < 4.7

In reply to Khem Raj

This helps compiling the code with older gcc especially on older build hosts, additionally clang advertizes itself as gcc 4.2.1 so it helps compiling dependent modues using clang as well

---
 .../gnu-efi/gnu-efi/gcc46-compatibility.patch      | 21 ++++++++++++
 meta/recipes-bsp/gnu-efi/gnu-efi_3.0.3.bb          |  1 +
 .../syslinux/0010-gcc46-compatibility.patch        | 37 ++++++++++++++++++++++
 meta/recipes-devtools/syslinux/syslinux_6.03.bb    |  1 +
 4 files changed, 60 insertions(+)
 create mode 100644 meta/recipes-bsp/gnu-efi/gnu-efi/gcc46-compatibility.patch
 create mode 100644 meta/recipes-devtools/syslinux/syslinux/0010-gcc46-compatibility.patch
meta/recipes-bsp/gnu-efi/gnu-efi/gcc46-compatibility.patch new file +21 -0
new file mode 100644
index 0000000..0ce6d7b
@@ -0,0 +1,21 @@
+don't break with old compilers and -DGNU_EFI_USE_MS_ABI
+It's entirely legitimate to request GNU_EFI_USE_MS_ABI even if the current
+compiler doesn't support it, and gnu-efi should transparently fall back to
+using legacy techniques to set the calling convention.  We don't get type
+checking, but at least it will still compile.
+
+Author: Steve Langasek <[email protected]>
+Upstream-Status: Pending
+Index: gnu-efi-3.0.3/inc/x86_64/efibind.h
+===================================================================
+--- gnu-efi-3.0.3.orig/inc/x86_64/efibind.h
++++ gnu-efi-3.0.3/inc/x86_64/efibind.h
+@@ -25,8 +25,6 @@ Revision History
+ #if defined(GNU_EFI_USE_MS_ABI)
+     #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))
+         #define HAVE_USE_MS_ABI 1
+-    #else
+-        #error Compiler is too old for GNU_EFI_USE_MS_ABI
+     #endif
+ #endif
+ 
meta/recipes-bsp/gnu-efi/gnu-efi_3.0.3.bb +1 -0
index 1a1ba40..eca3459 100644
@@ -18,6 +18,7 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
            file://parallel-make-archives.patch \
            file://lib-Makefile-fix-parallel-issue.patch \
            file://gnu-efi-Make-setjmp.S-portable-to-ARM.patch \
+           file://gcc46-compatibility.patch \
           "
 
 SRC_URI[md5sum] = "15a4bcbc18a9a5e8110ed955970622e6"
meta/recipes-devtools/syslinux/syslinux/0010-gcc46-compatibility.patch new file +37 -0
new file mode 100644
index 0000000..6279258
@@ -0,0 +1,37 @@
+don't break with old compilers and -DGNU_EFI_USE_MS_ABI
+It's entirely legitimate to request GNU_EFI_USE_MS_ABI even if the current
+compiler doesn't support it, and gnu-efi should transparently fall back to
+using legacy techniques to set the calling convention.  We don't get type
+checking, but at least it will still compile.
+
+Adapted from gnu-efi
+
+Author: Steve Langasek <[email protected]>
+Upstream-Status: Pending
+
+Index: syslinux-6.03/efi64/include/efi/x86_64/efibind.h
+===================================================================
+--- syslinux-6.03.orig/efi64/include/efi/x86_64/efibind.h
++++ syslinux-6.03/efi64/include/efi/x86_64/efibind.h
+@@ -25,8 +25,6 @@ Revision History
+ #if defined(GNU_EFI_USE_MS_ABI)
+     #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))
+         #define HAVE_USE_MS_ABI 1
+-    #else
+-        #error Compiler is too old for GNU_EFI_USE_MS_ABI
+     #endif
+ #endif
+ 
+Index: syslinux-6.03/gnu-efi/gnu-efi-3.0/inc/x86_64/efibind.h
+===================================================================
+--- syslinux-6.03.orig/gnu-efi/gnu-efi-3.0/inc/x86_64/efibind.h
++++ syslinux-6.03/gnu-efi/gnu-efi-3.0/inc/x86_64/efibind.h
+@@ -25,8 +25,6 @@ Revision History
+ #if defined(GNU_EFI_USE_MS_ABI)
+     #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))
+         #define HAVE_USE_MS_ABI 1
+-    #else
+-        #error Compiler is too old for GNU_EFI_USE_MS_ABI
+     #endif
+ #endif
+ 
meta/recipes-devtools/syslinux/syslinux_6.03.bb +1 -0
index ef9ae2f..94077da 100644
@@ -21,6 +21,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/boot/syslinux/syslinux-${PV}.tar.xz \
            file://0007-linux-syslinux-implement-ext_construct_sectmap_fs.patch \
            file://0008-libinstaller-syslinuxext-implement-syslinux_patch_bo.patch \
            file://0009-linux-syslinux-implement-install_bootblock.patch \
+           file://0010-gcc46-compatibility.patch \
            "
 
 SRC_URI[md5sum] = "92a253df9211e9c20172796ecf388f13"
Signature · 1 line
2.5.2
author
#10 lore raw

PATCH 7/12 syslinux: Dont bypass gcc driver for dependency generation options

In reply to Khem Raj

GCC docs also do not recommend using -Wp instead pass the option via gcc driver and let it process it as needed

This also helps in making it work with clang as well

---
 .../0011-mk-MMD-does-not-take-any-arguments.patch  | 33 ++++++++++++++++++++++
 meta/recipes-devtools/syslinux/syslinux_6.03.bb    |  1 +
 2 files changed, 34 insertions(+)
 create mode 100644 meta/recipes-devtools/syslinux/syslinux/0011-mk-MMD-does-not-take-any-arguments.patch
meta/recipes-devtools/syslinux/syslinux/0011-mk-MMD-does-not-take-any-arguments.patch new file +33 -0
new file mode 100644
index 0000000..443c1cc
@@ -0,0 +1,33 @@
+From 0f3d83c25491951f1fa84c7957358ef3d1bcd8a9 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Wed, 9 Sep 2015 17:39:22 +0000
+Subject: [PATCH] mk: -MMD does not take any arguments
+
+Specify -Wp for each option, clang seems to not accept
+-Wp,-x,y,-a,b
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ mk/syslinux.mk | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+Index: syslinux-6.03/mk/syslinux.mk
+===================================================================
+--- syslinux-6.03.orig/mk/syslinux.mk
++++ syslinux-6.03/mk/syslinux.mk
+@@ -82,11 +82,11 @@ ARCH ?= $(strip $(SUBARCH))
+ GCCWARN  = -W -Wall -Wstrict-prototypes $(DEBUGOPT)
+ 
+ # Common stanza to make gcc generate .*.d dependency files
+-MAKEDEPS = -Wp,-MT,$@,-MD,$(dir $@).$(notdir $@).d
++MAKEDEPS = -MT $@ -MD
+ 
+ # Dependencies that exclude system headers; use whenever we use
+ # header files from the platform.
+-UMAKEDEPS = -Wp,-MT,$@,-MMD,$(dir $@).$(notdir $@).d
++UMAKEDEPS = -MT $@ -MMD
+ 
+ # Items that are only appropriate during development; this file is
+ # removed when tarballs are generated.
meta/recipes-devtools/syslinux/syslinux_6.03.bb +1 -0
index 94077da..8534528 100644
@@ -22,6 +22,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/boot/syslinux/syslinux-${PV}.tar.xz \
            file://0008-libinstaller-syslinuxext-implement-syslinux_patch_bo.patch \
            file://0009-linux-syslinux-implement-install_bootblock.patch \
            file://0010-gcc46-compatibility.patch \
+           file://0011-mk-MMD-does-not-take-any-arguments.patch \
            "
 
 SRC_URI[md5sum] = "92a253df9211e9c20172796ecf388f13"
Signature · 1 line
2.5.2
author
#11 lore raw

PATCH 8/12 opkg: Include stdio.h for FILE definition

In reply to Khem Raj

Helps with compling it on musl

---
 ...-include-stdio.h-for-getting-FILE-defined.patch | 45 ++++++++++++++++++++++
 meta/recipes-devtools/opkg/opkg_0.3.0.bb           |  1 +
 2 files changed, 46 insertions(+)
 create mode 100644 meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch
meta/recipes-devtools/opkg/opkg/0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch new file +45 -0
new file mode 100644
index 0000000..acc1338
@@ -0,0 +1,45 @@
+From 58f4d3d63cd6097154205ea7ee042005036659b3 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Thu, 10 Sep 2015 21:43:32 -0700
+Subject: [PATCH] libopkg: include stdio.h for getting FILE defined
+To: [email protected]
+Cc: [email protected]
+
+For some libc(musl) stdio.h may not get included indirectly which means
+we need to mention it in explicit include list
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Submitted
+
+ libopkg/opkg_verify.c | 1 +
+ libopkg/pkg_src.c     | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/libopkg/opkg_verify.c b/libopkg/opkg_verify.c
+index 41dc3f4..a71591d 100644
+--- a/libopkg/opkg_verify.c
++++ b/libopkg/opkg_verify.c
+@@ -18,6 +18,7 @@
+ 
+ #include <malloc.h>
+ #include <string.h>
++#include <stdio.h>
+ 
+ #include "file_util.h"
+ #include "opkg_conf.h"
+diff --git a/libopkg/pkg_src.c b/libopkg/pkg_src.c
+index e31ec21..6b49a00 100644
+--- a/libopkg/pkg_src.c
++++ b/libopkg/pkg_src.c
+@@ -20,6 +20,7 @@
+ 
+ #include <malloc.h>
+ #include <unistd.h>
++#include <stdio.h>
+ 
+ #include "file_util.h"
+ #include "opkg_conf.h"
+-- 
+2.5.1
+
meta/recipes-devtools/opkg/opkg_0.3.0.bb +1 -0
index f4dbb2d..884368f 100644
@@ -15,6 +15,7 @@ SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz
            file://opkg-configure.service \
            file://opkg.conf \
            file://0001-opkg_archive-add-support-for-empty-compressed-files.patch \
+           file://0001-libopkg-include-stdio.h-for-getting-FILE-defined.patch \
 "
 
 SRC_URI[md5sum] = "3412cdc71d78b98facc84b19331ec64e"
Signature · 1 line
2.5.2
author
#12 lore raw

PATCH 9/12 quota: Replace using -I= with STAGING_INCDIR

In reply to Khem Raj

-I= is gcc specific, using STAGING_INCDIR makes it compiler independent Update posix types patch to include new u_int -> uint32_t changes

---
 .../quota/quota/remove_non_posix_types.patch                | 13 +++++++++++++
 meta/recipes-extended/quota/quota_4.02.bb                   |  2 +-
 2 files changed, 14 insertions(+), 1 deletion(-)
meta/recipes-extended/quota/quota/remove_non_posix_types.patch +13 -0
index 5442d98..06ff13c 100644
@@ -183,3 +183,16 @@ Index: quota-tools/quot.h
  } du_t;
  
  #define	NDU	60000
+Index: quota-tools/rquota_server.c
+===================================================================
+--- quota-tools.orig/rquota_server.c
++++ quota-tools/rquota_server.c
+@@ -60,7 +60,7 @@ extern char nfs_pseudoroot[PATH_MAX];
+  */
+ extern struct authunix_parms *unix_cred;
+ 
+-int in_group(gid_t * gids, u_int len, gid_t gid)
++int in_group(gid_t * gids, uint32_t len, gid_t gid)
+ {
+ 	gid_t *gidsp = gids + len;
+ 
meta/recipes-extended/quota/quota_4.02.bb +1 -1
index 124b0a3..673d584 100644
@@ -23,7 +23,7 @@ DEPENDS = "gettext-native e2fsprogs"
 
 inherit autotools-brokensep gettext pkgconfig
 
-CFLAGS += "-I=${includedir}/tirpc"
+CFLAGS += "-I${STAGING_INCDIR}/tirpc"
 LDFLAGS += "-ltirpc"
 ASNEEDED = ""
 EXTRA_OEMAKE += 'STRIP=""'
Signature · 1 line
2.5.2
author
#13 lore raw

PATCH 10/12 connman: Fix build with musl

In reply to Khem Raj
---
 meta/recipes-connectivity/connman/connman.inc      |  1 +
 ...acktrace-API-availability-before-using-it.patch | 55 ++++++++++++++
 ...resolve-musl-does-not-implement-res_ninit.patch | 77 ++++++++++++++++++++
 .../0003-Fix-header-inclusions-for-musl.patch      | 85 ++++++++++++++++++++++
 meta/recipes-connectivity/connman/connman_1.30.bb  |  3 +
 5 files changed, 221 insertions(+)
 create mode 100644 meta/recipes-connectivity/connman/connman/0001-Detect-backtrace-API-availability-before-using-it.patch
 create mode 100644 meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch
 create mode 100644 meta/recipes-connectivity/connman/connman/0003-Fix-header-inclusions-for-musl.patch
meta/recipes-connectivity/connman/connman.inc +1 -0
index 17dc4b9..fd9640e 100644
@@ -30,6 +30,7 @@ EXTRA_OECONF += "\
     --disable-polkit \
     --enable-client \
 "
+CFLAGS += "-D_GNU_SOURCE"
 
 PACKAGECONFIG ??= "wispr \
                    ${@bb.utils.contains('DISTRO_FEATURES', 'systemd','systemd', '', d)} \
meta/recipes-connectivity/connman/connman/0001-Detect-backtrace-API-availability-before-using-it.patch new file +55 -0

55 lines not on this page · raw message

meta/recipes-connectivity/connman/connman/0002-resolve-musl-does-not-implement-res_ninit.patch new file +77 -0

77 lines not on this page · raw message

meta/recipes-connectivity/connman/connman/0003-Fix-header-inclusions-for-musl.patch new file +85 -0

85 lines not on this page · raw message

meta/recipes-connectivity/connman/connman_1.30.bb +3 -0
index 8c47353..9b512c5 100644
@@ -3,6 +3,9 @@ require connman.inc
 SRC_URI  = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \
             file://0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch \
             file://add_xuser_dbus_permission.patch \
+            file://0001-Detect-backtrace-API-availability-before-using-it.patch \
+            file://0002-resolve-musl-does-not-implement-res_ninit.patch \
+            file://0003-Fix-header-inclusions-for-musl.patch \
             file://connman \
             "
 SRC_URI[md5sum] = "4a3efdbd6796922db9c6f66da57887fa"
Signature · 1 line
2.5.2
author
#14 lore raw

PATCH 11/12 waffle: upgrade waffle_1.5.1.bb -> waffle_1.5.2.bb

In reply to Khem Raj

Backport needed patches for compilation fixes on musl

---
 ...-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch | 54 ++++++++++++++++++++++
 .../waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb}    |  8 ++--
 2 files changed, 59 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-graphics/waffle/waffle/0001-third_party-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch
 rename meta/recipes-graphics/waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb} (84%)
meta/recipes-graphics/waffle/waffle/0001-third_party-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch new file +54 -0
new file mode 100644
index 0000000..a0c826e
@@ -0,0 +1,54 @@
+From 3b9b8f5f6d1b99af43e95ec0868404e552a85b73 Mon Sep 17 00:00:00 2001
+From: Emil Velikov <[email protected]>
+Date: Thu, 19 Mar 2015 22:26:11 +0000
+Subject: [PATCH] third_party/threads: Use PTHREAD_MUTEX_RECURSIVE by default
+
+PTHREAD_MUTEX_RECURSIVE_NP was used for compatibility with old glibc.
+Although due to the_GNU_SOURCES define the portable,
+PTHREAD_MUTEX_RECURSIVE will be available for Linuxes since at least
+1998. Simplify things giving us compatibility with musl which
+apparently does not provide the non-portable define.
+
+Inspired by almost identical commit in mesa aead7fe2e2b(c11/threads: Use
+PTHREAD_MUTEX_RECURSIVE by default) by Felix Janda.
+
+Signed-off-by: Emil Velikov <[email protected]>
+Reviewed-by: Chad Versace <[email protected]>
+---
+Upstream-Status: Backport
+
+ third_party/threads/threads_posix.c | 10 ++++------
+ 1 file changed, 4 insertions(+), 6 deletions(-)
+
+diff --git a/third_party/threads/threads_posix.c b/third_party/threads/threads_posix.c
+index 5835e43..e122bf9 100644
+--- a/third_party/threads/threads_posix.c
++++ b/third_party/threads/threads_posix.c
+@@ -26,6 +26,9 @@
+  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+  * DEALINGS IN THE SOFTWARE.
+  */
++
++#define _GNU_SOURCE
++
+ #include <stdlib.h>
+ #ifndef assert
+ #include <assert.h>
+@@ -150,13 +153,8 @@ int mtx_init(mtx_t *mtx, int type)
+       && type != (mtx_try|mtx_recursive))
+         return thrd_error;
+     pthread_mutexattr_init(&attr);
+-    if ((type & mtx_recursive) != 0) {
+-#if defined(__linux__) || defined(__linux)
+-        pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP);
+-#else
++    if ((type & mtx_recursive) != 0)
+         pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE);
+-#endif
+-    }
+     pthread_mutex_init(mtx, &attr);
+     pthread_mutexattr_destroy(&attr);
+     return thrd_success;
+-- 
+2.5.2
+
meta/recipes-graphics/waffle/waffle_1.5.2.bb renamed from meta/recipes-graphics/waffle/waffle_1.5.1.bb +5 -3
similarity index 84%
rename from meta/recipes-graphics/waffle/waffle_1.5.1.bb
rename to meta/recipes-graphics/waffle/waffle_1.5.2.bb
index b8aa05a..6923f1c 100644
@@ -3,9 +3,11 @@ LICENSE = "BSD-2-Clause"
 LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=4c5154407c2490750dd461c50ad94797 \
                     file://include/waffle/waffle.h;endline=24;md5=61dbf8697f61c78645e75a93c585b1bf"
 
-SRC_URI = "http://waffle-gl.org/files/release/${BPN}-${PV}/${BPN}-${PV}.tar.xz"
-SRC_URI[md5sum] = "c0d802bc3d0aba87c51e423a3a8bdd69"
-SRC_URI[sha256sum] = "cbab0e926515064e818bf089a5af04be33307e5f40d07659fb40d59b2bfe20aa"
+SRC_URI = "http://waffle-gl.org/files/release/${BPN}-${PV}/${BPN}-${PV}.tar.xz \
+           file://0001-third_party-threads-Use-PTHREAD_MUTEX_RECURSIVE-by-d.patch \
+          "
+SRC_URI[md5sum] = "c669c91bf2f7e13a5d781c3dbb30fd8c"
+SRC_URI[sha256sum] = "d2c096cf654bf0061323a4b9231a1ef5b749a1e5c7c5bfe067e964219c2a851c"
 
 inherit cmake distro_features_check lib_package
 
Signature · 1 line
2.5.2
#15 lore raw

Re: [PATCH 11/12] waffle: upgrade waffle_1.5.1.bb -> waffle_1.5.2.bb

Hi Khem,

Quoted 2 lines · Khem Raj
 .../waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb}    |  8 ++--

Sorry but you missed the M3 build, can you backport the fixes to 1.5.1 instead?

Ross

author
#16 lore raw

Re: [PATCH 11/12] waffle: upgrade waffle_1.5.1.bb -> waffle_1.5.2.bb

Quoted 10 lines · Ross

Hi Khem,

Quoted 2 lines · Khem Raj
 .../waffle/{waffle_1.5.1.bb => waffle_1.5.2.bb}    |  8 ++--

Sorry but you missed the M3 build, can you backport the fixes to 1.5.1 instead?

OK, ignore this one for now then I will queue the new fix with next lot which is all about fixes and no upgrades

author
#17 lore raw

PATCH 12/12 sysstat: Include needed headers explicitly

In reply to Khem Raj

It depends on defines from .h files that are not includes as part of source file, on glibc it works because they get included indirectly but that can change any time since its internal glibc behaviour, at user level the header needed should be explicitly included.

---
 .../0001-Include-needed-headers-explicitly.patch   | 62 ++++++++++++++++++++++
 meta/recipes-extended/sysstat/sysstat_11.1.5.bb    |  2 +
 2 files changed, 64 insertions(+)
 create mode 100644 meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch
meta/recipes-extended/sysstat/sysstat/0001-Include-needed-headers-explicitly.patch new file +62 -0
new file mode 100644
index 0000000..c126523
@@ -0,0 +1,62 @@
+From 42325faa88d64cce799977d611b2792beb154643 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Mon, 14 Sep 2015 08:36:59 +0000
+Subject: [PATCH] Include needed headers explicitly
+
+on glibc these headers get pulled in indirectly via other .h files
+but right fix is to include them directly when used
+
+fixes
+
+error: use of undeclared identifier 'PATH_MAX'
+error: called object type 'unsigned int' is not a function or function pointer
+dm_major = major(aux.st_rdev);
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+Upstream-Status: Pending
+
+ common.c    | 1 +
+ ioconf.c    | 1 +
+ sa_common.c | 1 +
+ 3 files changed, 3 insertions(+)
+
+diff --git a/common.c b/common.c
+index a23155b..ad86446 100644
+--- a/common.c
++++ b/common.c
+@@ -20,6 +20,7 @@
+  */
+ 
+ #include <stdio.h>
++#include <limits.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <time.h>
+diff --git a/ioconf.c b/ioconf.c
+index 7d88c5d..6d67691 100644
+--- a/ioconf.c
++++ b/ioconf.c
+@@ -27,6 +27,7 @@
+ #include <errno.h>
+ #include <dirent.h>
+ #include <sys/stat.h>
++#include <sys/types.h>
+ 
+ #include "ioconf.h"
+ #include "common.h"
+diff --git a/sa_common.c b/sa_common.c
+index b7351d9..c9e3299 100644
+--- a/sa_common.c
++++ b/sa_common.c
+@@ -20,6 +20,7 @@
+  */
+ 
+ #include <stdio.h>
++#include <limits.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <time.h>
+-- 
+2.5.2
+
meta/recipes-extended/sysstat/sysstat_11.1.5.bb +2 -0
index 69d2ec2..bff8616 100644
@@ -2,6 +2,8 @@ require sysstat.inc
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
 
+SRC_URI += "file://0001-Include-needed-headers-explicitly.patch"
+
 SRC_URI[md5sum] = "4d8e6e72d057189a1660462a678d9ada"
 SRC_URI[sha256sum] = "feb3a90d86ffd69cf5b88144a8876ae05bd42384f559676f08100671589fa2bb"
 
Signature · 1 line
2.5.2