Thanks Kris, that should be the correct solution, except it doesn’t fix the problem entirely. Here is my boost/ilb directory which I pass with the –L flag…
/boost/1.44.0/lib/libboost_program_options-gcc41-1_44.a
/boost/1.44.0/lib/libboost_program_options-gcc41-1_44.so
/boost/1.44.0/lib/libboost_program_options-gcc41-1_44.so.1.44.0
/boost/1.44.0/lib/libboost_program_options-gcc41-d-1_44.a
/boost/1.44.0/lib/libboost_program_options-gcc41-d-1_44.so
/boost/1.44.0/lib/libboost_program_options-gcc41-d-1_44.so.1.44.0
/boost/1.44.0/lib/libboost_program_options-gcc41-d.a
/boost/1.44.0/lib/libboost_program_options-gcc41-d.so
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-1_44.a
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-1_44.so
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-1_44.so.1.44.0
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-d-1_44.a
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-d-1_44.so
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-d-1_44.so.1.44.0
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-d.a
/boost/1.44.0/lib/libboost_program_options-gcc41-mt-d.so
/boost/1.44.0/lib/libboost_program_options-gcc41-mt.a
/boost/1.44.0/lib/libboost_program_options-gcc41-mt.so
/boost/1.44.0/lib/libboost_program_options-gcc41.a
/boost/1.44.0/lib/libboost_program_options-gcc41.so
And even though I tell it where to look, it does not find -lboost_program_options. So I am wondering if this is a version mismatch? Or if the source code for
the application needs to be changed?
Salman
From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org]
On Behalf Of Krzysztof Czainski
Sent: Tuesday, March 13, 2012 6:54 PM
To: boost-users@lists.boost.org
Subject: Re: [Boost-users] boost error
2012/3/14 Pervez, Salman <Salman.Pervez@citadelgroup.com>
Hi everyone, I am trying to do a source build for qpid 0.14. I am running into a boost dependency error which I am unable to solve. Here is the error...
/usr/bin/ld: cannot find -lboost_program_options
collect2: ld returned 1 exit status
make[2]: *** [libqpidcommon.la] Error 1
I also built boost from source so its no surprise that it cannot find the required file in /usr/bin/ld. Perhaps there is a way to tell it where to find boost? I passed the location of my boost build to the configure script through a CPPFLAG which helps it
find the hpp files but perhaps not this one.
I'm guessing here: try adding -L/path/to/the/boost/libs to LDFLAGS.
An aside note: I thought compiler flags go into CXXFLAGS instead of CPPFLAGS, because CPP usually stands for the preprocessor in makefiles, while CXX stands for the c++ compiler.
HTH
Kris