#11967: os x 10.7 Lion -- Sage segfaults on startup when initializing GiNaC
-----------------------+----------------------------------------------------
Reporter: was | Owner: drkirkby
Type: defect | Status: new
Priority: major | Milestone: sage-4.8
Component: porting | Keywords:
Work_issues: | Upstream: N/A
Reviewer: | Author:
Merged: | Dependencies:
-----------------------+----------------------------------------------------
Changes (by was):
* milestone: => sage-4.8
Comment:
I've put sage-4.7.3.alpha1, built from source on a 10.6 computer
(bsd.math) and on a 10.7 computer (my laptop), then moved the 10.6 built
one to the 10.7 computer. The version built on 10.6 starts up on 10.7
just fine, but of course the version built on 10.7 crashes as explained
above. I looked at the file local/lib/libpynac-0.2.3.dylib in each
install, and they are different:
{{{
10.6$ ls -l local/lib/libpynac-0.2.3.dylib
-rwxr-xr-x 1 wstein staff 3176552 Nov 2 18:15
local/lib/libpynac-0.2.3.dylib
10.7$ ls -l local/lib/libpynac-0.2.3.dylib
-rwxr-xr-x 1 wstein staff 5144444 Nov 2 18:27
local/lib/libpynac-0.2.3.dylib
}}}
Notice that the version that works is much smaller. The bad one (on 10.7)
has twice as many symbols:
{{{
10.6$ nm -o local/lib/libpynac-0.2.3.dylib|wc -l
4665
10.7$ nm -o local/lib/libpynac-0.2.3.dylib|wc -l
9526
}}}
Check out this:
{{{
10.6$nm -o local/lib/libpynac-0.2.3.dylib|grep -i Py_INCREF
but
10.7$ nm -o local/lib/libpynac-0.2.3.dylib|grep -i Py_INCREF
local/lib/libpynac-0.2.3.dylib: 00000000001a9750 T _Py_IncRef
}}}
This suggests again that the build of Pynac on OS X 10.7 is now broken and
somehow accidentally links in another copy of Python.
Looking at the build log, we find this during the pynac build (on 10.7):
{{{
-L/Users/wstein/sage/install/sage-4.7.3.alpha1/local/lib/python2.6/config
-lpython2.6
}}}
and in that -L'd directory we find only an "evil" static libpython2.6.a:
{{{
$ ls local/lib/python2.6/config
Makefile Setup.config config.c install-sh makesetup
Setup Setup.local config.c.in libpython2.6.a python.o
}}}
The same libpython2.6.a is in that directory in the 10.6 version. The
same build line appears there to. So... I'm guessing that one of the
changes in XCode 4.x is to make it so that -L works differently. In fact,
what now happens (that causes this problem) does seem pretty reasonable to
me.
My first attempt to fix this is to rebuild the pynac spkg, but with
libpython2.6.dylib simply copied into the local/lib/python2.6/config
directory. That one change was *not* sufficient to fix the problem, but
I bet something related will work...
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11967#comment:4>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.