Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have downloaded the top source code from the following location.

After extracting the code, i run the following command:


cc -DHAVE_CONFIG_H  -I. -I. -I /usr/src/linux-headers-3.5.0-19/arch/alpha  -g -O2 -Wall   -fno-strict-aliasing -o m_linux.o -c ./machine/m_linux.c
  ./machine/m_linux.c:71:44: fatal error: asm/page.h: No such file or directory
compilation terminated.

make: *** [m_linux.o] Error 1

Please help

share|improve this question
top is already part of Ubuntu why compile it from a source that is almost two years old? – Meer Borg Mar 12 '13 at 5:25

Install the necessary build tools first:

apt-get install build-essential automake

Tip: if you are interested in playing with the top source code, why not take the version included in your Ubuntu environment?

apt-get source procps

Then, to build just the binaries, go into the directory where it was unpacked and do:

debian/rules clean
debian/rules build
share|improve this answer

if you are just interested in compiling top, here is one thing I did:

I googled for top source code and found in

that the The source and homepage for procps utilities can be found here

then I did:

    tar xzf procps-3.2.7.tar.gz
    cd procps-3.2.7/
    make SHARED=0 DESTDIR=$HOME install
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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