What is the exact content of an obj file in C ?
NOTE : [This question was asked by Cool boy]
What is the exact content of an obj file in C ?
NOTE : [This question was asked by Cool boy]
The aim of the C Programming is to produce an independent executable code. It happens in two steps e.g. Compiling & Linking.
After compilation the “Source code” (which is written by a programmer) gets converted in to “Object code” which is placed in a file called Object File.
“Object Code” is just the translation of “Source Code”, which can be referred as machine language code.
But it is not the complete executable code, which can run alone unless included with “Startup code”(it is an Operating System specific code requires to start the program, as different OS handles execution of programs differently) & “Library codes” (it contains object code for many library functions, which are used widely in "Source code" e.g. printf(), scanf(), etc..).
The next step i.e. linking takes responsibility to include “Startup code” & the required pre-compiled codes from “Library files” to create a complete executable program.
Thanks,
Niladri
a loe level language code or compiled code
hi,
if u compile source code automatically obj file is created.
It contains machine understandable language(ie., low level language) only machine purpose.