title: How to determine why text size in my library is so huge?
body: <p>I have a shared library file built using the Android NDK for ARM. There is also a little bit of JNI in there. This SO file is linked against many other .a files (our own static libraries we build as dependencies) as well as a few other third party static libraries, such as boost.</p>
  
  <p>I am using GCC 4.8 and utilizing STL with C++11 features.</p>
  
  <p>I have done some self research on this. In particular, I came across this thread:<br>
  <a href="https://stackoverflow.com/questions/2839172/why-my-c-output-executable-is-so-big">why my C++ output executable is so big?</a></p>
  
  <p>That helped me figure out a few commands to run such as <code>size</code>:</p>
  
  <pre><code>$ size libmine.so
     text    data     bss     dec     hex filename
  13017993         201972   54120 13274085         ca8be5 libmine.so
  </code></pre>
  
  <p>Unfortunately though, other than the commands to run, the linked SO question didn't help me much on the diagnostic side (Or perhaps maybe I am just not experienced enough with linux-style development to use the information reliably). I am not sure how to analyze the results produced in such a way that it would help me pinpoint the areas of code, specific libraries, or template functions/classes/etc that are causing any growth.</p>
  
  <p>The shared library itself is 13MB, which is pretty huge. I did verify that my .SO file is "stripped", which I guess means no debug symbols. At this point I'm not sure if this is due to boost or some crazy template instantiation. How can I determine what is contributing to the massive growth of my shared library?</p>