title: ELF File generation commands and options
body: <p>I was reading about ELF files on the net and am stuck in understanding a standard command to generate an ELF file. </p>
  
  <p>Till now I have been running my code using > gcc test.c -o test.o .Thats it!!</p>
  
  <p>One article says:</p>
  
  <blockquote>
    <p>gcc -c test.c // will generate ELF file test.o</p>
  </blockquote>
  
  <p>Now -o option is to tell the compiler to create an executable ( which is not ELF)</p>
  
  <p>Another <a href="http://www.thegeekstuff.com/2012/07/elf-object-file-format/" rel="nofollow">article</a> says:</p>
  
  <blockquote>
    <p>gcc -c test.c -o test.o // will generate ELF test.o -> here's where I am confused.</p>
  </blockquote>
  
  <p>-o should always generate Executable.</p>