diff options
author | Khem Raj <raj.khem@gmail.com> | 2015-08-13 15:12:23 +0200 |
---|---|---|
committer | Andrei Gherzan <andrei@gherzan.ro> | 2015-12-09 12:46:54 +0100 |
commit | 2348e267f728b31bdc0d89d47d93570a433de1ae (patch) | |
tree | 61f97096fdb2c532dd2d6da532d749470381d916 | |
parent | d273a90c39a1a81cf173b5fc0e4ffaef306da5e3 (diff) | |
download | meta-raspberrypi-2348e267f728b31bdc0d89d47d93570a433de1ae.tar.gz |
userland: Fix POSIX compliance expectation
We have errors like below with glibc 2.22+
net_sockets_common.c:139:20: error: storage size of 'hints' isn't known
struct addrinfo hints, *info, *p;
^
newer glibc has now fixed the definitions of getaddrinfo and ilk to be
enabled with correct posix version.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
(cherry picked from commit f188f3d756f59fb4dc64cc1a64263c2251f76ae5)
Signed-off-by: Petter Mabäcker <petter@technux.se>
-rw-r--r-- | recipes-graphics/userland/userland/0001-Use-newer-POSIX-macro.patch | 35 | ||||
-rw-r--r-- | recipes-graphics/userland/userland_git.bb | 1 |
2 files changed, 36 insertions, 0 deletions
diff --git a/recipes-graphics/userland/userland/0001-Use-newer-POSIX-macro.patch b/recipes-graphics/userland/userland/0001-Use-newer-POSIX-macro.patch new file mode 100644 index 0000000..2a092c2 --- /dev/null +++ b/recipes-graphics/userland/userland/0001-Use-newer-POSIX-macro.patch | |||
@@ -0,0 +1,35 @@ | |||
1 | From 12f7718bb0e08e2c06825c7ab7541b3c5bfe74c1 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Sun, 9 Aug 2015 08:55:05 -0700 | ||
4 | Subject: [PATCH] Use newer POSIX macro | ||
5 | |||
6 | Define _POSIX_C_SOURCE such that it demands correct | ||
7 | posix interfaces, netdb.h declares interfaces such as | ||
8 | getaddrinfo if __USE_POSIX, i.e. POSIX.1:1990 or later. | ||
9 | However, these interfaces were new in the 2001 edition of POSIX | ||
10 | therefore ask for Extension from POSIX.1:2001 since we use addrinfo | ||
11 | structure here. | ||
12 | |||
13 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
14 | --- | ||
15 | Upstream-Status: Submitted | ||
16 | |||
17 | containers/CMakeLists.txt | 2 +- | ||
18 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
19 | |||
20 | diff --git a/containers/CMakeLists.txt b/containers/CMakeLists.txt | ||
21 | index a29a885..5570038 100644 | ||
22 | --- a/containers/CMakeLists.txt | ||
23 | +++ b/containers/CMakeLists.txt | ||
24 | @@ -13,7 +13,7 @@ add_definitions(-DDL_PATH_PREFIX="${VMCS_PLUGIN_DIR}/") | ||
25 | |||
26 | SET( GCC_COMPILER_FLAGS -Wall -g -O2 -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wcast-qual -Wwrite-strings -Wundef ) | ||
27 | SET( GCC_COMPILER_FLAGS ${GCC_COMPILER_FLAGS} -Wextra )#-Wno-missing-field-initializers ) | ||
28 | -SET( GCC_COMPILER_FLAGS ${GCC_COMPILER_FLAGS} -std=c99 -D_POSIX_C_SOURCE=199309L ) | ||
29 | +SET( GCC_COMPILER_FLAGS ${GCC_COMPILER_FLAGS} -std=c99 -D_POSIX_C_SOURCE=200112L ) | ||
30 | SET( GCC_COMPILER_FLAGS ${GCC_COMPILER_FLAGS} -Wno-missing-field-initializers ) | ||
31 | SET( GCC_COMPILER_FLAGS ${GCC_COMPILER_FLAGS} -Wno-unused-value ) | ||
32 | |||
33 | -- | ||
34 | 2.1.4 | ||
35 | |||
diff --git a/recipes-graphics/userland/userland_git.bb b/recipes-graphics/userland/userland_git.bb index 729c42a..861029d 100644 --- a/recipes-graphics/userland/userland_git.bb +++ b/recipes-graphics/userland/userland_git.bb | |||
@@ -16,6 +16,7 @@ SRCFORK = "raspberrypi" | |||
16 | SRCREV = "3b81b91c18ff19f97033e146a9f3262ca631f0e9" | 16 | SRCREV = "3b81b91c18ff19f97033e146a9f3262ca631f0e9" |
17 | 17 | ||
18 | SRC_URI = "git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \ | 18 | SRC_URI = "git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \ |
19 | file://0001-Use-newer-POSIX-macro.patch \ | ||
19 | " | 20 | " |
20 | S = "${WORKDIR}/git" | 21 | S = "${WORKDIR}/git" |
21 | 22 | ||