Hi,
I am having trouble compiling a correct version of the boost thread
library on a x86_64 Fedora Core 8 and was wondering if anyone can help
me out. I've tried both version 1.37 and 1.39. I describe below what I
do and what happens after that.
I am on an AMD64 Fedora Core 8 platform (with gcc 4.1.2 and glibc 2.7)
that already had boost 1.34 on it at /usr/lib level. I erased that
version by deleting all the libraries and moving 'boost' directory in
/usr/include to 'boost_1-34' directory. I download the .gz tarball,
bootstrap it, make it (with make for 1.37 and bjam for 1.39) and
install it to /usr/local/lib. The compilation goes without a hitch
(except for some warnings for boost serialization and others, but not
for thread). I have both .a and .so files generated and residing in
/usr/local/lib and boost include files in /usr/local/include. I add
the links libboost_thread-mt.a and libboost_thread-mt.so to point to
libboost_thread-gcc41-mt_1.3x.* libs.
Now, I write a small test program (given below). It gives me linker
errors with undefined references to pretty much every pthread symbol.
If anyone wants I can paste all the errors in the next message. When I
add the -lpthread flag to the compile, it gives me an undefined
reference error with regards to __vdso_clock_gettime from
/lib64/libpthread.a.
I'm not sure where exactly the problem lies and would greatly
appreciate if someone could point me in the right direction. Thank
you.
regards,
Kishalay
My test program: compiled with: gcc -o testk test.cpp -lboost_thread-mt
#include <cstdio>
#include <cstdlib>
#include