it's me again... ;-) Thus genkernel does not make use of th "unionfs (~x86) ebuild" it is needed to "patch/upgrade" the kernel-source-dir manually (even when unionfs-ebuild has been used before). Only after adding "unionfs-src" to the kernel-src-dir (see patch-kernel.sh within unionfs-src-tarball) the gentoo compile_unionfs_modules will succeed otherwise it will fail because "no rule to make target (unionfs.ko)". But if you'll have a closer look into unionfs's src-tarball's INSTALL and Makefile: "... You should be able to just type "make" and Unionfs will build itself for the running kernel. The Makefile will look for your running kernel sources in /lib/modules/`uname -r`/build/include. If your kernel sources are located in a different directory, create a "fistdev.mk" file along the lines of: LINUXSRC=/path/to/my/kernel/sources/linux-2.6.xx TOPINC=-I$(LINUXSRC)/include MODDIR=/lib/modules/2.6.xx You must set all three variables together, otherwise you can have problems compiling, installing, or loading the module. ..." ==> So I changed the compile_unionfs_modules() function within gen_compile.sh a little bit to make compilation of unionfs into inird independent from manually inserting "unionfs-src and Makefiles" into Kernel-Src before. ==> Another advantage is: I use unionfs-ebuild which installes unionfs.ko into: "/lib/modules/VERSION/fs" instead of "/lib/modules/2.6.15-gentoo-r1/kernel/fs" (<-- this second point is perhabs a "bug" in unionfs-ebuild but I'm not sure) ==> thus my fix only changes the behavior of gen_compile (initrd-creation) the unionfs (x86) ebuild is not affected and has still to be applied to get unionfs-support in a booted environment. But now there are not two (nearly the same, beacuse unionfs-ebuild more current patches) modules within the /lib/modules/ path --- gen_compile.sh.orig 2006-04-14 07:51:41.000000000 +0000 +++ gen_compile.sh 2006-04-14 07:54:35.000000000 +0000 @@ -333,6 +333,7 @@ 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 "KERNELVERSION=${KV}" >> fistdev.mk # Fix for hardened/selinux systems to have extened attributes @@ -346,13 +347,11 @@ if [ "${PAT}" -ge '6' ] then - # Setup the kernel sources to compile modules - cd ${KERNEL_DIR} - compile_generic "modules_prepare" kernel - cd "${TEMP}" cd "${UNIONFS_DIR}" - compile_generic unionfs.ko kernel + #Compile unionfs module within the unionfs + #environment not within the kernelsrc dir + make unionfs.ko else gen_die 'unionfs is only supported on 2.6 targets' fi genkernel output without the above modifications: -- COMMAND: make -j2 CC="gcc" LD="ld" AS="as" modules_prepare Makefile:532: /usr/src/linux-2.6.15-gentoo-r1/arch/x86/Makefile: No such file or directory make: *** No rule to make target `/usr/src/linux-2.6.15-gentoo-r1/arch/x86/Makef ile'. Stop. * CMD_DEBUGLEVEL: 5 * CMD_UNIONFS: 1 * WARNING: unionfs support is in active development and is not meant for general use. -- * Use at your own risk as this could blow up your system. * This code is subject to change at any time. * Gentoo Linux Genkernel; Version 3.3.11c * Running with options: --linuxrc=/usr/share/genkernel/generic/linuxrc --kernnam e=wig --kernel-config=/etc/kernels/wiggum --debuglevel=5 --unionfs-dev initrd * ERROR: Failed to compile the "modules_prepare" target... * -- End log... -- genkerne output with the above modifications applied: * UNIONFS MODULES: Adding support (compiling)... * unionfs modules: >> Compiling... make -C /usr/src/linux SUBDIRS=/var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4 FISTDEVMK=/var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/fistdev.mk modules make[1]: Entering directory `/usr/src/linux-2.6.15-gentoo-r1' CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/subr.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dentry.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/file.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/main.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/super.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/stale_inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/branchman.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/xattr.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/rdstate.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/copyup.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dirhelper.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/rename.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unlink.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/lookup.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/persistent_inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/commonfops.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dirfops.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/print.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/malloc_debug.o LD [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.o Building modules, stage 2. MODPOST CC /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.mod.o LD [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.ko make[1]: Leaving directory `/usr/src/linux-2.6.15-gentoo-r1' * unionfs: >> Copying to cache... * >> Creating unionfs tools cpio archive... * UNIONFS TOOLS: Adding support (compiling)... * unionfs tools: >> Compiling... ****************************************************************************** If you have questions about or problems building Unionfs, please read INSTALL. ****************************************************************************** make -C /lib/modules/2.6.15-gentoo-r1/build SUBDIRS=/var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4 FISTDEVMK=/var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/fistdev.mk modules make[1]: Entering directory `/usr/src/linux-2.6.15-gentoo-r1' CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/subr.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dentry.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/file.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/main.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/super.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/stale_inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/branchman.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/xattr.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/rdstate.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/copyup.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dirhelper.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/rename.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unlink.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/lookup.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/persistent_inode.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/commonfops.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/dirfops.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/print.o CC [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/malloc_debug.o LD [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.o Building modules, stage 2. MODPOST CC /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.mod.o LD [M] /var/tmp/genkernel/31386.29050.30366.7071/unionfs-1.1.4/unionfs.ko make[1]: Leaving directory `/usr/src/linux-2.6.15-gentoo-r1' gcc -static -o unionctl unionctl.c usercommon.c -I. -g -O2 -Wall -Werror -DUNIONFS_VERSION=\"1.1.4\" gcc -static -o uniondbg uniondbg.c -I. -g -O2 -Wall -Werror -DUNIONFS_VERSION=\"1.1.4\" gcc -static -o unionimap unionimap.c usercommon.c -luuid -I. -g -O2 -Wall -Werror -DUNIONFS_VERSION=\"1.1.4\" * unionfs: >> Copying to cache... * >> Creating insmod cpio archive... * >> Creating modules cpio archive...
*** Bug 129911 has been marked as a duplicate of this bug. ***
just wanted to mention the genkernel-version used: 3.3.11c
Fixed in 3.3.11d, thanks! Please attach your patches to bugs in the future, Bugzilla has a habit of eating whitespace.
*** Bug 130130 has been marked as a duplicate of this bug. ***