Where is my boost lib file?

If you are on a 64bit machine then you will probably find the files under /usr/lib/x86_64-linux-gnu/

See also this for an explanation of what this folder is for.


I'm not sure if this is what you're looking for, but you probably want to install libboost-all-dev.

$ ls /usr/lib/libboost*.so

/usr/lib/libboost_date_time-mt.so
/usr/lib/libboost_date_time.so
/usr/lib/libboost_filesystem-mt.so
/usr/lib/libboost_filesystem.so
/usr/lib/libboost_graph-mt.so
/usr/lib/libboost_graph_parallel-mt.so
/usr/lib/libboost_graph_parallel.so
/usr/lib/libboost_graph.so
/usr/lib/libboost_iostreams-mt.so
/usr/lib/libboost_iostreams.so
/usr/lib/libboost_math_c99f-mt.so
/usr/lib/libboost_math_c99f.so
/usr/lib/libboost_math_c99l-mt.so
/usr/lib/libboost_math_c99l.so
/usr/lib/libboost_math_c99-mt.so
/usr/lib/libboost_math_c99.so
/usr/lib/libboost_math_tr1f-mt.so
/usr/lib/libboost_math_tr1f.so
/usr/lib/libboost_math_tr1l-mt.so
/usr/lib/libboost_math_tr1l.so
/usr/lib/libboost_math_tr1-mt.so
/usr/lib/libboost_math_tr1.so
/usr/lib/libboost_mpi-mt.so
/usr/lib/libboost_mpi.so
/usr/lib/libboost_prg_exec_monitor-mt.so
/usr/lib/libboost_prg_exec_monitor.so
/usr/lib/libboost_program_options-mt.so
/usr/lib/libboost_program_options.so
/usr/lib/libboost_python-mt-py27.so
/usr/lib/libboost_python-mt-py32.so
/usr/lib/libboost_python-py27.so
/usr/lib/libboost_python-py32.so
/usr/lib/libboost_python.so
/usr/lib/libboost_regex-mt.so
/usr/lib/libboost_regex.so
/usr/lib/libboost_serialization-mt.so
/usr/lib/libboost_serialization.so
/usr/lib/libboost_signals-mt.so
/usr/lib/libboost_signals.so
/usr/lib/libboost_system-mt.so
/usr/lib/libboost_system.so
/usr/lib/libboost_thread-mt.so
/usr/lib/libboost_thread.so
/usr/lib/libboost_unit_test_framework-mt.so
/usr/lib/libboost_unit_test_framework.so
/usr/lib/libboost_wave-mt.so
/usr/lib/libboost_wave.so
/usr/lib/libboost_wserialization-mt.so
/usr/lib/libboost_wserialization.so

For me, the library path for boost was in /usr/lib64, and that's all I had to add to my library path for the code to build properly. On a different machine, I found it installed under /usr/lib.

If locate is available to you on your system, then try these for locating boost:

locate boost | fgrep .so   #find lib files      (/usr/lib64 for me)
locate boost | fgrep .hpp  #find include files  (/usr/include for me)