From ba109afd0d551909be86bb11d797f1db80ce56f6 Mon Sep 17 00:00:00 2001 From: Arne Fitzenreiter Date: Mon, 18 Nov 2013 19:00:51 +0100 Subject: [PATCH] kmod: replace module-init-tools by kmod-13. newer udev depend on kmod. --- .../modprobe.d/{cfg80211 => cfg80211.conf} | 0 .../modprobe.d/{pcspeaker => pcspeaker.conf} | 0 config/rootfiles/common/armv5tel/linux | 6 +- .../rootfiles/common/armv5tel/linux-kirkwood | 6 +- config/rootfiles/common/i586/linux | 6 +- config/rootfiles/common/kmod | 13 +++ config/rootfiles/common/module-init-tools | 21 ----- config/rootfiles/common/stage2 | 4 +- config/rootfiles/common/udev | 2 +- lfs/kmod | 94 +++++++++++++++++++ lfs/linux | 14 +-- lfs/mISDN | 4 +- lfs/udev | 2 +- make.sh | 2 +- 14 files changed, 130 insertions(+), 44 deletions(-) rename config/etc/modprobe.d/{cfg80211 => cfg80211.conf} (100%) rename config/etc/modprobe.d/{pcspeaker => pcspeaker.conf} (100%) create mode 100644 config/rootfiles/common/kmod delete mode 100644 config/rootfiles/common/module-init-tools create mode 100644 lfs/kmod diff --git a/config/etc/modprobe.d/cfg80211 b/config/etc/modprobe.d/cfg80211.conf similarity index 100% rename from config/etc/modprobe.d/cfg80211 rename to config/etc/modprobe.d/cfg80211.conf diff --git a/config/etc/modprobe.d/pcspeaker b/config/etc/modprobe.d/pcspeaker.conf similarity index 100% rename from config/etc/modprobe.d/pcspeaker rename to config/etc/modprobe.d/pcspeaker.conf diff --git a/config/rootfiles/common/armv5tel/linux b/config/rootfiles/common/armv5tel/linux index 2206ce3c1..8c4c97f2e 100644 --- a/config/rootfiles/common/armv5tel/linux +++ b/config/rootfiles/common/armv5tel/linux @@ -1,4 +1,4 @@ -etc/modprobe.d/framebuffer -etc/modprobe.d/ipv6 -etc/modprobe.d/isdn +etc/modprobe.d/framebuffer.conf +etc/modprobe.d/ipv6.conf +etc/modprobe.d/isdn.conf sbin/gen_init_cpio diff --git a/config/rootfiles/common/armv5tel/linux-kirkwood b/config/rootfiles/common/armv5tel/linux-kirkwood index 3354d9eee..60374aad0 100644 --- a/config/rootfiles/common/armv5tel/linux-kirkwood +++ b/config/rootfiles/common/armv5tel/linux-kirkwood @@ -4,9 +4,9 @@ boot/config-KVER-ipfire-kirkwood boot/dtb-KVER-ipfire-kirkwood boot/uImage-ipfire-kirkwood boot/vmlinuz-KVER-ipfire-kirkwood -etc/modprobe.d/framebuffer -etc/modprobe.d/ipv6 -etc/modprobe.d/isdn +etc/modprobe.d/framebuffer.conf +etc/modprobe.d/ipv6.conf +etc/modprobe.d/isdn.conf lib/modules/KVER-ipfire-kirkwood #lib/modules/KVER-ipfire-kirkwood/build #lib/modules/KVER-ipfire-kirkwood/kernel diff --git a/config/rootfiles/common/i586/linux b/config/rootfiles/common/i586/linux index 20b64102b..c0c343657 100644 --- a/config/rootfiles/common/i586/linux +++ b/config/rootfiles/common/i586/linux @@ -3,9 +3,9 @@ boot/System.map-ipfire boot/config-KVER-ipfire boot/vmlinuz-KVER-ipfire boot/vmlinuz-ipfire -etc/modprobe.d/framebuffer -etc/modprobe.d/ipv6 -etc/modprobe.d/isdn +etc/modprobe.d/framebuffer.conf +etc/modprobe.d/ipv6.conf +etc/modprobe.d/isdn.conf lib/modules/KVER-ipfire #lib/modules/KVER-ipfire/build #lib/modules/KVER-ipfire/kernel diff --git a/config/rootfiles/common/kmod b/config/rootfiles/common/kmod new file mode 100644 index 000000000..14e765477 --- /dev/null +++ b/config/rootfiles/common/kmod @@ -0,0 +1,13 @@ +bin/kmod +sbin/depmod +sbin/insmod +sbin/lsmod +sbin/modinfo +sbin/modprobe +sbin/rmmod +#usr/include/libkmod.h +#usr/lib/libkmod.la +usr/lib/libkmod.so +usr/lib/libkmod.so.2 +usr/lib/libkmod.so.2.2.3 +#usr/lib/pkgconfig/libkmod.pc diff --git a/config/rootfiles/common/module-init-tools b/config/rootfiles/common/module-init-tools deleted file mode 100644 index 4cffddb5e..000000000 --- a/config/rootfiles/common/module-init-tools +++ /dev/null @@ -1,21 +0,0 @@ -bin/lsmod -sbin/depmod -sbin/generate-modprobe.conf -sbin/insmod -sbin/insmod.static -sbin/modinfo -sbin/modprobe -sbin/rmmod -#share -#share/man -#share/man/man5 -#share/man/man5/depmod.conf.5 -#share/man/man5/modprobe.conf.5 -#share/man/man5/modules.dep.5 -#share/man/man8 -#share/man/man8/depmod.8 -#share/man/man8/insmod.8 -#share/man/man8/lsmod.8 -#share/man/man8/modinfo.8 -#share/man/man8/modprobe.8 -#share/man/man8/rmmod.8 diff --git a/config/rootfiles/common/stage2 b/config/rootfiles/common/stage2 index 04ef3f2cb..d5d1a5ceb 100644 --- a/config/rootfiles/common/stage2 +++ b/config/rootfiles/common/stage2 @@ -20,8 +20,8 @@ etc/ld.so.conf etc/logrotate.conf etc/mime.types etc/modprobe.d -etc/modprobe.d/cfg80211 -etc/modprobe.d/pcspeaker +etc/modprobe.d/cfg80211.conf +etc/modprobe.d/pcspeaker.conf etc/modules.conf etc/mtab etc/nsswitch.conf diff --git a/config/rootfiles/common/udev b/config/rootfiles/common/udev index bacd0cbbe..49cad7e92 100644 --- a/config/rootfiles/common/udev +++ b/config/rootfiles/common/udev @@ -1,4 +1,4 @@ -etc/modprobe.d/blacklist +etc/modprobe.d/blacklist.conf etc/scsi_id.config etc/udev #etc/udev/rules.d diff --git a/lfs/kmod b/lfs/kmod new file mode 100644 index 000000000..dc2dc10b8 --- /dev/null +++ b/lfs/kmod @@ -0,0 +1,94 @@ +############################################################################### +# # +# IPFire.org - A linux based firewall # +# Copyright (C) 2007 Michael Tremer & Christian Schmidt # +# # +# This program is free software: you can redistribute it and/or modify # +# it under the terms of the GNU General Public License as published by # +# the Free Software Foundation, either version 3 of the License, or # +# (at your option) any later version. # +# # +# This program is distributed in the hope that it will be useful, # +# but WITHOUT ANY WARRANTY; without even the implied warranty of # +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # +# GNU General Public License for more details. # +# # +# You should have received a copy of the GNU General Public License # +# along with this program. If not, see . # +# # +############################################################################### + +############################################################################### +# Definitions +############################################################################### + +include Config + +VER = 13 + +THISAPP = kmod-$(VER) +DL_FILE = $(THISAPP).tar.xz +DL_FROM = $(URL_IPFIRE) +DIR_APP = $(DIR_SRC)/$(THISAPP) +TARGET = $(DIR_INFO)/$(THISAPP) + +############################################################################### +# Top-level Rules +############################################################################### + +objects = $(DL_FILE) + +$(DL_FILE) = $(DL_FROM)/$(DL_FILE) + +$(DL_FILE)_MD5 = d5aba43b9370cd52f3cb35e82a1aa595 + +install : $(TARGET) + +check : $(patsubst %,$(DIR_CHK)/%,$(objects)) + +download :$(patsubst %,$(DIR_DL)/%,$(objects)) + +md5 : $(subst %,%_MD5,$(objects)) + +############################################################################### +# Downloading, checking, md5sum +############################################################################### + +$(patsubst %,$(DIR_CHK)/%,$(objects)) : + @$(CHECK) + +$(patsubst %,$(DIR_DL)/%,$(objects)) : + @$(LOAD) + +$(subst %,%_MD5,$(objects)) : + @$(MD5) + +############################################################################### +# Installation Details +############################################################################### + +$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) + @$(PREBUILD) + @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE) + cd $(DIR_APP) && ./configure \ + --prefix=/usr \ + --bindir=/bin \ + --sysconfdir=/etc \ + --enable-zlib \ + --disable-manpages + +# --libdir=/lib \ + + cd $(DIR_APP) && make $(MAKETUNING) + cd $(DIR_APP) && make install + + # Create symlinks + ln -svf ../bin/kmod /sbin/modprobe + ln -svf ../bin/kmod /sbin/modinfo + ln -svf ../bin/kmod /sbin/insmod + ln -svf ../bin/kmod /sbin/rmmod + ln -svf ../bin/kmod /sbin/depmod + ln -svf ../bin/kmod /sbin/lsmod + + @rm -rf $(DIR_APP) + @$(POSTBUILD) diff --git a/lfs/linux b/lfs/linux index 5fc9e1f8a..306a1d14f 100644 --- a/lfs/linux +++ b/lfs/linux @@ -230,25 +230,25 @@ ifeq "$(LASTKERNEL)" "1" cd $(DIR_APP) && install -m 755 usr/gen_init_cpio /sbin/ # Blacklist matroxfb_base - echo "blacklist matroxfb_base" >> /etc/modprobe.d/framebuffer + echo "blacklist matroxfb_base" >> /etc/modprobe.d/framebuffer.conf # Blacklist old framebuffer modules for f in $$(find /lib/modules/$(VER)-$(VERSUFIX)/kernel/drivers/video -name *fb.ko); do \ - echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/framebuffer ; \ + echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/framebuffer.conf ; \ done # Blacklist new drm framebuffer modules for f in $$(ls -1 /lib/modules/$(VER)-$(VERSUFIX)/kernel/drivers/gpu/drm/*/*.ko); do \ - echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/framebuffer ; \ + echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/framebuffer.conf ; \ done - sed -i -e "s|.ko||g" /etc/modprobe.d/framebuffer + sed -i -e "s|.ko||g" /etc/modprobe.d/framebuffer.conf # Blacklist isdn modules for f in $$(find /lib/modules/$(VER)-$(VERSUFIX)/kernel/drivers/isdn -name *.ko); do \ - echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/isdn ; \ + echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/isdn.conf ; \ done - sed -i -e "s|.ko||g" /etc/modprobe.d/isdn + sed -i -e "s|.ko||g" /etc/modprobe.d/isdn.conf # Disable ipv6 at runtime - echo "options ipv6 disable_ipv6=1" > /etc/modprobe.d/ipv6 + echo "options ipv6 disable_ipv6=1" > /etc/modprobe.d/ipv6.conf endif # Disable geode_aes modul if exist diff --git a/lfs/mISDN b/lfs/mISDN index e6a7465b3..5cd4972ca 100644 --- a/lfs/mISDN +++ b/lfs/mISDN @@ -106,9 +106,9 @@ endif ifneq "$(XEN)" "1" # Blacklist misdn modules for f in $$(find /lib/modules/$(KVER)-$(VERSUFIX)/mISDN -name *.ko); do \ - echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/mISDN ; \ + echo "blacklist $$(basename $$f)" >> /etc/modprobe.d/mISDN.conf ; \ done - sed -i -e "s|.ko||g" /etc/modprobe.d/mISDN + sed -i -e "s|.ko||g" /etc/modprobe.d/mISDN.conf endif # Remove mISDN modules that was shipped with the kernel diff --git a/lfs/udev b/lfs/udev index 9ebec2f18..3f7b94f33 100644 --- a/lfs/udev +++ b/lfs/udev @@ -95,7 +95,7 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) touch /etc/udev/rules.d/30-persistent-network.rules # Blacklist some modules - cp -vf $(DIR_SRC)/config/udev/blacklist /etc/modprobe.d/blacklist + cp -vf $(DIR_SRC)/config/udev/blacklist.conf /etc/modprobe.d/blacklist.conf # Install alsa rules. install -v -m 644 $(DIR_SRC)/config/udev/25-alsa.rules \ diff --git a/make.sh b/make.sh index 849624e7a..dea429055 100755 --- a/make.sh +++ b/make.sh @@ -360,7 +360,7 @@ buildbase() { lfsmake2 make lfsmake2 man lfsmake2 mktemp - lfsmake2 module-init-tools + lfsmake2 kmod lfsmake2 net-tools lfsmake2 patch lfsmake2 psmisc -- 2.39.2