next up previous

2.0.4 Notes on Compiling

into machine language, or object code. Compare the computer to a foreigner. The computer speaks and understands its own language, but the computer does not understand your language. Most people do not speak or understand the computer's language. Therefore, we program in a higher level language which we can understand, and then use a translator, a compiler, to translate what we have written into a form the computer can understand. This version of your code is called object code. The object code will be in filename .o, where filename is the name of the file you compiled (minus the appropriate extension).

After the object code has been created, the compiler then links the code with the necessary library routines. Often library routines are required in a program. Math functions are often in a library which need to be linked with your program before you can run it.

The result is an executable file, which can be run on a computer.