Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 408696 Details for
Bug 557070
=sys-apps/toybox-0.6.0 fails to build on uclibc/x86: nsenter.c:(.text.unshare_main+0x131): undefined reference to `setns'
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
toybox-0.6.0-add-setns-for-uclibc.patch
toybox-0.6.0-add-setns-for-uclibc.patch (text/plain), 897 bytes, created by
Andrew Miller
on 2015-08-10 04:32:30 UTC
(
hide
)
Description:
toybox-0.6.0-add-setns-for-uclibc.patch
Filename:
MIME Type:
Creator:
Andrew Miller
Created:
2015-08-10 04:32:30 UTC
Size:
897 bytes
patch
obsolete
>Upstream uses a patched version of uClibc,[1] Gentoo does not, >so we need to add the setns() system call. > >Patch by Andrew Miller, fixes bug #557070. > >[1] http://landley.net/hg/aboriginal/file/3ffb288cc713/sources/patches/uClibc-setns.patch > >--- lib/portability.h >+++ lib/portability.h >@@ -90,10 +90,23 @@ > char *stpcpy(char *dest, const char *src); > pid_t getsid(pid_t pid); > >+#ifndef HAVE_SETNS >+#include <sys/syscall.h> >+static inline int setns(int fd, int nstype) >+{ >+#ifdef __NR_setns >+ return syscall(__NR_setns, fd, nstype); >+#elif defined(__NR_set_ns) >+ return syscall(__NR_set_ns, fd, nstype); >+#else >+ return -1; >+#endif >+} >+#endif >+ > // uClibc's last-ever release was in 2012, so of course it doesn't define > // any flag newer than MS_MOVE, which was added in 2001 (linux 2.5.0.5), > // eleven years earlier. >- > #include <sys/mount.h> > #ifndef MS_MOVE > #define MS_MOVE (1<<13)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 557070
:
408568
| 408696