Mac Yosemite build error conway_polynomials-0.4.p0

129 views
Skip to first unread message

Andrew Bernard

unread,
Mar 2, 2015, 7:41:17 AM3/2/15
to sage-...@googlegroups.com
Greetings all,

New to this group.

Build error with source download for Mac on OS X 10.10.2 in package conway_polynomials-0.4.p0.

 File "sage/matrix/matrix_mod2_dense.pxd", line 7, in init sage.matrix.matrix_integer_dense (build/cythonized/sage/matrix/matrix_integer_dense.c:47607)

ImportError: dlopen(/Users/andro/src/sage-6.5/local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so, 2): Symbol not found: _gdImageCreateFromPng

  Referenced from: /Users/andro/src/sage-6.5/local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so

  Expected in: flat namespace

 in /Users/andro/src/sage-6.5/local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so

How does one go about addressing such?

What is the status of sage on Yosemite in general? Is it just too early to be doing this?

Thanks.

Andrew


Volker Braun

unread,
Mar 2, 2015, 8:54:13 AM3/2/15
to sage-...@googlegroups.com
Looks like a missing dependency. Can you open a ticket?

Workaround:

sage -f libgd
make    # continue building

kcrisman

unread,
Mar 2, 2015, 11:09:50 AM3/2/15
to sage-...@googlegroups.com
Since the OP is new to the group, probably doesn't have a Trac account (yet), so I've opened http://trac.sagemath.org/ticket/17884

Volker Braun

unread,
Mar 2, 2015, 3:10:22 PM3/2/15
to sage-...@googlegroups.com
Sage 6.5 supports Yosemite.

Can you post logs/pkgs/libgd-2.1.0.p0.log



On Monday, March 2, 2015 at 1:41:17 PM UTC+1, Andrew Bernard wrote:

Andrew Bernard

unread,
Mar 16, 2015, 10:52:49 AM3/16/15
to sage-...@googlegroups.com
Here is the error:

Volker Braun

unread,
Mar 16, 2015, 12:27:57 PM3/16/15
to sage-...@googlegroups.com
Need the build log.

Ben Salisbury

unread,
Mar 17, 2015, 7:43:01 PM3/17/15
to sage-...@googlegroups.com
Hi.  I am also having the same problem.  I've attached the requested log file.  Please help!
libgd-2.1.0.p0.log

François Bissey

unread,
Mar 17, 2015, 7:51:27 PM3/17/15
to sage-...@googlegroups.com
We would also need the sage build log. Also I would want the output of
otool -L local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so

and
nm local/lib/libgd.dylib | grep gdImageCreateFromPng

Francois
> --
> You received this message because you are subscribed to the Google
> Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to sage-devel+...@googlegroups.com
> <mailto:sage-devel+...@googlegroups.com>.
> To post to this group, send email to sage-...@googlegroups.com
> <mailto:sage-...@googlegroups.com>.
> Visit this group at http://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.

Ben Salisbury

unread,
Mar 17, 2015, 9:10:56 PM3/17/15
to sage-...@googlegroups.com
Sorry for the delay; I had retried the install again... with no luck.

The install log file was too large to attach.  Here is a link:  https://drive.google.com/file/d/0B0GKOwXupX1ub3NoMkxPRy1zcDQ/view?usp=sharing

The output from the requested commands are

$ otool -L local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so
local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so:
 libcsage
.dylib (compatibility version 0.0.0, current version 0.0.0)
 
/Users/Ben/sage-git/local/lib/libgmp.16.dylib (compatibility version 17.0.0, current version 17.0.0)
 
/Users/Ben/sage-git/local/lib/libm4ri-0.0.20140914.dylib (compatibility version 0.0.0, current version 0.0.0)
 
/Users/Ben/sage-git/local/lib/libgd.3.dylib (compatibility version 4.0.0, current version 4.0.0)
 
/Users/Ben/sage-git/local/lib/libpng12.0.dylib (compatibility version 52.0.0, current version 52.0.0)
 
/Users/Ben/sage-git/local/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.8)
 
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1213.0.0)
 
/Users/Ben/sage-git/local/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)

and

$ nm local/lib/libgd.dylib | grep gdImageCreateFromPng
000000000001329c T _gdImageCreateFromPng
000000000001334b T _gdImageCreateFromPngCtx
00000000000132ed T _gdImageCreateFromPngPtr
0000000000015402 T _gdImageCreateFromPngSource

Thanks for the help!

~Ben
libgd-2.1.0.p0.log

François Bissey

unread,
Mar 17, 2015, 9:17:04 PM3/17/15
to sage-...@googlegroups.com
I would rather have logs/pkgs/sage-6.5.log than the full install log.

Francois

On 03/18/15 14:10, Ben Salisbury wrote:
> Sorry for the delay; I had retried the install again... with no luck.
>
> The install log file was too large to attach. Here is a link:
> https://drive.google.com/file/d/0B0GKOwXupX1ub3NoMkxPRy1zcDQ/view?usp=sharing
>
> The output from the requested commands are
>
> |
> $ otool -L
> local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so
> local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so:
> libcsage.dylib (compatibility version 0.0.0,current version 0.0.0)
> /Users/Ben/sage-git/local/lib/libgmp.16.dylib(compatibility version
> 17.0.0,current version 17.0.0)
> /Users/Ben/sage-git/local/lib/libm4ri-0.0.20140914.dylib(compatibility
> version 0.0.0,current version 0.0.0)
> /Users/Ben/sage-git/local/lib/libgd.3.dylib(compatibility version
> 4.0.0,current version 4.0.0)
> /Users/Ben/sage-git/local/lib/libpng12.0.dylib(compatibility version
> 52.0.0,current version 52.0.0)
> /Users/Ben/sage-git/local/lib/libz.1.dylib(compatibility version
> 1.0.0,current version 1.2.8)
> /usr/lib/libSystem.B.dylib (compatibility version 1.0.0,current version
> 1213.0.0)
> /Users/Ben/sage-git/local/lib/libgcc_s.1.dylib(compatibility version
> 1.0.0,current version 1.0.0)
> |
>
> and
>
> |
> $ nm local/lib/libgd.dylib |grep gdImageCreateFromPng
> 000000000001329cT _gdImageCreateFromPng
> 000000000001334bT _gdImageCreateFromPngCtx
> 00000000000132edT _gdImageCreateFromPngPtr
> 0000000000015402T _gdImageCreateFromPngSource
> |
>
> Thanks for the help!
>
> ~Ben
>

Ben Salisbury

unread,
Mar 17, 2015, 9:24:24 PM3/17/15
to sage-...@googlegroups.com
Sorry about that.  Here it is!

~Ben
sage-6.6.beta5.log

François Bissey

unread,
Mar 17, 2015, 9:38:52 PM3/17/15
to sage-...@googlegroups.com
Which ticket were you working on? You seem to have run "./sage -b" and
it rebuilt sage.matrix.matrix_mod2_dense and sage.rings.polynomial.pbori.

Francois

On 03/18/15 14:24, Ben Salisbury wrote:
> Sorry about that. Here it is!
>
> ~Ben
>

Ben Salisbury

unread,
Mar 17, 2015, 9:43:07 PM3/17/15
to sage-...@googlegroups.com
I was just trying to build in the develop branch. I wasn't currently working on any particular patch.

Andrew Bernard

unread,
Mar 18, 2015, 12:43:44 AM3/18/15
to sage-...@googlegroups.com

$ otool -L local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so

local/lib/python2.7/site-packages/sage/matrix/matrix_mod2_dense.so:

libcsage.dylib (compatibility version 0.0.0, current version 0.0.0)

/Users/andro/src/sage-6.5/local/lib/libgmp.16.dylib (compatibility version 17.0.0, current version 17.0.0)

/Users/andro/src/sage-6.5/local/lib/libm4ri-0.0.20140914.dylib (compatibility version 0.0.0, current version 0.0.0)

/Users/andro/src/sage-6.5/local/lib/libgd.3.dylib (compatibility version 4.0.0, current version 4.0.0)

/Users/andro/src/sage-6.5/local/lib/libpng12.0.dylib (compatibility version 52.0.0, current version 52.0.0)

/Users/andro/src/sage-6.5/local/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.8)

/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1213.0.0)


$ nm local/lib/libgd.dylib | grep gdImageCreateFromPng 

0000000000012bfd T _gdImageCreateFromPngSource

Volker Braun

unread,
Mar 18, 2015, 2:39:48 PM3/18/15
to sage-...@googlegroups.com
This looks like it ought to work. The thing I can think of is that we install both a static and shared libgd, and if the linker ever used the static version to resolve (part) of the dependencies then its going to be tough to figure out anything.

Does "make distclean && make" change anything (will take some time to compile).

Ben Salisbury

unread,
Mar 18, 2015, 2:44:10 PM3/18/15
to sage-...@googlegroups.com
Hi,

I did run "make distclean && make" during both failed builds.

Best,
Ben

Volker Braun

unread,
Mar 18, 2015, 2:52:20 PM3/18/15
to sage-...@googlegroups.com
Do you have Homebrew installed (stuff in /usr/local ?)

Ben Salisbury

unread,
Mar 18, 2015, 3:03:42 PM3/18/15
to sage-...@googlegroups.com
I do not have homebrew installed.

$ brew help
-bash: brew: command not found

Best,
Ben

Volker Braun

unread,
Mar 18, 2015, 7:17:31 PM3/18/15
to sage-...@googlegroups.com
Do you perhaps have an older version of the command line tools installed? It definitely works on my OSX Yosemite machine so it must be either some conflict with a system-wide install or a different toolchain version.

Ben Salisbury

unread,
Mar 18, 2015, 7:22:16 PM3/18/15
to sage-...@googlegroups.com
It's possible... though I had just recompiled Sage 6.6beta4 last Thursday without any issues. Here is my current output:

$ xcode-select --version
xcode
-select version 2339.

In the meantime, I will try to reinstall command line tools and recompile.  My guess is that the problem has to do with the recent update to OS X 10.10.2.  I did the update at the end of last week without considering the ramifications...

Best,
Ben

Andrew Bernard

unread,
Mar 18, 2015, 7:26:01 PM3/18/15
to sage-...@googlegroups.com
I have:

$ xcode-select --version
xcode-select version 2339.

I am at Mac OS 10.10.2. Perhaps this is the issue?

Andrew

Ben Salisbury

unread,
Mar 18, 2015, 7:26:20 PM3/18/15
to sage-...@googlegroups.com
Okay, so it seems I cannot just run xcode-select --install to override the current version.

$ xcode-select --install
xcode
-select: error: command line tools are already installed, use "Software Update" to install updates

I looked at my Software Updates, and it seems that part of the update last week was an update to Command Line Tools.

Though I know I had installed beta4 on 3-12, so I'm not sure why I'm getting this new error now.

Volker Braun

unread,
Mar 18, 2015, 7:30:47 PM3/18/15
to sage-...@googlegroups.com
Same here. Also on 10.10.2

OSX osx 00:30:09 ~
$ xcode-select --version
xcode-select version 2339.


Ben Salisbury

unread,
Mar 18, 2015, 7:33:49 PM3/18/15
to sage-...@googlegroups.com
Hmmm.... that's both encouraging and discouraging.  I've already tried 'make distclean' to start fresh.  Is there another way?

Volker Braun

unread,
Mar 18, 2015, 7:35:07 PM3/18/15
to sage-...@googlegroups.com
No, "make distclean" is the official way to start from scratch (and a known starting point, namely just the source)...

Francois Bissey

unread,
Mar 18, 2015, 7:35:29 PM3/18/15
to sage-...@googlegroups.com
Ditto here. I built 6.6.beta5 last evening just to see if I was hitting it myself.
The error message about flat namespace is suggestive of an alternative toolchain
interfering.

Francois
> --
> You received this message because you are subscribed to the Google Groups "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
> To post to this group, send email to sage-...@googlegroups.com.
> Visit this group at http://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.


This email may be confidential and subject to legal privilege, it may
not reflect the views of the University of Canterbury, and it is not
guaranteed to be virus free. If you are not an intended recipient,
please notify the sender immediately and erase all copies of the message
and any attachments.

Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more
information.

Andrew Bernard

unread,
Mar 19, 2015, 1:29:54 AM3/19/15
to sage-...@googlegroups.com
Problem solved. On Yosemite 10.10.2, I have mac ports installed. The suggestions about alternative toolchains proved correct.

Here's what I did:
  • Renamed my /opt to /_opt to remove it from any possible path, so that locally installed toolchain components cannot be used.
  • set PATH to PATH=/bin:/usr/bin
  • checked xcode command line tools at latest version

Sage 6.5 compiles and runs with no major issues.

Thanks to all the people on this list!

Andrew



kcrisman

unread,
Mar 19, 2015, 11:03:05 AM3/19/15
to sage-...@googlegroups.com

Problem solved. On Yosemite 10.10.2, I have mac ports installed. The suggestions about alternative toolchains proved correct.


I thought our script explicitly disallows macports and fink?  (In particular, I just had a student compile Sage and he needed to move those directories "as usual".)  Maybe it is no longer catching this?

Ben Salisbury

unread,
Mar 19, 2015, 6:31:39 PM3/19/15
to sage-...@googlegroups.com
It was suggested to me to try 

export SAGE_PORT=yes

and this actually did the trick!  
Reply all
Reply to author
Forward
0 new messages