xbps-casper: respect ROOTDIR in the hook.

This commit is contained in:
Juan RP 2011-10-17 18:08:35 +02:00
parent 8ce4ce3080
commit 86d5a9f1a3
2 changed files with 11 additions and 11 deletions

View File

@ -16,23 +16,23 @@ case "$1" in
;;
esac
. /usr/share/initramfs-tools/hook-functions
. ${ROOTDIR}/usr/share/initramfs-tools/hook-functions
manual_add_modules unionfs
manual_add_modules aufs
# We need losetup
copy_exec /sbin/losetup /sbin
copy_exec ${ROOTDIR}/sbin/losetup /sbin
# Casper hooks
mkdir -p ${DESTDIR}/lib/udev/rules.d
cp -p /lib/udev/rules.d/60-cdrom_id.rules ${DESTDIR}/lib/udev/rules.d/
copy_exec /lib/udev/cdrom_id /lib/udev
copy_exec /lib/udev/path_id /lib/udev
cp -p ${ROOTDIR}/lib/udev/rules.d/60-cdrom_id.rules ${DESTDIR}/lib/udev/rules.d/
copy_exec ${ROOTDIR}/lib/udev/cdrom_id /lib/udev
copy_exec ${ROOTDIR}/lib/udev/path_id /lib/udev
# cifs boot
if [ -x /sbin/mount.cifs ]; then
copy_exec /sbin/mount.cifs /sbin
if [ -x ${ROOTDIR}/sbin/mount.cifs ]; then
copy_exec ${ROOTDIR}/sbin/mount.cifs /sbin
for x in cifs; do
manual_add_modules ${x}
done
@ -61,13 +61,13 @@ manual_add_modules ohci1394
for helper in getty login new-uuid; do
ln -s /sbin/casper-${helper} ${DESTDIR}/bin
done
cp /usr/share/initramfs-tools/scripts/casper-helpers $DESTDIR/scripts
cp ${ROOTDIR}/usr/share/initramfs-tools/scripts/casper-helpers $DESTDIR/scripts
auto_add_modules net
if [ -e /etc/casper.conf ]; then
if [ -e ${ROOTDIR}/etc/casper.conf ]; then
mkdir -p ${DESTDIR}/etc
cp /etc/casper.conf ${DESTDIR}/etc
cp ${ROOTDIR}/etc/casper.conf ${DESTDIR}/etc
fi
if [ "$CASPER_GENERATE_UUID" ]; then

View File

@ -1,6 +1,6 @@
# Template file for 'xbps-casper'
pkgname=xbps-casper
_localver=0.18 # XBPS package version
_localver=0.19 # XBPS package version
_distver=1.236 # This should match the upstream (Ubuntu) version
version=${_localver}.${_distver}
build_style=custom-install