On Mon, 2014-09-15 at 10:21 +0100, Daniel P. Berrange wrote:
On Sun, Sep 14, 2014 at 06:35:19PM +0100, Ian Campbell wrote:
> On Wed, 2014-09-10 at 12:20 +0200, Michal Privoznik wrote:
> >
> > +/*
> > + * Workaround older glibc. While kernel may support the setns
> > + * syscall, the glibc wrapper might not exist. If that's the
> > + * case, use our own.
> > + */
> > +#ifndef __NR_setns
> > +# if defined(__x86_64__)
> > +# define __NR_setns 308
> > +# elif defined(__i386__)
> > +# define __NR_setns 346
> > +# else
> > +# error "__NR_setns is not defined"
> > +# endif
> > +#endif
>
> Xen's automated build tests of libvirt have just failed with this when
> building for armhf:
> util/virprocess.c:75:4: error: #error "__NR_setns is not
> defined"
>
> is this another aspect of the "out of date glibc" issue?
IIUC, the syscalls numbers come from the kernel headers, while the syscall
API comes from glibc.
Makes sense.
Either way, we should not have left this as a fatal
#error. I'll dig up the required constants for all other architectures we
care about.
Thanks!
Ian.