[lxc-devel] [PATCH] define some macros to fix the build

Tycho Andersen tycho.andersen at canonical.com
Fri Jan 30 14:53:53 UTC 2015


Not all kernels have these macros; they'll just give an EINVAL if/when invoked.

Signed-off-by: Tycho Andersen <tycho.andersen at canonical.com>
---
 src/lxc/utils.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/src/lxc/utils.c b/src/lxc/utils.c
index 9acf7e6..f9533db 100644
--- a/src/lxc/utils.c
+++ b/src/lxc/utils.c
@@ -46,6 +46,22 @@
 #include "lxclock.h"
 #include "namespace.h"
 
+#ifndef PR_SET_MM_ARG_START
+#define PR_SET_MM_ARG_START 8
+#endif
+
+#ifndef PR_SET_MM_ARG_END
+#define PR_SET_MM_ARG_END 9
+#endif
+
+#ifndef PR_SET_MM_ENV_START
+#define PR_SET_MM_ENV_START 10
+#endif
+
+#ifndef PR_SET_MM_ENV_END
+#define PR_SET_MM_ENV_END 11
+#endif
+
 lxc_log_define(lxc_utils, lxc);
 
 static int _recursive_rmdir_onedev(char *dirname, dev_t pdev,
-- 
2.1.0



More information about the lxc-devel mailing list