title: Linker not recognizing symbols present in library
body: <p>I've got an object file which I'm trying to link.  It references symbols defined in a .so file which I created.  My command is (something like)</p>
  <pre><code>gcc -L$(PWD)/some_dir -lmylibrary -o program program.o
  </code></pre>
  <p>where libmylibrary.so is found in <code>$(PWD)/some_dir</code>.</p>
  <p>program.o was created with</p>
  <pre><code>gcc -std=gnu99 -g -O3 -c program.c -I$(SOME_DIR)
  </code></pre>
  <p>I get a linker error that the following symbols could not be found: <code>nodeSplitSize</code>, <code>yyparse</code>, <code>programTree</code></p>
  <p>However, running</p>
  <pre><code>nm -gD some_dir/libmylibrary.so
  </code></pre>
  <p>yields</p>
  <pre><code>...
  0000000000004d90 T nodeSplitSize
  ...
  0000000000005610 T yyparse
  ...
  000000000021eaa0 B programTree
  ...
  </code></pre>
  <p>If it helps, <code>nodeSplitSize</code> and <code>yyparse</code> are functions whereas <code>programTree</code> is a global, uninitiated variable.</p>