summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/recipes-kernel/kmod/kmod-native_git.bb5
-rw-r--r--meta/recipes-kernel/kmod/kmod.inc9
-rw-r--r--meta/recipes-kernel/kmod/kmod/0001-Fix-build-with-older-gcc-4.6.patch44
-rw-r--r--meta/recipes-kernel/kmod/kmod/0001-man-disable-man-page-generation-because-we-don-t-hav.patch26
-rw-r--r--meta/recipes-kernel/kmod/kmod/fix-undefined-O_CLOEXEC.patch16
-rw-r--r--meta/recipes-kernel/kmod/kmod_git.bb3
6 files changed, 60 insertions, 43 deletions
diff --git a/meta/recipes-kernel/kmod/kmod-native_git.bb b/meta/recipes-kernel/kmod/kmod-native_git.bb
index 8cbcdf8ad7..f22efc0615 100644
--- a/meta/recipes-kernel/kmod/kmod-native_git.bb
+++ b/meta/recipes-kernel/kmod/kmod-native_git.bb
@@ -4,8 +4,9 @@
4require kmod.inc 4require kmod.inc
5inherit native 5inherit native
6 6
7PR = "${INC_PR}.1" 7SRC_URI += "file://fix-undefined-O_CLOEXEC.patch \
8SRC_URI += "file://fix-undefined-O_CLOEXEC.patch" 8 file://0001-Fix-build-with-older-gcc-4.6.patch \
9 "
9 10
10do_install_append (){ 11do_install_append (){
11 for tool in depmod insmod lsmod modinfo modprobe rmmod 12 for tool in depmod insmod lsmod modinfo modprobe rmmod
diff --git a/meta/recipes-kernel/kmod/kmod.inc b/meta/recipes-kernel/kmod/kmod.inc
index a780b6c15f..1728a4e080 100644
--- a/meta/recipes-kernel/kmod/kmod.inc
+++ b/meta/recipes-kernel/kmod/kmod.inc
@@ -7,8 +7,6 @@ HOMEPAGE = "http://packages.profusion.mobi/kmod/"
7LICENSE = "GPL-2.0+ & LGPL-2.1+" 7LICENSE = "GPL-2.0+ & LGPL-2.1+"
8LICENSE_libkmod = "LGPL-2.1+" 8LICENSE_libkmod = "LGPL-2.1+"
9SECTION = "base" 9SECTION = "base"
10PV = "9"
11INC_PR = "r0"
12 10
13DEPENDS += "pkgconfig-native" 11DEPENDS += "pkgconfig-native"
14 12
@@ -19,17 +17,18 @@ inherit autotools gtk-doc ptest
19 17
20SRC_URI = "git://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git \ 18SRC_URI = "git://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git \
21 file://depmod-search.conf \ 19 file://depmod-search.conf \
22 file://0001-man-disable-man-page-generation-because-we-don-t-hav.patch \
23 file://run-ptest \ 20 file://run-ptest \
24 file://ptest.patch \ 21 file://ptest.patch \
25 " 22 "
26 23
27SRCREV = "62081c0f68905b22f375156d4532fd37fa5c8d33" 24SRCREV = "3b38c7fcb58be4ddc34f90454c5f5dc3693d2d85"
25# Lookout for PV bump too when SRCREV is changed
26PV = "14"
28 27
29S = "${WORKDIR}/git" 28S = "${WORKDIR}/git"
30 29
31EXTRA_AUTORECONF += "--install --symlink" 30EXTRA_AUTORECONF += "--install --symlink"
32EXTRA_OECONF +="--enable-debug --enable-logging --enable-tools" 31EXTRA_OECONF +="--enable-debug --enable-logging --enable-tools --disable-manpages"
33 32
34do_configure_prepend () { 33do_configure_prepend () {
35 gtkdocize --docdir ${S}/libkmod/docs || touch ${S}/libkmod/docs/gtk-doc.make 34 gtkdocize --docdir ${S}/libkmod/docs || touch ${S}/libkmod/docs/gtk-doc.make
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 @@
1Upstream-Status: Inappropriate [kmod is new]
2
3From 30e1839a46b0b9449f272765193a0da61bf85997 Mon Sep 17 00:00:00 2001
4From: Khem Raj <raj.khem@gmail.com>
5Date: Mon, 26 Aug 2013 15:32:36 -0700
6Subject: [PATCH] Fix build with older gcc < 4.6
7
8Static_assert is new feature in C11 standards and older than gcc 4.6
9does not support it. So define it to make the old gcc happy
10
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12---
13 libkmod/macro.h | 14 ++++++++++++--
14 1 file changed, 12 insertions(+), 2 deletions(-)
15
16diff --git a/libkmod/macro.h b/libkmod/macro.h
17index c6ba855..5032f54 100644
18--- a/libkmod/macro.h
19+++ b/libkmod/macro.h
20@@ -20,9 +20,19 @@
21 #pragma once
22
23 #include <stddef.h>
24-
25-#define assert_cc(expr) \
26+#if defined(__GNUC__)
27+/* Determine which version of GNU C we're using */
28+#define GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__)
29+#endif
30+#if (GCC_VERSION >= 40600)
31+# define assert_cc(expr) \
32 _Static_assert((expr), #expr)
33+#else
34+# define STATIC_ASSERT_GLUE1(x, y) x##y
35+# define STATIC_ASSERT_GLUE(x, y) STATIC_ASSERT_GLUE1(x, y)
36+# define assert_cc(expr) \
37+extern void STATIC_ASSERT_GLUE(static_assert, __LINE__)(int arg[(expr) ? 1 : -1]) __attribute__((unused))
38+#endif
39
40 #if HAVE_TYPEOF
41 #define check_types_match(expr1, expr2) \
42--
431.8.3.4
44
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 @@
1From ce6f0cabb65e67dd4d31e1e555db8bc6eaf435d3 Mon Sep 17 00:00:00 2001
2From: Martin Jansa <Martin.Jansa@gmail.com>
3Date: Fri, 24 Feb 2012 07:35:38 +0100
4Subject: [PATCH] man: disable man page generation because we don't have
5 working xsltproc
6
7Upstream-Status: Inappropriate [build system specific change]
8
9Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
10---
11 Makefile.am | 2 +-
12 1 files changed, 1 insertions(+), 1 deletions(-)
13
14diff --git a/Makefile.am b/Makefile.am
15index 141c102..a8bdfd1 100644
16--- a/Makefile.am
17+++ b/Makefile.am
18@@ -1,4 +1,4 @@
19-SUBDIRS = . libkmod/docs man
20+SUBDIRS = . libkmod/docs
21
22 DISTCLEAN_LOCAL_HOOKS =
23 EXTRA_DIST =
24--
251.7.8.4
26
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
2 2
3Index: git/libkmod/libkmod-private.h 3Index: git/libkmod/libkmod-private.h
4=================================================================== 4===================================================================
5--- git.orig/libkmod/libkmod-private.h 5--- git.orig/libkmod/libkmod-private.h 2013-08-21 10:07:51.000000000 -0700
6+++ git/libkmod/libkmod-private.h 6+++ git/libkmod/libkmod-private.h 2013-08-21 14:34:04.558278849 -0700
7@@ -1,6 +1,10 @@ 7@@ -9,6 +9,10 @@
8 #ifndef _LIBKMOD_PRIVATE_H_ 8 #include "macro.h"
9 #define _LIBKMOD_PRIVATE_H_ 9 #include "libkmod.h"
10 10
11+#ifndef O_CLOEXEC 11+#ifndef O_CLOEXEC
12+# define O_CLOEXEC 0 12+# define O_CLOEXEC 0
13+#endif 13+#endif
14+ 14+
15 #include <stdbool.h> 15 static _always_inline_ _printf_format_(2, 3) void
16 #include <stdio.h> 16 kmod_log_null(struct kmod_ctx *ctx, const char *format, ...) {}
17 #include <syslog.h> 17
diff --git a/meta/recipes-kernel/kmod/kmod_git.bb b/meta/recipes-kernel/kmod/kmod_git.bb
index f92ff72904..b07c06e7b4 100644
--- a/meta/recipes-kernel/kmod/kmod_git.bb
+++ b/meta/recipes-kernel/kmod/kmod_git.bb
@@ -3,8 +3,7 @@
3 3
4require kmod.inc 4require kmod.inc
5 5
6PR = "${INC_PR}.0" 6PV_append = "+git${SRCPV}"
7PV = "9+git${SRCPV}"
8 7
9PROVIDES += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools" 8PROVIDES += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools"
10RPROVIDES_${PN} += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools" 9RPROVIDES_${PN} += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools"