Message ID | 1366181614-19837-1-git-send-email-jengelh@inai.de |
---|---|
State | Rejected, archived |
Delegated to: | stephen hemminger |
Headers | show |
On Wed, 17 Apr 2013 08:53:34 +0200 Jan Engelhardt <jengelh@inai.de> wrote: > I get a compilation error with linux-glibc-devel-2.6.32 (SLES 11 SP2): > > ipnetns.c: In function 'netns_exec': > ipnetns.c:156: error: 'MS_SLAVE' undeclared (first use in this function) > ipnetns.c:156: error: (Each undeclared identifier is reported only once > ipnetns.c:156: error: for each function it appears in.) > ipnetns.c:156: error: 'MS_REC' undeclared (first use in this function) > ipnetns.c: In function 'netns_add': > ipnetns.c:372: error: 'MS_SHARED' undeclared (first use in this function) > ipnetns.c:372: error: 'MS_REC' undeclared (first use in this function) > make[1]: *** [ipnetns.o] Error 1 > > This patch fixes that. > --- > ip/ipnetns.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/ip/ipnetns.c b/ip/ipnetns.c > index b047b97..48b1ad5 100644 > --- a/ip/ipnetns.c > +++ b/ip/ipnetns.c > @@ -14,6 +14,7 @@ > #include <errno.h> > #include <unistd.h> > #include <ctype.h> > +#include <linux/fs.h> > > #include "utils.h" > #include "ip_common.h" Including linux/fs.h is the wrong answer and there is no guarantee that the installed kernel headers are up to date on the build machine either. The flags are supposed to be in <sys/mount.h> to work around the missing values, some manual ifdef's were added yesterday. Rejected. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/ip/ipnetns.c b/ip/ipnetns.c index b047b97..48b1ad5 100644 --- a/ip/ipnetns.c +++ b/ip/ipnetns.c @@ -14,6 +14,7 @@ #include <errno.h> #include <unistd.h> #include <ctype.h> +#include <linux/fs.h> #include "utils.h" #include "ip_common.h"