title: linker error: undefined symbol _sum in module my.c
body: <p>I am getting following error when I add user defined method in library using turbo c
      <strong>linker error</strong>: <code>undefined symbol _sum in module my.c</code>
  I followed all steps properly:</p>
  
  <pre><code> // 1. create addition.c containing function definatio and compile it
  </code></pre>
  
  <p>addition.c:</p>
  
  <pre><code> addition(int i, int j)
    {
    int total;
   total = i + j;
   return total;
   }
  </code></pre>
  
  <p>Step 2:</p>
  
  <p>Compile <code>addition.c</code> file by using <code>Alt + F9</code> keys (in turbo C)
  <code>addition.obj</code> file would be created which is the compiled form of <code>addition.c</code> file.</p>
  
  <p>Step 3:
  Add it to library using <code>tlib</code></p>
  
  <pre><code>c:\&gt; tlib math.lib + c:\ addition.obj
  </code></pre>
  
  <p>Means adding <code>c:\addition.obj</code> file in the math library.</p>
  
  <p>Step 4:
  Created a file <code>addition.h</code> &amp; declare prototype of <code>addition()</code> function like below.</p>
  
  <pre><code> int addition (int i, int j);
  </code></pre>
  
  <p>Now <code>addition.h</code> file containing prototype of function <code>addition</code>.</p>
  
  <pre><code># include &lt;stdio.h&gt;
       // Including our user defined function.
       # include “c:\\addition.h”     
     int main ()
     {
     int total;
     // calling function from library
     total = addition (10, 20); 
     printf ("Total = %d \n", total);
      }
  </code></pre>