Message60899
According to Boris Gubenko from the HP-UX compiler
development team, it is illegal to link with -lpthread
if the sources are not compiled with -mt. However, this
is exactly what happens during Python installation, e.g.:
cc -Ae -c -DNDEBUG -O -I. -I./Include
-DPy_BUILD_CORE -o Python/compile.o Python/compile.c
...
aCC -Wl,-E -Wl,+s -o python \
Modules/python.o \
libpython2.5.a -lnsl -lrt -ldld
-ldl -lpthread -lm
This illegal combination of compilation and link flags
eventually results in obscure runtime failures
(segfault, abort) while running Boost.Python C++
extensions. These failures go away if Python is
installed with, e.g.:
env CXX="aCC -mt" BASECFLAGS="-mt" ./configure
--without-gcc
I suggest changing the configure/make files to always
include "-mt" if threading is enabled.
BTW: The same issue already exists for Python 2.4.
Cheers,
Ralf
|
|
Date |
User |
Action |
Args |
2008-01-20 09:58:39 | admin | link | issue1465838 messages |
2008-01-20 09:58:39 | admin | create | |
|