Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 7e1eabe

Browse filesBrowse files
committed
libhybris: fix build with glibc-2.26
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
1 parent 9eba7dd commit 7e1eabe
Copy full SHA for 7e1eabe

File tree

Expand file treeCollapse file tree

2 files changed

+51
-1
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

2 files changed

+51
-1
lines changed
Open diff view settings
Collapse file
+47Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
From 283b4bf1621542d2fe14e8492b7578bf9c083418 Mon Sep 17 00:00:00 2001
2+
From: Martin Jansa <Martin.Jansa@gmail.com>
3+
Date: Fri, 25 Aug 2017 13:06:50 +0200
4+
Subject: [PATCH] hooks.c: Fix build with glibc-2.26
5+
6+
* add missing sys/uio.h include for writev
7+
* replace cfree with free as the cfree man says:
8+
This function should never be used. Use free(3) instead.
9+
Starting with version 2.26, it has been removed from glibc.
10+
* fixes:
11+
hooks.c: At top level:
12+
hooks.c:2428:26: error: 'cfree' undeclared here (not in a function); did you mean 'free'?
13+
HOOK_DIRECT_NO_DEBUG(cfree),
14+
^
15+
hooks.c:2675:26: error: 'writev' undeclared here (not in a function); did you mean 'write'?
16+
HOOK_DIRECT_NO_DEBUG(writev),
17+
^
18+
19+
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
20+
---
21+
hybris/common/hooks.c | 3 ++-
22+
1 file changed, 2 insertions(+), 1 deletion(-)
23+
24+
diff --git a/hybris/common/hooks.c b/hybris/common/hooks.c
25+
index 8a9cb2a..8c0f4d2 100644
26+
--- a/hybris/common/hooks.c
27+
+++ b/hybris/common/hooks.c
28+
@@ -64,6 +64,7 @@
29+
#include <sys/syscall.h>
30+
#include <sys/auxv.h>
31+
#include <sys/prctl.h>
32+
+#include <sys/uio.h>
33+
34+
#include <sys/mman.h>
35+
#include <libgen.h>
36+
@@ -2425,7 +2426,7 @@ static struct _hook hooks_common[] = {
37+
HOOK_DIRECT(malloc),
38+
HOOK_DIRECT_NO_DEBUG(free),
39+
HOOK_DIRECT_NO_DEBUG(calloc),
40+
- HOOK_DIRECT_NO_DEBUG(cfree),
41+
+ HOOK_DIRECT_NO_DEBUG(free),
42+
HOOK_DIRECT_NO_DEBUG(realloc),
43+
HOOK_DIRECT_NO_DEBUG(memalign),
44+
HOOK_DIRECT_NO_DEBUG(valloc),
45+
--
46+
2.14.1
47+
Collapse file

‎meta-android/recipes-core/libhybris/libhybris_git.bb‎

Copy file name to clipboardExpand all lines: meta-android/recipes-core/libhybris/libhybris_git.bb
+4-1Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,10 @@ PV = "0.1.0+gitr${SRCPV}"
88
PR = "r1"
99
PE = "1"
1010

11-
SRC_URI = "git://github.com/libhybris/libhybris;branch=master;protocol=git"
11+
SRC_URI = "git://github.com/libhybris/libhybris \
12+
file://0001-hooks.c-Fix-build-with-glibc-2.26.patch;patchdir=.. \
13+
"
14+
1215
S = "${WORKDIR}/git/hybris"
1316

1417
PACKAGE_ARCH = "${MACHINE_ARCH}"

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.