diff options
Diffstat (limited to 'meta/recipes-kernel/kmod/kmod')
3 files changed, 52 insertions, 34 deletions
diff --git a/meta/recipes-kernel/kmod/kmod/0001-Fix-build-with-older-gcc-4.6.patch b/meta/recipes-kernel/kmod/kmod/0001-Fix-build-with-older-gcc-4.6.patch new file mode 100644 index 0000000000..f8ff103087 --- /dev/null +++ b/meta/recipes-kernel/kmod/kmod/0001-Fix-build-with-older-gcc-4.6.patch @@ -0,0 +1,44 @@ +Upstream-Status: Inappropriate [kmod is new] + +From 30e1839a46b0b9449f272765193a0da61bf85997 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Mon, 26 Aug 2013 15:32:36 -0700 +Subject: [PATCH] Fix build with older gcc < 4.6 + +Static_assert is new feature in C11 standards and older than gcc 4.6 +does not support it. So define it to make the old gcc happy + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + libkmod/macro.h | 14 ++++++++++++-- + 1 file changed, 12 insertions(+), 2 deletions(-) + +diff --git a/libkmod/macro.h b/libkmod/macro.h +index c6ba855..5032f54 100644 +--- a/libkmod/macro.h ++++ b/libkmod/macro.h +@@ -20,9 +20,19 @@ + #pragma once + + #include <stddef.h> +- +-#define assert_cc(expr) \ ++#if defined(__GNUC__) ++/* Determine which version of GNU C we're using */ ++#define GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) ++#endif ++#if (GCC_VERSION >= 40600) ++# define assert_cc(expr) \ + _Static_assert((expr), #expr) ++#else ++# define STATIC_ASSERT_GLUE1(x, y) x##y ++# define STATIC_ASSERT_GLUE(x, y) STATIC_ASSERT_GLUE1(x, y) ++# define assert_cc(expr) \ ++extern void STATIC_ASSERT_GLUE(static_assert, __LINE__)(int arg[(expr) ? 1 : -1]) __attribute__((unused)) ++#endif + + #if HAVE_TYPEOF + #define check_types_match(expr1, expr2) \ +-- +1.8.3.4 + diff --git a/meta/recipes-kernel/kmod/kmod/0001-man-disable-man-page-generation-because-we-don-t-hav.patch b/meta/recipes-kernel/kmod/kmod/0001-man-disable-man-page-generation-because-we-don-t-hav.patch deleted file mode 100644 index 5361b847c9..0000000000 --- a/meta/recipes-kernel/kmod/kmod/0001-man-disable-man-page-generation-because-we-don-t-hav.patch +++ /dev/null @@ -1,26 +0,0 @@ -From ce6f0cabb65e67dd4d31e1e555db8bc6eaf435d3 Mon Sep 17 00:00:00 2001 -From: Martin Jansa <Martin.Jansa@gmail.com> -Date: Fri, 24 Feb 2012 07:35:38 +0100 -Subject: [PATCH] man: disable man page generation because we don't have - working xsltproc - -Upstream-Status: Inappropriate [build system specific change] - -Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> ---- - Makefile.am | 2 +- - 1 files changed, 1 insertions(+), 1 deletions(-) - -diff --git a/Makefile.am b/Makefile.am -index 141c102..a8bdfd1 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -1,4 +1,4 @@ --SUBDIRS = . libkmod/docs man -+SUBDIRS = . libkmod/docs - - DISTCLEAN_LOCAL_HOOKS = - EXTRA_DIST = --- -1.7.8.4 - diff --git a/meta/recipes-kernel/kmod/kmod/fix-undefined-O_CLOEXEC.patch b/meta/recipes-kernel/kmod/kmod/fix-undefined-O_CLOEXEC.patch index 3177e9a1a9..0268216230 100644 --- a/meta/recipes-kernel/kmod/kmod/fix-undefined-O_CLOEXEC.patch +++ b/meta/recipes-kernel/kmod/kmod/fix-undefined-O_CLOEXEC.patch @@ -2,16 +2,16 @@ Upstream-Status: Not applicable Index: git/libkmod/libkmod-private.h =================================================================== ---- git.orig/libkmod/libkmod-private.h -+++ git/libkmod/libkmod-private.h -@@ -1,6 +1,10 @@ - #ifndef _LIBKMOD_PRIVATE_H_ - #define _LIBKMOD_PRIVATE_H_ +--- git.orig/libkmod/libkmod-private.h 2013-08-21 10:07:51.000000000 -0700 ++++ git/libkmod/libkmod-private.h 2013-08-21 14:34:04.558278849 -0700 +@@ -9,6 +9,10 @@ + #include "macro.h" + #include "libkmod.h" +#ifndef O_CLOEXEC +# define O_CLOEXEC 0 +#endif + - #include <stdbool.h> - #include <stdio.h> - #include <syslog.h> + static _always_inline_ _printf_format_(2, 3) void + kmod_log_null(struct kmod_ctx *ctx, const char *format, ...) {} + |