[Python-Dev] Python build trouble with the new gcc/binutils
Andrew Koenig
ark@research.att.com
Fri, 16 Aug 2002 14:43:05 -0400 (EDT)
Zack> Can you disable all use of dynamic loading and try the build
Zack> again? Unfortunately, the only practical way to do this seems
Zack> to be to edit configure.in and force DYNLOADFILE to be
Zack> dynload_stub.o (right before the line saying
Zack> AC_MSG_RESULT($DYNLOADFILE)), then regenerate configure. (Might
Zack> be a good idea to add an --enable switch.)
As I sort of expected, this makes the crash go away. However, it is now
replaced by lots of messages like
building 'grp' extension
gcc -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -I. -I/export/spurr1/homes1/ark/Python-2.2.1/./Include -I/usr/local/include -IInclude/ -c /export/spurr1/homes1/ark/Python-2.2.1/Modules/grpmodule.c -o build/temp.solaris-2.7-sun4u-2.2/grpmodule.o
gcc -shared build/temp.solaris-2.7-sun4u-2.2/grpmodule.o -L/usr/local/lib -o build/lib.solaris-2.7-sun4u-2.2/grp.so
WARNING: removing "grp" since importing it failed
If I put back the dynamic loading stuff and rebuild everything from scratch,
I again get a python that crashes when I try to import struct.
It occurs to me that the traceback from that might be useful.
Needless to say, it is much shorter than the earlier one.
I must say that the "Address 0x2 out of bounds" note makes me suspicious.
Here's the traceback:
#0 __register_frame_info_bases (begin=0xfed40000, ob=0xfed40000, tbase=0x0,
dbase=0x0) at /tmp/build1165/gcc-3.1.1/gcc/unwind-dw2-fde.c:83
#1 0xfed417ec in frame_dummy ()
from /export/spurr1/homes1/ark/test-python/Python-2.2.1/build/lib.solaris-2.7-sun4u-2.2/struct.so
#2 0xfed416d4 in _init ()
from /export/spurr1/homes1/ark/test-python/Python-2.2.1/build/lib.solaris-2.7-sun4u-2.2/struct.so
#3 0xff3bc174 in ?? ()
#4 0xff3c0a8c in ?? ()
#5 0xff3c0ba8 in ?? ()
#6 0x0007b384 in _PyImport_GetDynLoadFunc (fqname=0x2 <Address 0x2 out of bounds>,
shortname=0x1002d0 "",
pathname=0xffbeedb8 "/export/spurr1/homes1/ark/test-python/Python-2.2.1/build/lib.solaris-2.7-sun4u-2.2/struct.so", fp=0xfc1e0) at Python/dynload_shlib.c:90
#7 0x0006edd8 in _PyImport_LoadDynamicModule (name=0xffbef2a8 "struct",
pathname=0xffbeedb8 "/export/spurr1/homes1/ark/test-python/Python-2.2.1/build/lib.solaris-2.7-sun4u-2.2/struct.so", fp=0xfc1e0) at Python/importdl.c:42
#8 0x0006b63c in load_module (name=0xffbef2a8 "struct", fp=0xfc1e0,
buf=0xffbeedb8 "/export/spurr1/homes1/ark/test-python/Python-2.2.1/build/lib.solaris-2.7-sun4u-2.2/struct.so", type=3) at Python/import.c:1365
#9 0x0006c4e4 in import_submodule (mod=0xe08c0, subname=0xffbef2a8 "struct",
fullname=0xffbef2a8 "struct") at Python/import.c:1895
#10 0x0006c008 in load_next (mod=0xe08c0, altmod=0xe08c0, p_name=0xffbef2a8,
buf=0xffbef2a8 "struct", p_buflen=0xffbef2a4) at Python/import.c:1751
#11 0x0006de54 in import_module_ex (name=0x0, globals=0xe08c0, locals=0x111548,
fromlist=0xe08c0) at Python/import.c:1602
#12 0x0006d024 in PyImport_ImportModuleEx (name=0x182eec "struct",
globals=0x111548, locals=0x111548, fromlist=0xe08c0) at Python/import.c:1643
#13 0x000bca6c in builtin___import__ (self=0x0, args=0x182eec)
at Python/bltinmodule.c:40
#14 0x000ba3a0 in PyCFunction_Call (func=0x101cb0, arg=0x10a440, kw=0x0)
at Objects/methodobject.c:69
#15 0x00095d08 in PyObject_Call (func=0x101cb0, arg=0x10a440, kw=0x0)
at Objects/abstract.c:1684
#16 0x00049c9c in PyEval_CallObjectWithKeywords (func=0x101cb0, arg=0x10a440,
kw=0x0) at Python/ceval.c:3049
#17 0x00047810 in eval_frame (f=0x186898) at Python/ceval.c:1839
#18 0x00048b38 in PyEval_EvalCodeEx (co=0x18d7b0, globals=0x186898, locals=0x0,
args=0x0, argcount=0, kws=0x0, kwcount=0, defs=0x0, defcount=0, closure=0x0)
at Python/ceval.c:2585
#19 0x0004b79c in PyEval_EvalCode (co=0x18d7b0, globals=0x111548, locals=0x0)
at Python/ceval.c:483
#20 0x00076fe8 in run_node (n=0xffd68, filename=0x111548 "", globals=0x111548,
locals=0x111548, flags=0x111548) at Python/pythonrun.c:1079
#21 0x00076450 in PyRun_InteractiveOneFlags (fp=0xffffffff,
filename=0xc0e70 "<stdin>", flags=0xffbefcf4) at Python/pythonrun.c:590
#22 0x000761f0 in PyRun_InteractiveLoopFlags (fp=0xfc1b0,
filename=0xc0e70 "<stdin>", flags=0xffbefcf4) at Python/pythonrun.c:526
#23 0x00077c78 in PyRun_AnyFileExFlags (fp=0xfc1b0, filename=0xc0e70 "<stdin>",
closeit=0, flags=0xffbefcf4) at Python/pythonrun.c:489
#24 0x0001c544 in Py_Main (argc=1, argv=0x1) at Modules/main.c:364