Results 1 to 10 of 15
I'm trying to compile my own debian kernel package.
I was doing this originally out of boredom, and now out of necessity .
Thing is, I'm using linux-source-2.6.15 (or 2.6.16, ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 06-01-2006 #1Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
Debian 2.6.15/2.6.16 compile error
I'm trying to compile my own debian kernel package.
I was doing this originally out of boredom, and now out of necessity .
Thing is, I'm using linux-source-2.6.15 (or 2.6.16, I've been experimenting with both). I untar the source, then I do the highly recommended copy of the /boot/config-<kernel version> to /usr/src/<source>/.config since I'm compiling a variation of the exact same version I have installed. I then changed the one thing I wanted, and the on thing I needed: Compiled it optimised for K6/k6II/k6III and added off-board IDE first=y.
make-kpkg kernel_image
invariably a NIC driver of some sort, lately the realtek?8139?cp drivers, kill the compile with error 2. The odd thing is that I have a computer running this exact version of the kernel supplied by debian using a NIC that needs that driver. So if it compiled for the debian maintainers... why won't it compile for me?
It's a debian etch system I'm compiling from. I've successfully compiled 2.6.8 kernels, but nothing beyond that point has ever worked. I'd just have it not compile the rt driver, but 1) I do have a card with that chipset 2) all that does is cause a different NIC (sometimes one that didn't error with the rt being allowed) to error.
I'm confused. Could someone please explain this? Could someone please tell me WTF I can do to fix it?
Oh, and yeah, I tried to start with the default .config. Turns out that 2.6.15+ uses /boot/config-<kernel> as the default .config so that didn't work.
- 06-01-2006 #2
Did you try it like that?
Add yourself to the "src" group:
Then log out and log in so the group changes takes effect.Code:su adduser yourself src
Make sure you are up-to-date:
Install the needed packages:Code:su apt-get update apt-get dist-upgrade
Log out and log in so the "group" change takes effect, and then:Code:apt-get install build-essential debhelper devscripts dh-make module-assistant kernel-package libncurses-dev bzip2 fakeroot
Something like that usualy works. Plus make sure your /etc/modules file is OK and the modules are in the right order before doing the compilation.Code:cd wget ftp://kernel.org/pub/linux/kernel/v2.6/linux-2.6.16.19.tar.bz2 cd /usr/src tar jxf ~/linux-2.6.16.19.tar.bz2 cd linux-2.6.16.19/ make mrproper cp /boot/config-$(uname -r) .config make menuconfig fakeroot make-kpkg clean fakeroot make-kpkg --append-to-version "-my-kernel" --revision "01062006" --us --uc --initrd kernel_image cd .. su dpkg -i linux-image-2.6.16.19-my-kernel_01062006_i386.deb
"To express yourself in freedom, you must die to everything of yesterday. From the 'old', you derive security; from the 'new', you gain the flow."
-Bruce Lee
- 06-01-2006 #3Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
I'm lazy, I just do the whole compilation as root.
I should like to think so, I had aptitude install everything require and suggested by both the source and make-kpkg.
I didn't grab the source code from kernel.org. Don't know why. I think because... well.. again I'm lazy. simpler to type apt-get install linux-source-2.6.<whichever I want>.
- 06-01-2006 #4To compile as root is pure evil, try not too
Originally Posted by dravenloft 
I just like better the vanilla sources, as the Debian ones are simply being cleaned up of too many drivers (because of licencing issues):
Originally Posted by dravenloft
http://wiki.debian.org/KernelFirmwareLicensing"To express yourself in freedom, you must die to everything of yesterday. From the 'old', you derive security; from the 'new', you gain the flow."
-Bruce Lee
- 06-01-2006 #5Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
Ok, not doing some things as root I understand. I mean, it's easy for attacks, etc. But why not compile a kernel? And other forms of compiling?
Originally Posted by antidrugue
Ah. Well... still might give it a try. Maybe cleaning out the drivers that have licencing issues destabilised something.I just like better the vanilla sources, as the Debian ones are simply being cleaned up of too many drivers (because of licencing issues):
http://wiki.debian.org/KernelFirmwareLicensing
- 06-01-2006 #6I just like to make an habit of not doing things as root whenever possible. A mistake happens so fast, you never know.
Originally Posted by dravenloft "To express yourself in freedom, you must die to everything of yesterday. From the 'old', you derive security; from the 'new', you gain the flow."
-Bruce Lee
- 06-02-2006 #7Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
Good point. I guess I never think of it that way because I only use root to compile kernels, edit txt configs and to run those lovely GUI configs that require Admin access. Basically I just su, do what I need exit instead of fakeroot or sudo the same things.
- 06-03-2006 #8Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
Ok... I've tried the source from apt, this one I just downloaded yesterday from kernel.org. Why do they all do that? Every version from 2.6.11 to present that I've tried to compile do this. I think this is the majority point of failure, although I do know that I've failed before and after it at various points (no particular version just sometimes happens)... thing is ... well... there're kernels compiled with this driver as either =y or =m I'm running one from apt as I type this. I'm confused.Code:CC [M] drivers/net/3c515.o CC [M] drivers/net/eexpress.o In file included from drivers/net/eexpress.c:116: include/linux/mca-legacy.h:12:2: warning: #warning "MCA legacy - please move your driver to the new sysfs api" CC [M] drivers/net/eepro.o CC [M] drivers/net/8139cp.o drivers/net/8139cp.c: In function 'read_eeprom': drivers/net/8139cp.c:1659: error: unable to find a register to spill in class 'CREG' drivers/net/8139cp.c:1659: error: this is the insn: (insn:HI 15 14 16 0 (parallel [ (set (reg:SI 1 dx [97]) (ashift:SI (reg:SI 1 dx [97]) (subreg:QI (reg/v:SI 3 bx [orig:95 addr_len ] [95]) 0))) (clobber (reg:CC 17 flags)) ]) 398 {*ashlsi3_1} (insn_list:REG_DEP_TRUE 6 (insn_list:REG_DEP_TRUE 14 (nil))) (expr_list:REG_UNUSED (reg:CC 17 flags) (expr_list:REG_UNUSED (reg:CC 17 flags) (expr_list:REG_EQUAL (ashift:SI (const_int 6 [0x6]) (subreg:QI (reg/v:SI 3 bx [orig:95 addr_len ] [95]) 0)) (nil))))) drivers/net/8139cp.c:1659: confused by earlier errors, bailing out make[3]: *** [drivers/net/8139cp.o] Error 1 make[2]: *** [drivers/net] Error 2 make[1]: *** [drivers] Error 2 make[1]: Leaving directory `/usr/src/linux-2.6.16' make: *** [debian/stamp-build-kernel] Error 2
- 06-03-2006 #9
Why not just disable the "8139cp" module in "make menuconfig" before compiling?
You can find it like that:
You can even disable the whole [*] EISA, VLB, PCI and on board controllers thing if you don't need any card in it.
Originally Posted by make menuconfig
You probably having this error with all kernel because you are using the same config file to compile all of them."To express yourself in freedom, you must die to everything of yesterday. From the 'old', you derive security; from the 'new', you gain the flow."
-Bruce Lee
- 06-03-2006 #10Just Joined!
- Join Date
- Jun 2006
- Posts
- 50
because I have an rt8139cp card
Originally Posted by antidrugue
I leave them because I have cards I sometimes use there.You can even disable the whole [*] EISA, VLB, PCI and on board controllers thing if you don't need any card in it.
actually no. I use either the most up to date /boot/config-<kernel> or I let it use the default. Sometimes I take one or the other and go through making changes to it to remove devices I don't have and never will. Admittedly that one itme is always there... but I need it to be.You probably having this error with all kernel because you are using the same config file to compile all of them.


Reply With Quote
