aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorRuslan Isaev <legale.legale@gmail.com>2021-05-10 14:56:59 +0000
committerHauke Mehrtens <hauke@hauke-m.de>2021-05-23 15:11:19 +0200
commit7a70f78fb7da4dc3e8c58e7662f4dc623274a78b (patch)
tree159b1f0b26c620ad9005ba08a66c206a0063b770 /tools
parent7efc0d4d062e2b890b7daa6b30aa3a5e1754aaf5 (diff)
downloadupstream-7a70f78fb7da4dc3e8c58e7662f4dc623274a78b.tar.gz
upstream-7a70f78fb7da4dc3e8c58e7662f4dc623274a78b.tar.bz2
upstream-7a70f78fb7da4dc3e8c58e7662f4dc623274a78b.zip
fakeroot: Alpine linux libc.musl build error fix
Prevent build error on Alpine Linux host: libfakeroot.c error: conflicting types for 'id_t' Error relocating openwrt/staging_dir/host/lib/libfakeroot.so: SEND_GET_XATTR: symbol not found Signed-off-by: Ruslan Isaev <legale.legale@gmail.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/fakeroot/patches/400-alpine-libc.musl-fix.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/tools/fakeroot/patches/400-alpine-libc.musl-fix.patch b/tools/fakeroot/patches/400-alpine-libc.musl-fix.patch
new file mode 100644
index 0000000000..619b092ca9
--- /dev/null
+++ b/tools/fakeroot/patches/400-alpine-libc.musl-fix.patch
@@ -0,0 +1,34 @@
+Alpine linux libc.musl build error fix
+
+Prevent build error on Alpine Linux host:
+libfakeroot.c error: conflicting types for 'id_t'
+Error relocating openwrt/staging_dir/host/lib/libfakeroot.so: SEND_GET_XATTR: symbol not found
+
+--- a/libfakeroot.c
++++ b/libfakeroot.c
+@@ -81,12 +81,14 @@
+ #define SEND_STAT64(a,b,c) send_stat64(a,b,c)
+ #define SEND_GET_STAT(a,b) send_get_stat(a,b)
+ #define SEND_GET_STAT64(a,b) send_get_stat64(a,b)
++#define SEND_GET_XATTR(a,b,c) send_get_xattr(a,b,c)
+ #define SEND_GET_XATTR64(a,b,c) send_get_xattr64(a,b,c)
+ #else
+ #define SEND_STAT(a,b,c) send_stat(a,b)
+ #define SEND_STAT64(a,b,c) send_stat64(a,b)
+ #define SEND_GET_STAT(a,b) send_get_stat(a)
+ #define SEND_GET_STAT64(a,b) send_get_stat64(a)
++#define SEND_GET_XATTR(a,b,c) send_get_xattr(a,b)
+ #define SEND_GET_XATTR64(a,b,c) send_get_xattr64(a,b)
+ #endif
+
+@@ -125,8 +127,9 @@
+
+ /* 10.10 uses id_t in getpriority/setpriority calls, so pretend
+ id_t is used everywhere, just happens to be int on some OSes */
+-#ifndef _ID_T
++#if !defined(_ID_T) && !defined(__DEFINED_id_t)
+ #define _ID_T
++#define __DEFINED_id_t
+ typedef int id_t;
+ #endif
+ #endif