title: coredump file get line number to a shared library
body: <p>I'm using gdb to analyze a core dump file. The executable is linked to a shared library, both the executable and shared library is compiled with <code>-g</code> flag, in the <code>bt</code> I can see the line num in executable, but not the shared library. Any idea to solve this?</p>
  <p>I open the core file in this way:</p>
  <pre><code>gdb /path/to/executable /path/to/core/file
  </code></pre>
  <pre><code>(gdb) bt
  #0  0x00007f4e7711b438 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
  #1  0x00007f4e7711d03a in __GI_abort () at abort.c:89
  #2  0x00007f4e7858b8b1 in std::pair&lt;tsmap3::NearestPtResult, double&gt; tsmap3::IndexTree::GetNearestPt2&lt;tsmap3::LaneImpl&gt;(tsmap3::Point3d const&amp;, tsmap3::Point3d const&amp;, double, std::function&lt;tsmap3::NearestPtResult (tsmap3::Point3d const&amp;, tsmap3::LaneImpl const*)&gt;, std::function&lt;bool (tsmap3::LaneImpl const*)&gt;, std::unordered_set&lt;unsigned long, std::hash&lt;unsigned long&gt;, std::equal_to&lt;unsigned long&gt;, std::allocator&lt;unsigned long&gt; &gt;&amp;) const () from /home/ziqi.liu/code/map-lane-map3/build/src/tsmap3.cpython-35m-x86_64-linux-gnu.so
  #3  0x00007f4e784d93a0 in tsmap3::NearestPtResult tsmap3::GridSystem::GetNearestPt&lt;tsmap3::LaneImpl&gt;(tsmap3::Point3d const&amp;, double, std::function&lt;tsmap3::NearestPtResult (tsmap3::Point3d const&amp;, tsmap3::LaneImpl const*)&gt; const&amp;, std::function&lt;bool (tsmap3::LaneImpl const*)&gt; const&amp;) () from /home/ziqi.liu/code/map-lane-map3/build/src/tsmap3.cpython-35m-x86_64-linux-gnu.so
  #4  0x00007f4e784bf201 in tsmap3::TSMapImpl::GetNearestRefPt(tsmap3::Point3d const&amp;, double, std::vector&lt;tsmap3::Lane::Property, std::allocator&lt;tsmap3::Lane::Property&gt; &gt; const&amp;, bool) const ()
     from /home/ziqi.liu/code/map-lane-map3/build/src/tsmap3.cpython-35m-x86_64-linux-gnu.so
  #5  0x00007f4e78537fb3 in tsmap3::TSMap::GetNearestRefPt(tsmap3::Point3d const&amp;, double, std::vector&lt;tsmap3::Lane::Property, std::allocator&lt;tsmap3::Lane::Property&gt; &gt; const&amp;, bool) const ()
     from /home/ziqi.liu/code/map-lane-map3/build/src/tsmap3.cpython-35m-x86_64-linux-gnu.so
  #6  0x00000000004230d2 in main (argc=&lt;optimized out&gt;, argv=&lt;optimized out&gt;) at /home/ziqi.liu/code/map-lane-map3/examples/bench_get_nearest_ref_pt.cpp:54
  </code></pre>
  <p>the <code>/home/ziqi.liu/code/map-lane-map3/build/src/tsmap3.cpython-35m-x86_64-linux-gnu.so</code> is the so file for shared library.</p>
  <p>I do have the source files for that shared library, I guess I need to hint the gdb where to find the source files somehow</p>