[Swan-dev] KLIPS build failure with linux-3.15 and CONFIG_USER_NS=n

Mike Gilbert floppym at gentoo.org
Thu Jul 10 05:51:14 EEST 2014


On Wed, Jul 9, 2014 at 9:58 PM, Mike Gilbert <floppym at gentoo.org> wrote:
> There are a few places in the code that utilize kuid_t and related
> functions if HAVE_USER_NS is defined. In recent linux versions it is
> no longer possible to use uint32_t as a stand-in for kuid_t,
> regardless of user namespace support.
>

This patch seems to resolve the issue. I'm not sure if there is a
better way to check for kuid_t.

diff --git a/linux/include/libreswan/ipsec_kversion.h
b/linux/include/libreswan/ipsec_kversion.h
index 63bb7b7..c1c3d0c 100644
--- a/linux/include/libreswan/ipsec_kversion.h
+++ b/linux/include/libreswan/ipsec_kversion.h
@@ -520,7 +520,7 @@

 /* CONFIG_USER_NS is now on in Fedora 20 kernels */
 #if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0)
-# if defined(CONFIG_USER_NS)
+# if defined(KUIDT_INIT)
 #  define HAVE_USER_NS
 # endif
 #endif


More information about the Swan-dev mailing list