I am using Ubuntu 10.04 LTS with kernel 2.6.32-21-generic , and Ubuntu 10.04.4 LTS with kernel 2.6.32-38-generic.

While I am trying to compile the source for both kernel version - 2.6.32-21-generic and 2.6.32-38-generic, I got following error.

" error: .size expression for do_hypervisor_callback does not evaluate to a constant "

make[2]: *** [arch/x86/kernel/entry_64.o]

[arch/x86/kernel] Error 2

make: * [arch/x86] Error 2Error 1 make[1]: *

While searching in internet, several places I have seen the questions, but no answer except mentioning it is a bug . I am wondering Ubuntu 10.04 LTS is a stable version, but kernel has bug that too so many users pointed out about the bug.

Can anyone help me to figure out stable kernel version 2.6 source code so that I can download/compile the source code for 2.6 kernel and do my OS assignment.

BTW, I can't use kernel 3.0 , although Ubuntu 12.04 LTS has kernel 3.11.0-15 and I am successfully able to compile that kernel, but I need to compile kernel 2.6 for my work.

So should I go with Arch-Linux(Fedora) or stick to Ubuntu ?

So it will be great if any clue how to successfully compile kernel 2.6 or find a stable kernel 2.6 . Thanks in advance :)

  • The linux kernel is in the same place it always is kernel.org – Ramhound Mar 28 '14 at 10:49
  • @Ramhound how to solve the compilation error ? Should I use patch ? Can I use other kernel version ( like available in kernel.org) in Ubuntu 10.04? – bholanath Mar 28 '14 at 11:07
  • The current error your getting is a compiler error. It also seems incomplete. Are you making modifications because its odd source code that in theory was compiled and released months ago has an error in it. – Ramhound Mar 28 '14 at 11:43
  • @Ramhound I have modified in one source file and then trying to execute "make" command. At that time I was getting that error. Yah it's a compiler error. – bholanath Mar 28 '14 at 13:50
  • @Ramhound I have downloaded kernel source from the kernel.org and now while executing make command the error is not there. It is still going on, looks like it is building the kernel. Don't know how much time it will take , but I am happy that it is working now. Thank you so much. – bholanath Mar 28 '14 at 13:54

This looks more like an issue with XEN in your .config file. This happened to be before, and got resolved by disabling this part. Search for


and change it to


Happy compiling.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.