Files
sablink-distro/sys-kernel/genkernel/files/genkernel-3.4.10-unionfs-support.patch
T
2008-06-16 20:18:41 +00:00

562 lines
18 KiB
Diff

diff -Naur a/gen_cmdline.sh b/gen_cmdline.sh
--- a/gen_cmdline.sh 2008-06-05 18:47:55.000000000 +0200
+++ b/gen_cmdline.sh 2008-06-16 21:01:33.000000000 +0200
@@ -227,6 +227,17 @@
echo
print_warning 1 "Please use --evms, as --evms2 is deprecated."
;;
+ --unionfs)
+ CMD_UNIONFS=1
+ print_info 2 "CMD_UNIONFS: ${CMD_UNIONFS}"
+ echo
+ print_warning 1 "WARNING: unionfs support is in active development and is not meant for general"
+ print_warning 1 "use."
+ print_warning 1 "Bug Reports without patches/fixes will be ignored."
+ print_warning 1 "Use at your own risk as this could blow up your system."
+ print_warning 1 "This code is subject to change at any time."
+ echo
+ ;;
--lvm)
CMD_LVM=1
print_info 2 "CMD_LVM: ${CMD_LVM}"
diff -Naur a/gen_compile.sh b/gen_compile.sh
--- a/gen_compile.sh 2008-06-05 18:47:56.000000000 +0200
+++ b/gen_compile.sh 2008-06-16 21:15:38.000000000 +0200
@@ -355,6 +355,103 @@
fi
}
+compile_unionfs_modules() {
+ if [ ! -f "${UNIONFS_MODULES_BINCACHE}" ]
+ then
+ [ -f "${UNIONFS_SRCTAR}" ] ||
+ gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!"
+ cd "${TEMP}"
+ rm -rf ${UNIONFS_DIR} > /dev/null
+ rm -rf unionfs* > /dev/null
+ mkdir unionfs
+ /bin/tar xzpf ${UNIONFS_SRCTAR} ||
+ gen_die 'Could not extract unionfs source tarball!'
+ [ -d "${UNIONFS_DIR}" ] ||
+ gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!'
+ cd "${UNIONFS_DIR}"
+ print_info 1 'unionfs modules: >> Compiling...'
+ echo "LINUXSRC=${KERNEL_DIR}" >> fistdev.mk
+ echo 'TOPINC=-I$(LINUXSRC)/include' >> fistdev.mk
+ echo "MODDIR= /lib/modules/${KV}" >> fistdev.mk
+ echo "KVERS=${KV}" >> fistdev.mk
+ echo "KERNELVERSION=${KV}" >> fistdev.mk
+ # Fix for hardened/selinux systems to have extened attributes
+ # per r2d2's request. Also add -DUNIONFS_UNSUPPORTED for 2.6.16
+ echo "EXTRACFLAGS=-DUNIONFS_XATTR -DFIST_SETXATTR_CONSTVOID -DUNIONFS_UNSUPPORTED" \
+ >> fistdev.mk
+ # Here we do something really nasty and disable debugging, along with
+ # change our default CFLAGS
+ echo "UNIONFS_DEBUG_CFLAG=-DUNIONFS_NDEBUG" >> fistdev.mk
+ echo "UNIONFS_OPT_CFLAG= -O2 -pipe" >> fistdev.mk
+
+ if [ "${PAT}" -ge '6' ]
+ then
+ # ARCH is used by unionfs - and conflicts with genkernel
+ ARCH_PUSH=${ARCH}
+ unset ARCH
+ # Compile unionfs module within the unionfs
+ # environment not within the kernelsrc dir
+ make unionfs.ko || gen_die 'failed to compile unionfs'
+ ARCH=${ARCH_PUSH}
+ else
+ gen_die 'unionfs is only supported on 2.6 targets'
+ fi
+ print_info 1 'unionfs: >> Copying to cache...'
+
+ mkdir -p ${TEMP}/unionfs/lib/modules/${KV}/kernel/fs/unionfs
+
+ if [ -f unionfs.ko ]
+ then
+ cp -f unionfs.ko ${TEMP}/unionfs/lib/modules/${KV}/kernel/fs/unionfs
+ else
+ cp -f unionfs.o ${TEMP}/unionfs/lib/modules/${KV}/kernel/fs/unionfs
+ fi
+
+ cd ${TEMP}/unionfs
+ /bin/tar -cjf "${UNIONFS_MODULES_BINCACHE}" . ||
+ gen_die 'Could not create unionfs modules binary cache'
+
+ cd "${TEMP}"
+ rm -rf "${UNIONFS_DIR}" > /dev/null
+ rm -rf unionfs > /dev/null
+ fi
+}
+
+compile_unionfs_utils() {
+ if [ ! -f "${UNIONFS_BINCACHE}" ]
+ then
+ [ -f "${UNIONFS_SRCTAR}" ] ||
+ gen_die "Could not find unionfs source tarball: ${UNIONFS_SRCTAR}!"
+ cd "${TEMP}"
+ rm -rf ${UNIONFS_DIR} > /dev/null
+ rm -rf unionfs* > /dev/null
+ mkdir -p unionfs/sbin
+ /bin/tar -zxpf ${UNIONFS_SRCTAR} ||
+ gen_die 'Could not extract unionfs source tarball!'
+ [ -d "${UNIONFS_DIR}" ] ||
+ gen_die 'Unionfs directory ${UNIONFS_DIR} is invalid!'
+ cd "${UNIONFS_DIR}"
+ print_info 1 'unionfs tools: >> Compiling...'
+ #./bootstrap &> /dev/null
+ #./configure >> ${LOGFILE} 2>&1 || gen_die 'Configuring unionfs-utils failed!'
+ sed -i Makefile -e 's|LDFLAGS = |LDFLAGS = -all-static|g'
+ compile_generic '' utils
+ print_info 1 'unionfs: >> Copying to cache...'
+ strip uniondbg unionctl
+ cp uniondbg ${TEMP}/unionfs/sbin/ ||
+ gen_die 'Could not copy the uniondbg binary to the tmp directory'
+ cp unionctl ${TEMP}/unionfs/sbin/ ||
+ gen_die 'Could not copy the unionctl binary to the tmp directory'
+ cd ${TEMP}/unionfs
+ /bin/tar -cjf "${UNIONFS_BINCACHE}" . ||
+ gen_die 'Could not create unionfs tools binary cache'
+
+ cd "${TEMP}"
+ rm -rf "${UNIONFS_DIR}" > /dev/null
+ rm -rf unionfs > /dev/null
+ fi
+}
+
compile_busybox() {
[ -f "${BUSYBOX_SRCTAR}" ] ||
gen_die "Could not find busybox source tarball: ${BUSYBOX_SRCTAR}!"
diff -Naur a/gen_determineargs.sh b/gen_determineargs.sh
--- a/gen_determineargs.sh 2008-06-05 18:47:55.000000000 +0200
+++ b/gen_determineargs.sh 2008-06-16 21:01:33.000000000 +0200
@@ -108,6 +108,7 @@
set_config_with_override 1 OLDCONFIG CMD_OLDCONFIG
set_config_with_override 1 LVM CMD_LVM
set_config_with_override 1 EVMS CMD_EVMS
+ set_config_with_override 1 UNIONFS CMD_UNIONFS
set_config_with_override 1 DMRAID CMD_DMRAID
set_config_with_override 1 BUSYBOX CMD_BUSYBOX "yes"
set_config_with_override 1 DISKLABEL CMD_DISKLABEL
@@ -129,6 +130,8 @@
DEVICE_MAPPER_BINCACHE=`cache_replace "${DEVICE_MAPPER_BINCACHE}"`
LVM_BINCACHE=`cache_replace "${LVM_BINCACHE}"`
DMRAID_BINCACHE=`cache_replace "${DMRAID_BINCACHE}"`
+ UNIONFS_BINCACHE=`cache_replace "${UNIONFS_BINCACHE}"`
+ UNIONFS_MODULES_BINCACHE=`cache_replace "${UNIONFS_MODULES_BINCACHE}"`
BLKID_BINCACHE=`cache_replace "${BLKID_BINCACHE}"`
DEFAULT_KERNEL_CONFIG=`arch_replace "${DEFAULT_KERNEL_CONFIG}"`
@@ -137,6 +140,8 @@
DEVICE_MAPPER_BINCACHE=`arch_replace "${DEVICE_MAPPER_BINCACHE}"`
LVM_BINCACHE=`arch_replace "${LVM_BINCACHE}"`
DMRAID_BINCACHE=`arch_replace "${DMRAID_BINCACHE}"`
+ UNIONFS_BINCACHE=`arch_replace "${UNIONFS_BINCACHE}"`
+ UNIONFS_MODULES_BINCACHE=`arch_replace "${UNIONFS_MODULES_BINCACHE}"`
BLKID_BINCACHE=`arch_replace "${BLKID_BINCACHE}"`
@@ -207,4 +212,5 @@
fi
get_KV
+ UNIONFS_MODULES_BINCACHE=`kv_replace "${UNIONFS_MODULES_BINCACHE}"`
}
diff -Naur a/generic/initrd.scripts b/generic/initrd.scripts
--- a/generic/initrd.scripts 2008-06-05 18:47:56.000000000 +0200
+++ b/generic/initrd.scripts 2008-06-16 21:01:33.000000000 +0200
@@ -210,6 +210,21 @@
fi
}
+# Insert a directory tree $2 to an union specified by $1
+# Top-level read-write branch is specified by it's index 0
+# $1 = union absolute path (starting with /)
+# $2 = path to data directory
+#
+union_insert_dir() {
+ # detect branch 0 because newer unionfs doesn't support "0,1,2"
+ BRANCH_0="/"$(/sbin/unionctl $1 --list | cut -d/ -f2- | cut -d'(' -f1)
+ /sbin/unionctl $1 --add --after $BRANCH_0 --mode ro $2
+ if [ $? = '0' ]
+ then
+ good_msg "Addition of $2 to $1 after branch $BRANCH_0 successful"
+ fi
+}
+
findnfsmount() {
if [ "${IP}" != '' ] || busybox udhcpc -n -T 15 -q -s /bin/udhcpc.scripts
then
@@ -895,6 +910,62 @@
fi
}
+setup_unionfs() {
+ if [ "${USE_UNIONFS_NORMAL}" = '1' ]
+ then
+ # Directory used for rw changes in union mount filesystem
+ UNION=/union
+ MEMORY=/memory
+ if [ -z "$UID" ]
+ then
+ CHANGES=$MEMORY/unionfs_changes/default
+ else
+ CHANGES=$MEMORY/unionfs_changes/$UID
+ fi
+
+ mkdir -p ${MEMORY}
+ mkdir -p ${UNION}
+ good_msg "Loading unionfs module"
+ modprobe unionfs > /dev/null 2>&1
+ if [ -n "${UNIONFS}" ]
+ then
+ CHANGESDEV=${UNIONFS}
+ good_msg "mounting $CHANGESDEV to $MEMORY for unionfs support"
+ mount -t auto $CHANGESDEV $MEMORY
+ # mount tmpfs only in the case when changes= boot parameter was
+ # empty or we were not able to mount the storage device
+ ret=$?
+ if [ "${ret}" -ne 0 ]
+ then
+ bad_msg "mount of $CHANGESDEV failed falling back to ramdisk based unionfs"
+ mount -t tmpfs tmpfs $MEMORY
+ fi
+ if [ "${CDROOT}" -eq '1' -a ! -f ${MEMORY}/livecd.unionfs ]
+ then
+ umount $MEMORY
+ bad_msg "failed to find livecd.unionfs file on $CHANGESDEV"
+ bad_msg "create a livecd.unionfs file on this device if you wish to use it for unionfs"
+ bad_msg "falling back to ramdisk based unionfs for safety"
+ mount -t tmpfs tmpfs $MEMORY
+ fi
+ else
+ good_msg "Mounting ramdisk to $MEMORY for unionfs support..."
+ mount -t tmpfs tmpfs $MEMORY
+ fi
+
+ mkdir -p $CHANGES
+ mount -t unionfs -o dirs=$CHANGES=rw unionfs ${UNION}
+ ret=$?
+ if [ "${ret}" -ne 0 ]
+ then
+ bad_msg "Can't setup union ${UNION} in directory!"
+ USE_UNIONFS_NORMAL=0
+ fi
+ else
+ USE_UNIONFS_NORMAL=0
+ fi
+}
+
swsusp_resume() {
# determine swap resume partition
local device=$(ls -l "${REAL_RESUME}" | sed 's/\ */ /g' | cut -d \ -f 6-7 | sed 's/,\ */:/')
diff -Naur a/generic/linuxrc b/generic/linuxrc
--- a/generic/linuxrc 2008-06-05 18:47:56.000000000 +0200
+++ b/generic/linuxrc 2008-06-16 21:01:33.000000000 +0200
@@ -81,6 +81,21 @@
looptype\=*)
LOOPTYPE=`parse_opt "${x}"`
;;
+ unionfs)
+ USE_UNIONFS_NORMAL=0
+ ;;
+ unionfs\=*)
+ USE_UNIONFS_NORMAL=1
+ CMD_UNIONFS=`parse_opt "${x}"`
+ echo ${CMD_UNIONFS}|grep , >/dev/null 2>&1
+ if [ "$?" -eq '0' ]
+ then
+ UID=`echo ${CMD_UNIONFS#*,}`
+ UNIONFS=`echo ${CMD_UNIONFS%,*}`
+ else
+ UNIONFS=${CMD_UNIONFS}
+ fi
+ ;;
# Start Volume manager options
dolvm)
USE_LVM_NORMAL=1
@@ -249,16 +264,27 @@
fi
fi
-mkdir -p "${NEW_ROOT}"
-CHROOT="${NEW_ROOT}"
+# Set up unionfs
+mkdir -p ${NEW_ROOT}
+setup_unionfs
+
+if [ "${USE_UNIONFS_NORMAL}" = '1' ]
+then
+ CHROOT=${UNION}
+else
+ CHROOT=${NEW_ROOT}
+fi
# Run debug shell if requested
rundebugshell
if [ "${CDROOT}" = '1' ]
then
- good_msg "Making tmpfs for ${NEW_ROOT}"
- mount -t tmpfs tmpfs "${NEW_ROOT}"
+ if [ ! "${USE_UNIONFS_NORMAL}" = '1' ]
+ then
+ good_msg "Making tmpfs for ${NEW_ROOT}"
+ mount -t tmpfs tmpfs ${NEW_ROOT}
+ fi
for i in dev mnt mnt/cdrom mnt/livecd mnt/key tmp tmp/.initrd mnt/gentoo sys
do
@@ -512,6 +538,22 @@
fi
fi
+ if [ "${USE_UNIONFS_NORMAL}" = '1' ]
+ then
+ union_setup_dir ${UNION} ${NEW_ROOT}/${FS_LOCATION}
+
+ mkdir -p ${UNION}/mnt/livecd
+ if [ ! -e "${UNION}/mnt/cdrom" ]; then
+ mkdir ${UNION}/mnt/cdrom -p
+ fi
+ mount --bind ${NEW_ROOT}/${FS_LOCATION} ${UNION}/mnt/livecd
+ mount --bind ${NEW_ROOT}/mnt/cdrom ${UNION}/mnt/cdrom
+
+ # Make sure fstab notes livecd is mounted ro. Makes system skip remount which fails on unionfs dirs.
+ sed -e 's|\(.*\s/\s*tmpfs\s*\)defaults\(.*\)|\1defaults,ro\2|' /${UNION}/etc/fstab > /${UNION}/etc/fstab.new
+ mv /${UNION}/etc/fstab.new /${UNION}/etc/fstab
+ fi
+
# Unpacking additional packages from NFS mount
# This is useful for adding kernel modules to /lib
# We do this now, so that additional packages can add whereever they want.
@@ -529,55 +571,58 @@
fi
- good_msg "Copying read-write image contents to tmpfs"
- # Copy over stuff that should be writable
- (cd "${NEW_ROOT}/${FS_LOCATION}"; cp -a ${ROOT_TREES} "${NEW_ROOT}")
+ if [ "${USE_UNIONFS_NORMAL}" != '1' ]
+ then
+ good_msg "Copying read-write image contents to tmpfs"
+ # Copy over stuff that should be writable
+ (cd "${NEW_ROOT}/${FS_LOCATION}"; cp -a ${ROOT_TREES} "${NEW_ROOT}")
- # Now we do the links.
- for x in ${ROOT_LINKS}
- do
- if [ -L "${NEW_ROOT}/${FS_LOCATION}/${x}" ]
- then
- ln -s "`readlink ${NEW_ROOT}/${FS_LOCATION}/${x}`" "${x}" 2>/dev/null
- else
- # List all subdirectories of x
- find "${NEW_ROOT}/${FS_LOCATION}/${x}" -type d 2>/dev/null | while read directory
- do
- # Strip the prefix of the FS_LOCATION
- directory="${directory#${NEW_ROOT}/${FS_LOCATION}/}"
-
- # Skip this directory if we already linked a parent directory
- if [ "${curent_parrent}" != '' ]; then
- var=`echo "${directory}" | grep "^${curent_parrent}"`
- if [ "${var}" != '' ]; then
- continue
- fi
- fi
- # Test if the directory exists already
- if [ -e "/${NEW_ROOT}/${directory}" ]
- then
- # It does exist, link all the individual files
- for file in `ls /${NEW_ROOT}/${FS_LOCATION}/${directory}`
- do
- if [ ! -d "/${NEW_ROOT}/${FS_LOCATION}/${directory}/${file}" ] && [ ! -e "${NEW_ROOT}/${directory}/${file}" ]; then
- ln -s "/${FS_LOCATION}/${directory}/${file}" "${directory}/${file}" 2> /dev/null
+ # Now we do the links.
+ for x in ${ROOT_LINKS}
+ do
+ if [ -L "${NEW_ROOT}/${FS_LOCATION}/${x}" ]
+ then
+ ln -s "`readlink ${NEW_ROOT}/${FS_LOCATION}/${x}`" "${x}" 2>/dev/null
+ else
+ # List all subdirectories of x
+ find "${NEW_ROOT}/${FS_LOCATION}/${x}" -type d 2>/dev/null | while read directory
+ do
+ # Strip the prefix of the FS_LOCATION
+ directory="${directory#${NEW_ROOT}/${FS_LOCATION}/}"
+
+ # Skip this directory if we already linked a parent directory
+ if [ "${curent_parrent}" != '' ]; then
+ var=`echo "${directory}" | grep "^${curent_parrent}"`
+ if [ "${var}" != '' ]; then
+ continue
fi
- done
- else
- # It does not exist, make a link to the livecd
- ln -s "/${FS_LOCATION}/${directory}" "${directory}" 2>/dev/null
- current_parent="${directory}"
- fi
- done
- fi
- done
+ fi
+ # Test if the directory exists already
+ if [ -e "/${NEW_ROOT}/${directory}" ]
+ then
+ # It does exist, link all the individual files
+ for file in `ls /${NEW_ROOT}/${FS_LOCATION}/${directory}`
+ do
+ if [ ! -d "/${NEW_ROOT}/${FS_LOCATION}/${directory}/${file}" ] && [ ! -e "${NEW_ROOT}/${directory}/${file}" ]; then
+ ln -s "/${FS_LOCATION}/${directory}/${file}" "${directory}/${file}" 2> /dev/null
+ fi
+ done
+ else
+ # It does not exist, make a link to the livecd
+ ln -s "/${FS_LOCATION}/${directory}" "${directory}" 2>/dev/null
+ current_parent="${directory}"
+ fi
+ done
+ fi
+ done
- if [ "${DO_slowusb}" ] || [ "${FORCE_slowusb}" ]
- then
- sleep 10
+ if [ "${DO_slowusb}" ] || [ "${FORCE_slowusb}" ]
+ then
+ sleep 10
+ fi
+ mkdir initrd proc tmp sys 2>/dev/null
+ chmod 1777 tmp
fi
- mkdir initrd proc tmp sys 2>/dev/null
- chmod 1777 tmp
#UML=`cat /proc/cpuinfo|grep UML|sed -e 's|model name.*: ||'`
#if [ "${UML}" = 'UML' ]
@@ -594,6 +639,12 @@
then
sleep 10
fi
+else
+ if [ "${USE_UNIONFS_NORMAL}" = '1' ]
+ then
+ union_setup_dir ${UNION} ${NEW_ROOT}/${FS_LOCATION}
+ mkdir -p ${UNION}/tmp/.initrd
+ fi
fi
# Execute script on the cdrom just before boot to update things if necessary
diff -Naur a/gen_initramfs.sh b/gen_initramfs.sh
--- a/gen_initramfs.sh 2008-06-05 18:47:56.000000000 +0200
+++ b/gen_initramfs.sh 2008-06-16 21:01:33.000000000 +0200
@@ -72,6 +72,21 @@
rm -rf "${TEMP}/initramfs-blkid-temp" > /dev/null
}
+append_unionfs_tools(){
+ if [ -d "${TEMP}/initramfs-unionfs-tools-temp" ]
+ then
+ rm -r "${TEMP}/initramfs-unionfs-tools-temp/"
+ fi
+ print_info 1 'UNIONFS TOOLS: Adding support (compiling)...'
+ compile_unionfs_utils
+ mkdir -p "${TEMP}/initramfs-unionfs-tools-temp/bin/"
+ /bin/tar -jxpf "${UNIONFS_BINCACHE}" -C "${TEMP}/initramfs-unionfs-tools-temp" ||
+ gen_die "Could not extract unionfs tools binary cache!";
+ cd "${TEMP}/initramfs-unionfs-tools-temp/"
+ find . -print | cpio ${CPIO_ARGS} --append -F "${CPIO}"
+ rm -r "${TEMP}/initramfs-unionfs-tools-temp/"
+}
+
#append_suspend(){
# if [ -d "${TEMP}/initramfs-suspend-temp" ];
# then
@@ -463,6 +478,7 @@
append_data 'base_layout'
append_data 'auxilary'
append_data 'busybox' "${BUSYBOX}"
+ append_data 'unionfs_tools' "${UNIONFS}"
append_data 'lvm' "${LVM}"
append_data 'dmraid' "${DMRAID}"
append_data 'evms' "${EVMS}"
diff -Naur a/gen_initrd.sh b/gen_initrd.sh
--- a/gen_initrd.sh 2008-06-05 18:47:55.000000000 +0200
+++ b/gen_initrd.sh 2008-06-16 21:01:33.000000000 +0200
@@ -65,6 +65,24 @@
gen_die 'Could not extract busybox bincache!'
chmod +x "${TEMP}/initrd-temp/bin/busybox"
+ #unionfs modules
+ if [ "${UNIONFS}" -eq '1' ]
+ then
+ print_info 1 'UNIONFS MODULES: Adding support (compiling)...'
+ compile_unionfs_modules
+ /bin/tar -jxpf "${UNIONFS_MODULES_BINCACHE}" -C "${TEMP}/initrd-temp" ||
+ gen_die "Could not extract unionfs modules binary cache!";
+ fi
+
+ #unionfs utils
+ if [ "${UNIONFS}" -eq '1' ]
+ then
+ print_info 1 'UNIONFS TOOLS: Adding support (compiling)...'
+ compile_unionfs_utils
+ /bin/tar -jxpf "${UNIONFS_BINCACHE}" -C "${TEMP}/initrd-temp" ||
+ gen_die "Could not extract unionfs tools binary cache!";
+ fi
+
# DMRAID
if [ "${DMRAID}" -eq '1' ]
then
diff -Naur a/genkernel b/genkernel
--- a/genkernel 2008-06-05 18:47:55.000000000 +0200
+++ b/genkernel 2008-06-16 21:01:33.000000000 +0200
@@ -382,6 +382,8 @@
[ "${EVMS}" -eq '1' ] && print_info 1 'add "doevms" for evms support'
[ "${DMRAID}" -eq '1' ] && print_info 1 'add "dodmraid" for dmraid support'
[ "${DMRAID}" -eq '1' ] && print_info 1 ' or "dodmraid=<additional options>"'
+ [ "${UNIONFS}" -eq '1' ] && print_info 1 'add "unionfs" for unionfs support'
+ [ "${UNIONFS}" -eq '1' ] && print_info 1 ' or "unionfs=<block_device>"'
fi
[ "${BOOTRW}" != '' ] && mount -o remount,ro ${BOOTDIR}
diff -Naur a/genkernel.conf b/genkernel.conf
--- a/genkernel.conf 2008-06-05 18:47:55.000000000 +0200
+++ b/genkernel.conf 2008-06-16 21:04:25.000000000 +0200
@@ -59,6 +59,10 @@
# should run "emerge evms" first.
# EVMS="no"
+# UnionFS support. Under active development. Do not use unless you are working
+# on developing this feature.
+# UNIONFS="no"
+
# Add DMRAID support.
# DMRAID="no"
@@ -160,6 +164,14 @@
DMRAID_SRCTAR="${DISTDIR}/dmraid-${DMRAID_VER}.tar.bz2"
DMRAID_BINCACHE="%%CACHE%%/dmraid-${DMRAID_VER}-%%ARCH%%.tar.bz2"
+# Kernel Version Compatibility
+# (from http://www.am-utils.org/project-unionfs.html)
+UNIONFS_VER="VERSION_UNIONFS"
+UNIONFS_DIR="unionfs-${UNIONFS_VER}"
+UNIONFS_SRCTAR="${DISTDIR}/unionfs-${UNIONFS_VER}.tar.gz"
+UNIONFS_BINCACHE="%%CACHE%%/unionfs-${UNIONFS_VER}-tools-%%ARCH%%.tar.bz2"
+UNIONFS_MODULES_BINCACHE="%%CACHE%%/unionfs-${UNIONFS_VER}-modules-%%KV%%-%%ARCH%%.tar.bz2"
+
E2FSPROGS_VER="VERSION_E2FSPROGS"
E2FSPROGS_DIR="e2fsprogs-${E2FSPROGS_VER}"
E2FSPROGS_SRCTAR="${DISTDIR}/e2fsprogs-${E2FSPROGS_VER}.tar.gz"
diff -Naur a/mips/config.sh b/mips/config.sh
--- a/mips/config.sh 2008-06-05 18:47:55.000000000 +0200
+++ b/mips/config.sh 2008-06-16 21:01:33.000000000 +0200
@@ -12,6 +12,7 @@
USECOLOR="yes"
NOINITRDMODULES="yes"
BUSYBOX=1
+UNIONFS=0
DMRAID=0
DISKLABEL=0