Boost logo

Boost Testing :

From: David Abrahams (dave_at_[hidden])
Date: 2007-03-30 23:59:55


on Fri Mar 30 2007, "Caleb Epstein" <caleb.epstein-AT-gmail.com> wrote:

> On 3/30/07, David Abrahams <dave_at_[hidden]> wrote:
>
>> According to the latest test results, it looks like python.jam is
>> adding an extra -lpthread :(.
>>
>> So I can remove that, but it also is not adding any of -lresolv,
>> -lsocket, or -lnsl. The earlier error messages seemed to indicate
>> that it was OK. I wonder why? I'm inclined not to add them to the
>> jam file in case some other sunos installation complains like yours
>> did about -lpthread.
>
> I don't see an extra -lpthread

See below in the command line you yourself pasted into your email.

> (maybe that was yesterday?), but I have
> never seen this error from today's run before:
>
> /openpkg/bin/ld:
> /home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/build/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off/libboost_python-gcc41-d-1_34.so.1.34.0:
> pthread_getspecific: invalid version 2 (max 0)
> /home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/build/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off/libboost_python-gcc41-d-1_34.so.1.34.0:
> could not read symbols: Bad value

My guess is that pthreads are already statically linked into the
executable, and the library search picked up a different version.

> Link [2007-03-29 11:43:05 UTC]: fail
>
> "/openpkg/bin/g++" -L"/openpkg/lib"
> -L"/openpkg/lib/python2.5/config" -Wl,-R
> -Wl,"/home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/build/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off"
> -Wl,-rpath-link
> -Wl,"/home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/build/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off"
> -o "/home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/test/bases.test/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off/bases"
> -Wl,--start-group
> "/home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/test/bases.test/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off/bases.o"
> "/home/cae/boost-regression/RC_1_34_0/results/boost/bin.v2/libs/python/build/gcc-4.1.1_sunos_i86pc/debug/debug-symbols-off/libboost_python-gcc41-d-1_34.so.1.34.0"
> -lpython2.5 -lrt -lpthread -ldl -Wl,--end-group -Wl,--strip-all
                     ^^^^^^^^^

That -lpthread is not specified in the result you said you get from
distutils.sysconfig.get_config_var('LIBS')

On the other hand, I can't find any documentation that says
distutils.sysconfig.get_config_var('LIBS') should be in the link lines
for extension modules and/or embedding applications.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com
Don't Miss BoostCon 2007! ==> http://www.boostcon.com

Boost-testing list run by mbergal at meta-comm.com