From 43a3d87b8370872c5720b4bb6616b797486d38d8 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Sat, 22 Jun 2013 22:09:40 +0000 Subject: [PATCH] package: fix insmod on install the procd changes broke the postinst insmod. Signed-off-by: John Crispin SVN-Revision: 37015 --- include/kernel.mk | 2 +- package/base-files/files/lib/functions.sh | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/include/kernel.mk b/include/kernel.mk index b637de5918..cbf342a0d2 100644 --- a/include/kernel.mk +++ b/include/kernel.mk @@ -105,7 +105,7 @@ define ModuleAutoLoad echo "#!/bin/sh" > $(2)/CONTROL/postinst; \ echo "[ -z \"\$$$$$$$$IPKG_INSTROOT\" ] || exit 0" >> $(2)/CONTROL/postinst; \ echo ". /lib/functions.sh" >> $(2)/CONTROL/postinst; \ - echo "load_modules $$$$$$$$modules" >> $(2)/CONTROL/postinst; \ + echo "insert_modules $$$$$$$$modules" >> $(2)/CONTROL/postinst; \ chmod 0755 $(2)/CONTROL/postinst; \ fi endef diff --git a/package/base-files/files/lib/functions.sh b/package/base-files/files/lib/functions.sh index 42d76fd67d..bc521b07ee 100755 --- a/package/base-files/files/lib/functions.sh +++ b/package/base-files/files/lib/functions.sh @@ -203,6 +203,13 @@ config_list_foreach() { done } +insert_modules() { + [ -d /etc/modules.d ] && { + cd /etc/modules.d + sed 's/^[^#]/insmod &/' $* | ash 2>&- || : + } +} + include() { local file -- 2.25.1