Merge branch 'master' into staging-next

This commit is contained in:
Jan Tojnar
2019-12-03 16:51:48 +01:00
144 changed files with 1463 additions and 927 deletions

View File

@@ -14,7 +14,11 @@ stdenv.mkDerivation {
sed -i 's,/usr/bin/install,${buildPackages.coreutils}/bin/install,' Makefile
'';
makeFlags = [ "CROSS=${stdenv.cc.targetPrefix}" ];
makeFlags = [
"CROSS=${stdenv.cc.targetPrefix}"
"CC=${stdenv.cc.targetPrefix}cc"
"LD=${stdenv.cc.targetPrefix}cc"
];
installFlags = stdenv.lib.mapAttrsToList
(n: v: "${n}dir=${placeholder "out"}/${v}") {

View File

@@ -58,7 +58,7 @@ let
+ '' mkdir -p $out/include/config
echo "${version}-default" > $out/include/config/kernel.release
''
# These oddly named file records teh `SHELL` passed, which causes bootstrap
# These oddly named file records the `SHELL` passed, which causes bootstrap
# tools run-time dependency.
+ ''
find "$out" -name '..install.cmd' -print0 | xargs -0 rm

View File

@@ -1,5 +1,6 @@
{ stdenv, lib, fetchurl, autoreconfHook, pkgconfig
, libxslt, xz, elf-header }:
, libxslt, xz, elf-header
, withStatic ? false }:
let
systems = [ "/run/current-system/kernel-modules" "/run/booted-system/kernel-modules" "" ];
@@ -21,10 +22,11 @@ in stdenv.mkDerivation rec {
"--sysconfdir=/etc"
"--with-xz"
"--with-modulesdirs=${modulesDirs}"
];
] ++ lib.optional withStatic "--enable-static";
patches = [ ./module-dir.patch ]
++ lib.optional stdenv.isDarwin ./darwin.patch;
++ lib.optional stdenv.isDarwin ./darwin.patch
++ lib.optional withStatic ./enable-static.patch;
postInstall = ''
for prog in rmmod insmod lsmod modinfo modprobe depmod; do

View File

@@ -0,0 +1,12 @@
diff --git a/configure.ac b/configure.ac
index ee72283..b42c42a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -19,7 +19,6 @@ AM_SILENT_RULES([yes])
LT_INIT([disable-static pic-only])
DOLT
-AS_IF([test "x$enable_static" = "xyes"], [AC_MSG_ERROR([--enable-static is not supported by kmod])])
AS_IF([test "x$enable_largefile" = "xno"], [AC_MSG_ERROR([--disable-largefile is not supported by kmod])])
#####################################################################