initramfs-tools: add initramfs-tools trigger, add blkid.

Do not use blkid from busybox, doesn't work... dunno why.
Bump revision again, grrr!

--HG--
extra : convert_revision : 5af4b5870491c9ba24f3df7e897f4102bda51dd5
This commit is contained in:
Juan RP 2009-10-08 16:57:13 +02:00
parent 7e71f6d4af
commit d3b7ea77b7
2 changed files with 42 additions and 39 deletions

View file

@ -176,8 +176,42 @@
# Don't wait for a root device that doesn't have a corresponding
# device in /dev (ie, mtd0)
if [ "${ROOT#/dev}" = "${ROOT}" ]; then
--- init.orig 2009-03-20 10:10:13.000000000 +0100
+++ init 2009-10-08 16:50:24.108954736 +0200
@@ -2,14 +2,29 @@
echo "Loading, please wait..."
+# Create some required busybox symlinks.
+if [ -x /bin/busybox ]; then
+ busybox ln -s /bin/busybox /bin/cut
+ busybox ln -s /bin/busybox /bin/touch
+ busybox ln -s /bin/busybox /bin/tr
+ busybox ln -s /bin/busybox /bin/grep
+ busybox ln -s /bin/busybox /bin/awk
+ busybox ln -s /bin/busybox /bin/tail
+ busybox ln -s /bin/busybox /bin/basename
+ busybox ln -s /bin/busybox /bin/ls
+ busybox ln -s /bin/busybox /bin/cp
+ busybox ln -s /bin/busybox /bin/rm
+ busybox ln -s /bin/busybox /sbin/pkill
+fi
+
[ -d /dev ] || mkdir -m 0755 /dev
[ -d /root ] || mkdir -m 0700 /root
[ -d /sys ] || mkdir /sys
[ -d /proc ] || mkdir /proc
[ -d /tmp ] || mkdir /tmp
mkdir -p /var/lock
-mount -t sysfs -o nodev,noexec,nosuid none /sys
-mount -t proc -o nodev,noexec,nosuid none /proc
+mount -t sysfs -o nodev,noexec,nosuid sysfs /sys
+mount -t proc -o nodev,noexec,nosuid proc /proc
# Note that this only becomes /dev on the real filesystem if udev's scripts
# are used; which they will be, but it's worth pointing out
--- mkinitramfs.orig 2009-04-02 12:25:45.000000000 +0200
+++ mkinitramfs 2009-10-08 15:52:24.676373911 +0200
+++ mkinitramfs 2009-10-08 16:50:03.681982224 +0200
@@ -8,8 +8,7 @@ keep="n"
CONFDIR="/etc/initramfs-tools"
verbose="n"
@ -205,12 +239,12 @@
# those root need busybox
eval "$(mount | awk '/ \/ / {print "r_dev=" $1; exit}')"
if [ "${r_dev#/dev/mapper/}" != "${r_dev}" ]; then
@@ -251,16 +249,14 @@ else
@@ -251,16 +249,17 @@ else
ln -s ${BUSYBOXDIR}/busybox ${DESTDIR}/bin/sh
fi
-# Modutils
+# Module-init-tools
+# module-init-tools
copy_exec /sbin/modprobe /sbin
copy_exec /sbin/depmod /sbin
copy_exec /sbin/rmmod /sbin
@ -220,44 +254,12 @@
-# workaround: libgcc always needed on old-abi arm
-if [ "$DPKG_ARCH" = arm ] || [ "$DPKG_ARCH" = armeb ]; then
- cp -a /lib/libgcc_s.so.1 "${DESTDIR}/lib/"
+# libblkid
+copy_exec /sbin/blkid /sbin
+
+if [ -d /etc/modprobe.d ]; then
+ mkdir -p "${DESTDIR}/etc/modprobe.d"
+ cp -a /etc/modprobe.d/* "${DESTDIR}/etc/modprobe.d/"
fi
run_scripts /usr/share/initramfs-tools/hooks
--- init.orig 2009-03-20 10:10:13.000000000 +0100
+++ init 2009-10-08 15:44:38.768984346 +0200
@@ -2,14 +2,30 @@
echo "Loading, please wait..."
+# Create some required busybox symlinks.
+if [ -x /bin/busybox ]; then
+ busybox ln -s /bin/busybox /bin/cut
+ busybox ln -s /bin/busybox /bin/touch
+ busybox ln -s /bin/busybox /bin/tr
+ busybox ln -s /bin/busybox /bin/grep
+ busybox ln -s /bin/busybox /bin/awk
+ busybox ln -s /bin/busybox /bin/tail
+ busybox ln -s /bin/busybox /bin/basename
+ busybox ln -s /bin/busybox /bin/ls
+ busybox ln -s /bin/busybox /bin/cp
+ busybox ln -s /bin/busybox /sbin/blkid
+ busybox ln -s /bin/busybox /bin/rm
+ busybox ln -s /bin/busybox /sbin/pkill
+fi
+
[ -d /dev ] || mkdir -m 0755 /dev
[ -d /root ] || mkdir -m 0700 /root
[ -d /sys ] || mkdir /sys
[ -d /proc ] || mkdir /proc
[ -d /tmp ] || mkdir /tmp
mkdir -p /var/lock
-mount -t sysfs -o nodev,noexec,nosuid none /sys
-mount -t proc -o nodev,noexec,nosuid none /proc
+mount -t sysfs -o nodev,noexec,nosuid sysfs /sys
+mount -t proc -o nodev,noexec,nosuid proc /proc
# Note that this only becomes /dev on the real filesystem if udev's scripts
# are used; which they will be, but it's worth pointing out

View file

@ -1,7 +1,7 @@
# Template file for 'initramfs-tools'
pkgname=initramfs-tools
version=0.93.2
revision=8
revision=9
wrksrc=$pkgname
patch_files="$pkgname-xbps.diff"
distfiles="${DEBIAN_SITE}/main/i/${pkgname}/${pkgname}_${version}.tar.gz"
@ -19,6 +19,7 @@ long_desc="
able to load an initramfs archive."
noarch=yes
triggers="initramfs-tools"
keep_dirs="/var/lib/$pkgname"
conf_files="/etc/$pkgname/initramfs.conf /etc/$pkgname/update-initramfs.conf
/etc/$pkgname/modules"