From 7d858dd1d15792a56d4b1ab6eb72361d122f3b98 Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Mon, 3 Jul 2017 03:46:00 +0200 Subject: compat: support OpenSUSE's backports --- src/compat/compat.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/compat/compat.h') diff --git a/src/compat/compat.h b/src/compat/compat.h index 562c050..539b4bf 100644 --- a/src/compat/compat.h +++ b/src/compat/compat.h @@ -18,6 +18,11 @@ #define ISUBUNTU1404 #endif #endif +#ifdef CONFIG_SUSE_KERNEL +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 5, 0) && LINUX_VERSION_CODE >= KERNEL_VERSION(4, 4, 0) +#define ISOPENSUSE42 +#endif +#endif #if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0) #error "WireGuard requires Linux >= 3.10" @@ -88,7 +93,7 @@ static const struct ipv6_stub_type *ipv6_stub = &ipv6_stub_impl; #endif -#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0) && IS_ENABLED(CONFIG_IPV6) +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 8, 0) && IS_ENABLED(CONFIG_IPV6) && !defined(ISOPENSUSE42) #include static inline bool ipv6_mod_enabled(void) { -- cgit v1.2.3-59-g8ed1b