Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Building a Redhat 9 kernel on Gentoo
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
SickBoy
n00b
n00b


Joined: 25 Aug 2003
Posts: 67
Location: mpls, mn

PostPosted: Tue Nov 16, 2004 3:02 pm    Post subject: Building a Redhat 9 kernel on Gentoo Reply with quote

OK, Here's the short. I am trying to set up a Gentoo box to fool Rational Clearcase into thinking it's a Redhat 9 machine. Hacking the install script isn't hard - but linking the MVFS module (for dynamic code views, which isn't a requirement for Clearcase to work but is a very nice feature) is damn near impossible on a 2.6 kernel.

So what I did was I tarred up /usr/src/linux-2.4.20-8 directory on a Redhat 9 box, and instead of emerging a kernel sources ebuild during the installation process, I untarred the Redhat 9 kernel source.

At first I tried using

genkernel all --menuconfig

and when that didn't work, I reverted to manual configuration, which also didn't work. It seems to be having problems with the aic7xxx driver which I need for scsi.

Quote:

blah blah blah....gcc -D__KERNEL__ -I/usr/src/linux-2.4.20-8/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686 -nostdinc -iwithprefix include -DKBUILD_BASENAME=isapnp_proc -c -o isapnp_proc.o isapnp_proc.c
ld -m elf_i386 -r -o isa-pnp.o isapnp.o quirks.o isapnp_proc.o
rm -f pnp.o
ld -m elf_i386 -r -o pnp.o isa-pnp.o
make[3]: Leaving directory `/usr/src/linux-2.4.20-8/drivers/pnp'
make[2]: Leaving directory `/usr/src/linux-2.4.20-8/drivers/pnp'
make -C scsi
make[2]: Entering directory `/usr/src/linux-2.4.20-8/drivers/scsi'
make -C aic7xxx
make[3]: Entering directory `/usr/src/linux-2.4.20-8/drivers/scsi/aic7xxx'
make all_targets
make[4]: Entering directory `/usr/src/linux-2.4.20-8/drivers/scsi/aic7xxx'
gcc -D__KERNEL__ -I/usr/src/linux-2.4.20-8/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686 -nostdinc -iwithprefix include -DKBUILD_BASENAME=aic7xxx_osm -c -o aic7xxx_osm.o aic7xxx_osm.c
aic7xxx_osm.c:420:27: missing terminating " character
aic7xxx_osm.c:439:1: missing terminating " character
aic7xxx_osm.c: In function `ahc_linux_map_seg':
aic7xxx_osm.c:683: warning: integer constant is too large for "long" type
make[4]: *** [aic7xxx_osm.o] Error 1
make[4]: Leaving directory `/usr/src/linux-2.4.20-8/drivers/scsi/aic7xxx'
make[3]: *** [first_rule] Error 2
make[3]: Leaving directory `/usr/src/linux-2.4.20-8/drivers/scsi/aic7xxx'
make[2]: *** [_subdir_aic7xxx] Error 2
make[2]: Leaving directory `/usr/src/linux-2.4.20-8/drivers/scsi'
make[1]: *** [_subdir_scsi] Error 2
make[1]: Leaving directory `/usr/src/linux-2.4.20-8/drivers'
make: *** [_dir_drivers] Error 2


Any ideas? Is a gentoo kernel sources ebuild more than just the kernel sources (and patches)?

TIA...
Back to top
View user's profile Send private message
SickBoy
n00b
n00b


Joined: 25 Aug 2003
Posts: 67
Location: mpls, mn

PostPosted: Tue Nov 16, 2004 3:31 pm    Post subject: Reply with quote

OK, I worked around that one by setting aic7xxx to compile as a module.

It now seems to be choking on something (correct me if I am wrong) that I can't compile as a module. devfs is required to be compiled statically, correct?

Quote:
make[3]: Entering directory `/usr/src/linux-2.4.20-8/fs/cramfs'
gcc -D__KERNEL__ -I/usr/src/linux-2.4.20-8/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686 -nostdinc -iwithprefix include -DKBUILD_BASENAME=inode -c -o inode.o inode.c
gcc -D__KERNEL__ -I/usr/src/linux-2.4.20-8/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686 -nostdinc -iwithprefix include -DKBUILD_BASENAME=uncompress -I /usr/src/linux-2.4.20-8/fs/inflate_fs -c -o uncompress.o uncompress.c
rm -f cramfs.o
ld -m elf_i386 -r -o cramfs.o inode.o uncompress.o
make[3]: Leaving directory `/usr/src/linux-2.4.20-8/fs/cramfs'
make[2]: Leaving directory `/usr/src/linux-2.4.20-8/fs/cramfs'
make -C devfs
make[2]: Entering directory `/usr/src/linux-2.4.20-8/fs/devfs'
make all_targets
make[3]: Entering directory `/usr/src/linux-2.4.20-8/fs/devfs'
gcc -D__KERNEL__ -I/usr/src/linux-2.4.20-8/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -march=i686 -nostdinc -iwithprefix include -DKBUILD_BASENAME=base -DEXPORT_SYMTAB -c base.c
base.c: In function `is_devfsd_or_child':
base.c:1417: error: structure has no member named `p_opptr'
base.c:1417: error: structure has no member named `p_opptr'
make[3]: *** [base.o] Error 1
make[3]: Leaving directory `/usr/src/linux-2.4.20-8/fs/devfs'
make[2]: *** [first_rule] Error 2
make[2]: Leaving directory `/usr/src/linux-2.4.20-8/fs/devfs'
make[1]: *** [_subdir_devfs] Error 2
make[1]: Leaving directory `/usr/src/linux-2.4.20-8/fs'
make: *** [_dir_fs] Error 2
Back to top
View user's profile Send private message
SickBoy
n00b
n00b


Joined: 25 Aug 2003
Posts: 67
Location: mpls, mn

PostPosted: Wed Nov 17, 2004 3:08 pm    Post subject: Reply with quote

Needed a patched base.c source file for the devfs module. Found it here:

http://cvs.cens.ucla.edu/213/DevFS_Installation.html
Back to top
View user's profile Send private message
troycarpenter
n00b
n00b


Joined: 02 Dec 2004
Posts: 25

PostPosted: Thu Dec 02, 2004 8:04 pm    Post subject: Reply with quote

Did you ever get Clearcase working? I just started on a new project that uses clearcase and I have had nothing but trouble getting the kernel modules to compile. So I am now going down this road as well, but I don't really want a separate kernel for clearcase work than from my everyday use.

Currently when I try to compile the kernel module, I get the following:

Code:
make -C /usr/src/linux SUBDIRS=`pwd`
make[1]: Entering directory `/usr/src/linux-2.6.9-gentoo-r6'
  CC      /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_insmod_wrapper.o
ld -r -o /var/adm/rational/clearcase/mvfs/vnode_src/mvfs.kobj /var/adm/rational/clearcase/mvfs/vnode_src/mvfs.obj /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_insmod_wrapper.o
  CC [M]  /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_param.o
  CC [M]  /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_asops.o
  CC [M]  /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_dops.o
  CC [M]  /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_fops.o
  CC [M]  /var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.o
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c: In function `vnlayer_truncate_inode':
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:99: error: `ATTR_FROM_OPEN' undeclared (first use in this function)
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:99: error: (Each undeclared identifier is reported only once
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:99: error: for each function it appears in.)
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:102: error: structure has no member named `setattr_raw'
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:103: error: `ATTR_RAW' undeclared (first use in this function)
/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.c:105: error: structure has no member named `setattr_raw'
make[2]: *** [/var/adm/rational/clearcase/mvfs/vnode_src/mvfs_linux_glue.o] Error 1
make[1]: *** [_module_/var/adm/rational/clearcase/mvfs/vnode_src] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.9-gentoo-r6'
make: *** [all] Error 2


A google on ATRR_FROM_OPEN doesn't reveal very much.

I did get the module to comple once, but I modified much of the source to use the 2.4 code instead of the 2.6 changes. The module loaded, but there was a kernel OOPs when I started the clearcase processes. Clearcase then claimed that the modules were not loaded, and I couldn't rmmod them because they were "busy".
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum