Error building 2.9 on OSX 10.4 (LAPACK)

26 views
Skip to first unread message

Stephen Forrest

unread,
Dec 16, 2007, 12:17:39 PM12/16/07
to Sage Development
I just downloaded the 2.9 source tarball and attempted a build.  It died on building lapack.  It looks like the test* files in spkg/build/lapack-20071123/src/INSTALL are for a different architecture.

I'm running OSX 10.4 Intel; 2 GHz Intel Core Duo and 1 GB of RAM.

Steve 

****************************************************
GCC Version
gcc -v
Using built-in specs.
Target: i686-apple-darwin8
Configured with: /private/var/tmp/gcc/gcc- 5250.obj~20/src/configure --disable-checking -enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/ --with-gxx-include-dir=/include/c++/4.0.0 --build=powerpc-apple-darwin8 --with-arch=pentium-m --with-tune=prescott --program-prefix= --host=i686-apple-darwin8 --target=i686-apple-darwin8
Thread model: posix
gcc version 4.0.1 (Apple Computer, Inc. build 5250)
****************************************************
( cd INSTALL; make; ./testlsame; ./testslamch; \
  ./testdlamch; ./testsecond; ./testdsecnd; ./testversion )
sage_fortran -fPIC  -c lsame.f -o lsame.o
sage_fortran -fPIC  -c lsametst.f -o lsametst.o
sage_fortran  -o testlsame lsame.o lsametst.o
ld: table of contents for archive: /opt/sage-2.9/local/bin/../lib/gcc-lib/i386- apple-darwin8.10.3/4.0.3//libf95.a is out of date; rerun ranlib(1) (can't load from it)
ld: table of contents for archive: /opt/sage-2.9/local/bin/../lib/gcc-lib/i386-apple-darwin8.10.3/4.0.3//libgcc.a is out of date; rerun ranlib(1) (can't load from it)
ld: table of contents for archive: /opt/sage-2.9/local/bin/../lib/gcc-lib/i386-apple-darwin8.10.3/4.0.3//libgcc_eh.a is out of date; rerun ranlib(1) (can't load from it)
make[3]: *** [testlsame] Error 1
/bin/sh: line 1: ./testlsame: cannot execute binary file
/bin/sh: line 1: ./testslamch: cannot execute binary file
/bin/sh: line 1: ./testdlamch: cannot execute binary file
/bin/sh: line 1: ./testsecond: No such file or directory
/bin/sh: line 1: ./testdsecnd: cannot execute binary file
/bin/sh: line 1: ./testversion: cannot execute binary file
make[2]: *** [lapack_install] Error 126
Error compiling lapack

William Stein

unread,
Dec 16, 2007, 12:21:02 PM12/16/07
to sage-...@googlegroups.com
On Dec 16, 2007 9:17 AM, Stephen Forrest <stephen...@gmail.com> wrote:
> I just downloaded the 2.9 source tarball and attempted a build. It died on
> building lapack. It looks like the test* files in
> spkg/build/lapack-20071123/src/INSTALL are for a different architecture.
>
> I'm running OSX 10.4 Intel; 2 GHz Intel Core Duo and 1 GB of RAM.
>
> Steve
>
> ****************************************************
> GCC Version
> gcc -v
> Using built-in specs.
> Target: i686-apple-darwin8
> Configured with: /private/var/tmp/gcc/gcc- 5250.obj~20/src/configure
> --disable-checking -enable-werror --prefix=/usr --mandir=/share/man
> --enable-languages=c,objc,c++,obj-c++
> --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/
> --with-gxx-include-dir=/include/c++/4.0.0 --build=powerpc-apple-darwin8
> --with-arch=pentium-m --with-tune=prescott --program-prefix=
> --host=i686-apple-darwin8 --target=i686-apple-darwin8
> Thread model: posix
> gcc version 4.0.1 (Apple Computer, Inc. build 5250)

I'm not sure if this is related to the problem you just reported,
but you should upgrade to a newer version of XCode.
E.g., on my intel osx10 10.4 test machine I have build 5367:

$ gcc -v
gcc version 4.0.1 (Apple Computer, Inc. build 5367)

William

mabshoff

unread,
Dec 16, 2007, 2:37:06 PM12/16/07
to sage-devel


On Dec 16, 6:21 pm, "William Stein" <wst...@gmail.com> wrote:
> On Dec 16, 2007 9:17 AM, Stephen Forrest <stephen.forr...@gmail.com> wrote:
>
>
>
> > I just downloaded the 2.9 source tarball and attempted a build. It died on
> > building lapack. It looks like the test* files in
> > spkg/build/lapack-20071123/src/INSTALL are for a different architecture.
>
> > I'm running OSX 10.4 Intel; 2 GHz Intel Core Duo and 1 GB of RAM.
>
> > Steve
>
> > ****************************************************
> > GCC Version
> > gcc -v
> > Using built-in specs.
> > Target: i686-apple-darwin8
> > Configured with: /private/var/tmp/gcc/gcc- 5250.obj~20/src/configure
> > --disable-checking -enable-werror --prefix=/usr --mandir=/share/man
> > --enable-languages=c,objc,c++,obj-c++
> > --program-transform-name=/^[cg][^.-]*$/s/$/-4.0/
> > --with-gxx-include-dir=/include/c++/4.0.0 --build=powerpc-apple-darwin8
> > --with-arch=pentium-m --with-tune=prescott --program-prefix=
> > --host=i686-apple-darwin8 --target=i686-apple-darwin8
> > Thread model: posix
> > gcc version 4.0.1 (Apple Computer, Inc. build 5250)
>

Hi Steve,

> I'm not sure if this is related to the problem you just reported,
> but you should upgrade to a newer version of XCode.
> E.g., on my intel osx10 10.4 test machine I have build 5367:
>

I suspect the same issue, since we recently updated the binary g95 for
OSX 10.5.

Slightly surreal, but the first hit on Google for "libf95.a is out of
date" is:

http://www.mail-archive.com/sage-...@googlegroups.com/msg04632.html

Analog to the above mail do a

touch spkg/installed/lapack-20071123.spkg

since we don't really need Lapack on OSX. We started building it also
on OSX in anticipation of building ATLAS there, too. I suspect that
you will run into trouble "down the road" with numpy, scipy and cvxopt
if you don't fix the problem via William's suggested fix.

A last resort is to install gfortran and do SAGE_FORTRAN=`which
gfortran` before forcing a rebuild of the sage fortran.spkg via

./sage -f spkg/standard/fortran-20071120.p1.spkg

Let us know if you run into any more trouble. If the above solves your
problem we should update the readme to reflect the requirement for a
specific XCode release.

> $ gcc -v
> gcc version 4.0.1 (Apple Computer, Inc. build 5367)
>
> William

Cheers,

Michael

Justin C. Walker

unread,
Dec 16, 2007, 2:47:28 PM12/16/07
to sage-...@googlegroups.com

On Dec 16, 2007, at 09:17 , Stephen Forrest wrote:

> I just downloaded the 2.9 source tarball and attempted a build. It
> died on
> building lapack. It looks like the test* files in
> spkg/build/lapack-20071123/src/INSTALL are for a different
> architecture.

The files src/INSTALL/test* are all ELF files for a Linux box. I
don't know that this is a problem, or just a packaging issue.

I may be off in the weeds, but this looks like a "simple" problem to
fix. Either when the tarball is built, or when the spkg is built,
would a 'ranlib' fix this? Typically, when a (.a) library is copied
(rather than moved), its creation/mod date changes, and shows as
later than some internal bit of housekeeping info. 'ranlib' will fix
that.

Justin

--
Justin C. Walker, Curmudgeon-At-Large
Institute for the Enhancement of the Director's Income
--------
Experience is what you get
when you don't get what you want.
--------

William Stein

unread,
Dec 16, 2007, 2:46:34 PM12/16/07
to sage-...@googlegroups.com

- William

(Sent from my iPhone.)

On Dec 16, 2007, at 11:37 AM, mabshoff <Michael...@fsmath.mathematik.uni-dortmund.de
> wrote:


do not put .spkg in the above line

mabshoff

unread,
Dec 16, 2007, 3:26:55 PM12/16/07
to sage-devel


On Dec 16, 8:46 pm, William Stein <wst...@gmail.com> wrote:
> - William
>
> (Sent from my iPhone.)
>
> On Dec 16, 2007, at 11:37 AM, mabshoff <Michael.Absh...@fsmath.mathematik.uni-dortmund.de
Ooops, I do that *every* time. Anyway, I made this ticket #1540 and
posted an updated lapack.spkg that removes those files at

http://sage.math.washington.edu/home/mabshoff/lapack-20071123.p0.spkg

Let me know if that fixes it.

Cheers,

Michael

Stephen Forrest

unread,
Dec 16, 2007, 5:27:21 PM12/16/07
to sage-...@googlegroups.com
Upgrading XCode to version 2.5 (gcc build 5370, slightly newer than
William's) solved the problem; nothing more was necessary.

Thanks very much to everyone who responded!

Steve

On Dec 16, 2007 2:37 PM, mabshoff

Reply all
Reply to author
Forward
0 new messages