title: How do I statically link external libraries into my executable?
body: <p>I don't want to have the end use have to have the libraries installed, so, having the libraries packaged in my exec would be preferred. </p>
  
  <p>this is the relevant line in the make file: </p>
  
  <pre><code>hPif : src/main.o src/fann_utils.o src/hashes.o src/Config.o
      g++ -o  hPif src/main.o src/fann_utils.o src/hashes.o src/Config.o -static -lfann -lboost -L/usr/local/lib 
  </code></pre>
  
  <p>I'm trying to link fann and boost, and I read somewhere (http://www.adp-gmbh.ch/cpp/gcc/create_lib.html)  that using the -static flag allows that.</p>
  
  <p>What am I doing wrong?</p>