summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoey Hess <joey@kitenet.net>2011-08-15 23:36:51 (GMT)
committerJoey Hess <joey@kitenet.net>2011-08-15 23:36:51 (GMT)
commit804a6a4349944f2fa8ad146d8e7794ae19c09d58 (patch)
treeeb9c1cb12a89048fb5ff7d02b34d8359d0104619
parent3b609a408c6a10890785e9824b0c8f3a78c0089f (diff)
downloaddebootstrap-804a6a4349944f2fa8ad146d8e7794ae19c09d58.zip
debootstrap-804a6a4349944f2fa8ad146d8e7794ae19c09d58.tar.gz
debootstrap-804a6a4349944f2fa8ad146d8e7794ae19c09d58.tar.bz2
warn about missing modules on FreeBSD
* Fix support for running debootstrap on a FreeBSD host to create a kFreeBSD chroot or jail. Thanks, Arno Toell. * When debootstrapping on FreeBSD, warn if necessary modules are not loaded. Thanks, Arno Toell.
-rw-r--r--debian/changelog6
-rwxr-xr-xdebootstrap6
2 files changed, 10 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index 468f7b3..a13a247 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,14 +1,16 @@
debootstrap (1.0.36) UNRELEASED; urgency=low
* Guess host OS based on uname for non-Debian systems. Closes: #637363
- * Fix support for running debootstrap on a FreeBSD host to create a kFreeBSD
- chroot or jail.
* Clarify "target" in usage message.
+ * Fix support for running debootstrap on a FreeBSD host to create a kFreeBSD
+ chroot or jail. Thanks, Arno Toell.
* Search PATH for programs, rather than checking hardcoded locations.
* Support using md5 and shaN programs, as found on FreeBSD, in addition
to md5sum and shaNsum.
* When FreeBSD (not kfreebsd) is the host, don't chroot to mount special
filesystems.
+ * When debootstrapping on FreeBSD, warn if necessary modules are not
+ loaded. Thanks, Arno Toell.
-- Joey Hess <joeyh@debian.org> Mon, 15 Aug 2011 14:14:29 -0400
diff --git a/debootstrap b/debootstrap
index ca4c026..facd1d8 100755
--- a/debootstrap
+++ b/debootstrap
@@ -428,6 +428,12 @@ if [ -z "$ARCH" ] || [ -z "$HOST_OS" ]; then
fi
+if [ "$HOST_OS" = "kfreebsd" ] || [ "$HOST_OS" = "freebsd" ]; then
+ for module in "linprocfs fdescfs tmpfs linsysfs"; do
+ kldstat -m "$module" > /dev/null 2>&1 || warning SANITYCHECK "Probably required module %s is not loaded" "$module"
+ done
+fi
+
if [ "$TARGET" = "/" ]; then
CHROOT_CMD=""
elif doing_variant scratchbox; then