aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2021-02-15 19:58:54 +0100
committerFelix Fietkau <nbd@nbd.name>2021-02-15 19:58:54 +0100
commit1da945b7602322142fc9a2d70edaf5592743bd6d (patch)
tree3d6d29fb0267f996a6e72ca51b774d3ddeba3c4c /tools
parent8edb1797d55d259c6eda18c89784f152328436fc (diff)
downloadupstream-1da945b7602322142fc9a2d70edaf5592743bd6d.tar.gz
upstream-1da945b7602322142fc9a2d70edaf5592743bd6d.tar.bz2
upstream-1da945b7602322142fc9a2d70edaf5592743bd6d.zip
tools/fakeroot: fix build regression on macOS
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'tools')
-rw-r--r--tools/fakeroot/patches/301-glibc-2.33-compat-fixes.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/tools/fakeroot/patches/301-glibc-2.33-compat-fixes.patch b/tools/fakeroot/patches/301-glibc-2.33-compat-fixes.patch
new file mode 100644
index 0000000000..0b91d65edb
--- /dev/null
+++ b/tools/fakeroot/patches/301-glibc-2.33-compat-fixes.patch
@@ -0,0 +1,42 @@
+--- a/libfakeroot.c
++++ b/libfakeroot.c
+@@ -1368,7 +1368,8 @@ int renameat(int olddir_fd, const char *
+ #endif /* HAVE_FSTATAT */
+
+
+-#if defined(__GLIBC__) && __GLIBC_PREREQ(2,33)
++#if defined(__GLIBC__)
++#if __GLIBC_PREREQ(2,33)
+ /* Glibc 2.33 exports symbols for these functions in the shared lib */
+ int lstat(const char *file_name, struct stat *statbuf) {
+ return WRAP_LSTAT LSTAT_ARG(_STAT_VER, file_name, statbuf);
+@@ -1413,6 +1414,7 @@ int renameat(int olddir_fd, const char *
+ return WRAP_MKNODAT MKNODAT_ARG(_STAT_VER, dir_fd, pathname, mode, &dev);
+ }
+ #endif
++#endif /* __GLIBC__ */
+ #endif /* GLIBC_PREREQ */
+
+
+--- a/configure.ac
++++ b/configure.ac
+@@ -182,6 +182,9 @@ AC_MSG_CHECKING([for type of arg of __xm
+ #include <fcntl.h>
+ #include <unistd.h>
+ ]], [[
++#ifndef __GLIBC__
++#error no extra *
++#endif
+ int __xmknod ( int ver,
+ const char *pathname ,
+ mode_t mode , dev_t *dev);
+@@ -208,6 +211,9 @@ AC_MSG_CHECKING([for type of arg of __xm
+ #include <fcntl.h>
+ #include <unistd.h>
+ ]], [[
++#ifndef __GLIBC__
++#error no extra *
++#endif
+ int __xmknodat ( int ver,
+ int dirfd,
+ const char *pathname ,