
No. I tried again the following for the thread.cpp: robert@ubuntu:~/boost$ g++ -L /home/robert/src/boost_1_43_0 -lboost_thread thread.cpp -o thread and got the following complaints: thread.cpp:2:35: error: boost/thread/thread.hpp: No such file or directory thread.cpp: In function ‘int main(int, char**)’: thread.cpp:12: error: ‘boost’ has not been declared thread.cpp:12: error: expected ‘;’ before ‘thrd’ thread.cpp:13: error: ‘thrd’ was not decon > If I try robert@ubuntu:~/boost$ g++ -L/usr/local -lboost_thread thread.cpp -o thread I got: thread.cpp:2:35: error: boost/thread/thread.hpp: No such file or directory thread.cpp: In function ‘int main(int, char**)’: thread.cpp:12: error: ‘boost’ has not been declared thread.cpp:12: error: expected ‘;’ before ‘thrd’ thread.cpp:13: error: ‘thrd’ was not dec5 Currently there is nothing under directory /usr/local/lib that is related to boost: robert@ubuntu:/usr/local/lib$ ls -l total 4 drwxrwsr-x 4 root staff 4096 2010-05-31 08:10 python2.6 but there is one lib directory as in: /home/robert/src/boost_1_43_0 -lboost_thread/lib I got nothing when checking out what boost packages I've already installed with: $ dpkg -l | grep boost Any further hints? Thanks. On Thu, Jun 17, 2010 at 9:36 AM, Steven Watanabe <watanabesj@gmail.com>wrote:
AMDG
Boost lzw wrote:
<snip>
but failed to compile thread.cpp program with robert@ubuntu:~/boost$ g++ -I /home/robert/src/boost_1_43_0 thread.cpp -o thread
-L/usr/local/lib -lboost_thread
for the following thread.cpp
=================== <snip>
===================
The first few complaints I got are: ---------------------------------------------- /tmp/ccwgSZ3d.o: In function `main': thread.cpp:(.text+0x6e): undefined reference to `boost::thread::join()' thread.cpp:(.text+0x7f): undefined reference to `boost::thread::~thread()' thread.cpp:(.text+0xa0): undefined reference to `boost::thread::~thread()' /tmp/ccwgSZ3d.o: In function `boost::detail::thread_data_base::thread_data_base()': How can I compile boost::thread separately for it to work? Thanks a lot.
It looks like you already did
(4)
robert@ubuntu:~/src/boost_1_43_0$ sudo ./bootstrap.sh --prefix=/usr/local --show-libraries --with-libraries=all --exec-prefix=/usr/local/bin/
(5) ./bjam install
In Christ, Steven Watanabe
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users