Problem building Sage after upgrading OS X 10.6.8 -> 10.9.1

109 views
Skip to first unread message

David Roe

unread,
Feb 5, 2014, 7:33:58 PM2/5/14
to sage-devel
I recently upgraded OS X and now run into trouble building Sage.  XCode displays the version number as Version 5.0.2 (5A3005).

When I try "make build" in my existing Sage (built before the upgrade), I get the following error:

checking for C compiler default output file name...
configure: error: C compiler cannot create executables

(log available at http://pastebin.com/WQ5ssXVi)
I checked my C compiler: gcc -v returns

Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/c++/4.2.1
Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin13.0.0
Thread model: posix

and it successfully builds a hello_world.c.  So I decided to try building from scratch, using a fresh sage-6.1 tarball.  It errored with

sed: /usr/include/sys/cdefs.h: No such file or directory

(log available at http://pastebin.com/G9Ajqs4n)
After running "sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include/" the build proceeded, with lots of warnings of the form

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/5.0/include/stddef.h:84:24: note: expanded from macro 'offsetof'
#define offsetof(t, d) __builtin_offsetof(t, d)
                       ^
In file included from ../../src/gcc/graphite-scop-detection.c:25:
In file included from ../../src/gcc/tree-flow.h:27:
In file included from ../../src/gcc/basic-block.h:26:
In file included from ../../src/gcc/function.h:27:
../../src/gcc/vecprim.h:29:1: warning: using extended field designator is an extension [-Wextended-offsetof]
DEF_VEC_ALLOC_I(uchar,gc);
^~~~~~~~~~~~~~~~~~~~~~~~~
../../src/gcc/vec.h:572:34: note: expanded from macro 'DEF_VEC_ALLOC_I'
DEF_VEC_ALLOC_FUNC_I(T,A)                                                 \
                                                                          ^
../../src/gcc/vec.h:1274:21: note: expanded from macro '\
DEF_VEC_NONALLOC_FUNCS_I'
                         (*vec_, alloc_, offsetof (VEC(T,A),base.vec),    \
                                         ^                      ~~~~

and some suspicious lines that looked like

/usr/bin/ranlib: file: libgcc_eh.a(unwind-sjlj.o) has no symbols
/usr/bin/ranlib: file: ../.././gcc/libgcc.a(_trampoline.o) has no symbols

Eventually it failed as before, with

checking for C compiler default output file name...
configure: error: in `/Users/roed/sage/sage6/local/var/tmp/sage/build/gcc-4.7.3.p1/gcc-build/x86_64-apple-darwin13.0.0/libgomp':
configure: error: C compiler cannot create executables
See `config.log' for more details.
make[5]: *** [configure-stage1-target-libgomp] Error 77
make[4]: *** [stage1-bubble] Error 2
make[3]: *** [all] Error 2

(log available at http://people.ucalgary.ca/~roed/gcc-4.7.3.p1.log, since it's too big for pastebin)

Something appears to be screwed up with my development environment, but I'm not sure what.  Any ideas?
David

John H Palmieri

unread,
Feb 5, 2014, 9:32:23 PM2/5/14
to sage-...@googlegroups.com


On Wednesday, February 5, 2014 4:33:58 PM UTC-8, David Roe wrote:
I recently upgraded OS X and now run into trouble building Sage.  XCode displays the version number as Version 5.0.2 (5A3005).

Maybe see http://trac.sagemath.org/ticket/15783? That is, after upgrading Xcode, you need to type

   xcode-select --install

from a Terminal. Or have you done that already?

  John

 

David Roe

unread,
Feb 6, 2014, 1:33:24 AM2/6/14
to sage-devel
On Wed, Feb 5, 2014 at 7:32 PM, John H Palmieri <jhpalm...@gmail.com> wrote:


On Wednesday, February 5, 2014 4:33:58 PM UTC-8, David Roe wrote:
I recently upgraded OS X and now run into trouble building Sage.  XCode displays the version number as Version 5.0.2 (5A3005).

Maybe see http://trac.sagemath.org/ticket/15783? That is, after upgrading Xcode, you need to type

   xcode-select --install

from a Terminal. Or have you done that already?

That seems to have fixed the problem, or at least allowed me to get through building gcc.  Thanks!
David

Bill Janssen

unread,
Sep 15, 2015, 7:50:47 PM9/15/15
to sage-devel
I've got this problem right now, with Sage 6.8, on 10.9.  And I've run xcode-select --install from a terminal; it just outputs the line "xcode-select: note: install requested for command line developer tools" (which are already installed).

Help!

Bill

Bill Janssen

unread,
Sep 15, 2015, 7:55:12 PM9/15/15
to sage-devel
I take it back.  Apparently installing them from the Xcode app gives you the compilers, etc, but not the header files.  Using xcode-select --install seems to yield both.

Bill
Reply all
Reply to author
Forward
0 new messages