treewide: Replace module_init_tools -> kmod

The former is deprecated and doesn't handle compressed kernel modules,
so all current usages of it are broken.
This commit is contained in:
Tuomas Tynkkynen 2016-04-22 10:40:57 +03:00
parent d99eaf005c
commit 01854a850a
11 changed files with 39 additions and 39 deletions

View file

@ -31,13 +31,13 @@ in
# unload module during suspend/hibernate as it crashes the whole system
powerManagement.powerDownCommands = ''
${pkgs.module_init_tools}/bin/rmmod -f facetimehd
${pkgs.kmod}/bin/rmmod -f facetimehd
'';
# and load it back on resume
powerManagement.resumeCommands = ''
export MODULE_DIR=/run/current-system/kernel-modules/lib/modules
${pkgs.module_init_tools}/bin/modprobe -v facetimehd
${pkgs.kmod}/bin/modprobe -v facetimehd
'';
};

View file

@ -80,7 +80,7 @@ in
preStart = ''
mkdir -p -m 0755 /afs
mkdir -m 0700 -p ${cfg.cacheDirectory}
${pkgs.module_init_tools}/sbin/insmod ${openafsPkgs}/lib/openafs/libafs-*.ko || true
${pkgs.kmod}/sbin/insmod ${openafsPkgs}/lib/openafs/libafs-*.ko || true
${openafsPkgs}/sbin/afsd -confdir ${afsConfig} -cachedir ${cfg.cacheDirectory} ${if cfg.sparse then "-dynroot-sparse" else "-dynroot"} -fakestat -afsdb
${openafsPkgs}/bin/fs setcrypt ${if cfg.crypt then "on" else "off"}
'';
@ -92,7 +92,7 @@ in
preStop = ''
${pkgs.utillinux}/bin/umount /afs
${openafsPkgs}/sbin/afsd -shutdown
${pkgs.module_init_tools}/sbin/rmmod libafs
${pkgs.kmod}/sbin/rmmod libafs
'';
};
};

View file

@ -149,11 +149,11 @@ let
${pkgs.mtools}/bin/mlabel -i /dev/vda2 ::boot
# Mount /boot; load necessary modules first.
${pkgs.module_init_tools}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/nls/nls_cp437.ko || true
${pkgs.module_init_tools}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/nls/nls_iso8859-1.ko || true
${pkgs.module_init_tools}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/fat/fat.ko || true
${pkgs.module_init_tools}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/fat/vfat.ko || true
${pkgs.module_init_tools}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/efivarfs/efivarfs.ko || true
${pkgs.kmod}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/nls/nls_cp437.ko || true
${pkgs.kmod}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/nls/nls_iso8859-1.ko || true
${pkgs.kmod}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/fat/fat.ko || true
${pkgs.kmod}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/fat/vfat.ko || true
${pkgs.kmod}/sbin/insmod ${pkgs.linux}/lib/modules/*/kernel/fs/efivarfs/efivarfs.ko || true
mkdir /boot
mount /dev/vda2 /boot

View file

@ -329,14 +329,14 @@ rec {
buildInputs = [ utillinux ];
buildCommand = ''
ln -s ${linux}/lib /lib
${module_init_tools}/bin/modprobe loop
${module_init_tools}/bin/modprobe ext4
${module_init_tools}/bin/modprobe hfs
${module_init_tools}/bin/modprobe hfsplus
${module_init_tools}/bin/modprobe squashfs
${module_init_tools}/bin/modprobe iso9660
${module_init_tools}/bin/modprobe ufs
${module_init_tools}/bin/modprobe cramfs
${kmod}/bin/modprobe loop
${kmod}/bin/modprobe ext4
${kmod}/bin/modprobe hfs
${kmod}/bin/modprobe hfsplus
${kmod}/bin/modprobe squashfs
${kmod}/bin/modprobe iso9660
${kmod}/bin/modprobe ufs
${kmod}/bin/modprobe cramfs
mknod /dev/loop0 b 7 0
mkdir -p $out
@ -355,12 +355,12 @@ rec {
buildInputs = [ utillinux mtdutils ];
buildCommand = ''
ln -s ${linux}/lib /lib
${module_init_tools}/bin/modprobe mtd
${module_init_tools}/bin/modprobe mtdram total_size=131072
${module_init_tools}/bin/modprobe mtdchar
${module_init_tools}/bin/modprobe mtdblock
${module_init_tools}/bin/modprobe jffs2
${module_init_tools}/bin/modprobe zlib
${kmod}/bin/modprobe mtd
${kmod}/bin/modprobe mtdram total_size=131072
${kmod}/bin/modprobe mtdchar
${kmod}/bin/modprobe mtdblock
${kmod}/bin/modprobe jffs2
${kmod}/bin/modprobe zlib
mknod /dev/mtd0 c 90 0
mknod /dev/mtdblock0 b 31 0

View file

@ -1,6 +1,6 @@
{ stdenv, fetchurl
, yacc, flex
, sysfsutils, module_init_tools, udev
, sysfsutils, kmod, udev
, firmware # Special pcmcia cards.
, config # Special hardware (map memory & port & irq)
, lib # used to generate postInstall script.
@ -15,11 +15,11 @@ stdenv.mkDerivation rec {
sha256 = "5d8e2efad8a7f692129610603da232f2144851753d8d49a70eeb8eb1be6f6bc3";
};
buildInputs = [udev yacc sysfsutils module_init_tools flex];
buildInputs = [udev yacc sysfsutils kmod flex];
patchPhase = ''
sed -i "
s,/sbin/modprobe,${module_init_tools}&,;
s,/sbin/modprobe,${kmod}&,;
s,/lib/udev/,$out/sbin/,;
" udev/* # fix-color */
sed -i "

View file

@ -1,10 +1,10 @@
{ stdenv, fetchurl, coreutils, gnugrep, utillinux, module_init_tools
{ stdenv, fetchurl, coreutils, gnugrep, utillinux, kmod
, procps, kbd, dbus_tools }:
let
binPath = stdenv.lib.makeBinPath
[ coreutils gnugrep utillinux module_init_tools procps kbd dbus_tools ];
[ coreutils gnugrep utillinux kmod procps kbd dbus_tools ];
sbinPath = stdenv.lib.makeSearchPathOutputs "sbin" ["bin"]
[ procps ];

View file

@ -18,7 +18,7 @@
{ stdenv, lib, fetchurl, pkgconfig, help2man, makeWrapper
, glib, libbsd
, libX11, libXext, xorgserver, xkbcomp, module_init_tools, xkeyboard_config, xf86videonouveau
, libX11, libXext, xorgserver, xkbcomp, kmod, xkeyboard_config, xf86videonouveau
, nvidia_x11, virtualgl, primusLib
# The below should only be non-null in a x86_64 system. On a i686
# system the above nvidia_x11 and virtualgl will be the i686 packages.
@ -43,7 +43,7 @@ let
nvidiaLibs = lib.makeLibraryPath nvidia_x11s;
bbdPath = lib.makeBinPath [ module_init_tools xorgserver ];
bbdPath = lib.makeBinPath [ kmod xorgserver ];
bbdLibs = lib.makeLibraryPath [ libX11 libXext ];
xmodules = lib.concatStringsSep "," (map (x: "${x}/lib/xorg/modules") ([ xorgserver ] ++ lib.optional (!useNvidia) xf86videonouveau));
@ -80,7 +80,7 @@ in stdenv.mkDerivation rec {
# be in PATH, and thus no action for them is required.
substituteInPlace src/module.c \
--replace "/sbin/modinfo" "${module_init_tools}/sbin/modinfo"
--replace "/sbin/modinfo" "${kmod}/sbin/modinfo"
# Don't use a special group, just reuse wheel.
substituteInPlace configure \

View file

@ -1,5 +1,5 @@
{ stdenv, lib, fetchFromGitHub, makeWrapper, perl, systemd, iw, rfkill, hdparm, ethtool, inetutils
, module_init_tools, pciutils, smartmontools, x86_energy_perf_policy, gawk, gnugrep, coreutils
, kmod, pciutils, smartmontools, x86_energy_perf_policy, gawk, gnugrep, coreutils
, enableRDW ? false, networkmanager
}:
@ -27,7 +27,7 @@ in stdenv.mkDerivation {
buildInputs = [ perl ];
paths = lib.makeBinPath
([ iw rfkill hdparm ethtool inetutils systemd module_init_tools pciutils smartmontools
([ iw rfkill hdparm ethtool inetutils systemd kmod pciutils smartmontools
x86_energy_perf_policy gawk gnugrep coreutils
]
++ lib.optional enableRDW networkmanager

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, openconnect, intltool, pkgconfig, networkmanager, libsecret
, withGnome ? true, gnome3, procps, module_init_tools }:
, withGnome ? true, gnome3, procps, kmod }:
stdenv.mkDerivation rec {
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
--replace "/sbin/sysctl" "${procps}/sbin/sysctl"
substituteInPlace "src/nm-openconnect-service.c" \
--replace "/usr/sbin/openconnect" "${openconnect}/sbin/openconnect" \
--replace "/sbin/modprobe" "${module_init_tools}/sbin/modprobe"
--replace "/sbin/modprobe" "${kmod}/sbin/modprobe"
'';
postConfigure = ''

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, openvpn, intltool, pkgconfig, networkmanager, libsecret
, withGnome ? true, gnome3, procps, module_init_tools }:
, withGnome ? true, gnome3, procps, kmod }:
stdenv.mkDerivation rec {
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
--replace "/sbin/sysctl" "${procps}/sbin/sysctl"
substituteInPlace "src/nm-openvpn-service.c" \
--replace "/sbin/openvpn" "${openvpn}/sbin/openvpn" \
--replace "/sbin/modprobe" "${module_init_tools}/sbin/modprobe"
--replace "/sbin/modprobe" "${kmod}/sbin/modprobe"
substituteInPlace "properties/auth-helpers.c" \
--replace "/sbin/openvpn" "${openvpn}/sbin/openvpn"
'';

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, vpnc, intltool, pkgconfig, networkmanager, libsecret
, withGnome ? true, gnome3, procps, module_init_tools }:
, withGnome ? true, gnome3, procps, kmod }:
stdenv.mkDerivation rec {
name = "${pname}${if withGnome then "-gnome" else ""}-${version}";
@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
--replace "/sbin/sysctl" "${procps}/sbin/sysctl"
substituteInPlace "src/nm-vpnc-service.c" \
--replace "/sbin/vpnc" "${vpnc}/sbin/vpnc" \
--replace "/sbin/modprobe" "${module_init_tools}/sbin/modprobe"
--replace "/sbin/modprobe" "${kmod}/sbin/modprobe"
'';
postConfigure = ''