7.8. Kmod-15

The Kmod package contains programs for loading, inserting and removing kernel modules for Linux. Kmod replaces the Module-Init-tools package.

7.8.1. Installation of Kmod

Prepare Kmod for compilation:

liblzma_CFLAGS="-I/tools/include" liblzma_LIBS="-L/tools/lib -llzma" \
zlib_CFLAGS="-I/tools/include" zlib_LIBS="-L/tools/lib -lz" \
CC="${CC} ${BUILD64}" ./configure --prefix=/tools --bindir=/bin \
    --build=${CLFS_HOST} --host=${CLFS_TARGET} --with-xz --with-zlib \
    --disable-manpages

Compile the package:

make

Install the package:

make DESTDIR=${CLFS} install

Create symbolic links for programs that expect Module-Init-Tools.

ln -sv kmod ${CLFS}/bin/lsmod
ln -sv ../bin/kmod ${CLFS}/sbin/depmod
ln -sv ../bin/kmod ${CLFS}/sbin/insmod
ln -sv ../bin/kmod ${CLFS}/sbin/modprobe
ln -sv ../bin/kmod ${CLFS}/sbin/modinfo
ln -sv ../bin/kmod ${CLFS}/sbin/rmmod

Details on this package are located in Section 10.52.2, “Contents of Kmod.”