1
0
mirror of synced 2026-04-15 23:51:03 +00:00

2006-12-25 22:46:56 by steve

BUGFIX:  Module installation now works correctly.  D'oh.
This commit is contained in:
steve
2006-12-25 22:46:57 +00:00
parent fdc25c74d5
commit ba810412b9
3 changed files with 51 additions and 30 deletions

View File

@@ -41,18 +41,25 @@ linux_modules_package="linux-modules-$(uname -r)"
# Attempt to install that package. This will either work on an Etch
# system, or fail on a Sarge/custom kernel.
#
if chroot ${prefix} /usr/bin/apt-cache policy ${linux_modules_package} 2>/dev/null; then
if chroot ${prefix} /usr/bin/apt-cache show ${linux_modules_package} >/dev/null 2>/dev/null; then
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
logMessage "Package '${linux_modules_package}' is available - installing"
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
else
#
# Fall back to copying over modules from the host to the new
# system.
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
#
# Fall back to copying over modules from the host to the new
# system.
#
logMessage "Package '${linux_modules_package}' is not available"
logMessage "Copying modules from /lib/modules/$(uname -r)"
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
fi

View File

@@ -41,18 +41,25 @@ linux_modules_package="linux-modules-$(uname -r)"
# Attempt to install that package. This will either work on an Etch
# system, or fail on a Sarge/custom kernel.
#
if chroot ${prefix} /usr/bin/apt-cache policy ${linux_modules_package} 2>/dev/null; then
if chroot ${prefix} /usr/bin/apt-cache show ${linux_modules_package} >/dev/null 2>/dev/null; then
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
logMessage "Package '${linux_modules_package}' is available - installing"
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
else
#
# Fall back to copying over modules from the host to the new
# system.
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
#
# Fall back to copying over modules from the host to the new
# system.
#
logMessage "Package '${linux_modules_package}' is not available"
logMessage "Copying modules from /lib/modules/$(uname -r)"
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
fi
#

View File

@@ -41,18 +41,25 @@ linux_modules_package="linux-modules-$(uname -r)"
# Attempt to install that package. This will either work on an Etch
# system, or fail on a Sarge/custom kernel.
#
if chroot ${prefix} /usr/bin/apt-cache policy ${linux_modules_package} 2>/dev/null; then
if chroot ${prefix} /usr/bin/apt-cache show ${linux_modules_package} >/dev/null 2>/dev/null; then
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
logMessage "Package '${linux_modules_package}' is available - installing"
#
# If it worked then we can install the package.
#
installDebianPackage ${prefix} ${linux_modules_package}
else
#
# Fall back to copying over modules from the host to the new
# system.
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
#
# Fall back to copying over modules from the host to the new
# system.
#
logMessage "Package '${linux_modules_package}' is not available"
logMessage "Copying modules from /lib/modules/$(uname -r)"
mkdir -p ${prefix}/lib/modules
cp -au /lib/modules/$(uname -r) ${prefix}/lib/modules
fi