Differences between revisions 1 and 54 (spanning 53 versions)
Revision 1 as of 2007-11-28 11:31:24
Size: 1264
Comment: initial version
Revision 54 as of 2009-12-24 13:33:26
Size: 5446
Editor: DavidKirkby
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
== The Solaris Port of Sage == == Running Sage on Sun's Solaris operating system. ==
Line 3: Line 3:
This page tracks the Solaris port of Sage. This page, which is primarily maintained by David Kirkby, describes the current status of Sage on the various versions of Solaris and on various hardware (SPARC and x86).
Line 5: Line 5:
mabshoff is currently working on a 32 bit build on Solaris 9/Sparc. It should run on Solaris 10/Sparc. Although it is Christmas Eve as I write this, I suspect a Solaris server running Sage will be available before the end of 2009 at http://t2nb.math.washington.edu:8000/ That's a Sun T5240 kindly donated by Sun. But it is not installed just yet, but will be in the next few days.
Line 7: Line 7:
== History of efforts == === Solaris 10 on SPARC hardware. ===
Line 9: Line 9:
 * 2.8.14:
  * new bug in matrix code that provides a special class for multivariate polynomials as entries causes segfaults all over the map.
  * int_fast64_t needs to be 4 bytes large, otherwise Sage throws an exception at startup. This needs fixing and actually causes doctest failures with the modp code
  * libfplll miscompiles, fix clear, but needs to be merged upstream
  * FLINT miscompiles, fixed upstream
  * lcalc miscompiles, fixes need to be integrated
  * clisp compiles, but segfaults. Solution: use 2.39 binary until issue is solved
  * cvxopt doesn't work (complex.h missing)
  * 2-3 patches are needed to sage.spkg - easy fixes, need to be merged upstream
 * 2.8.3:
  * worked reasonably well after workarounds, about 10-12 doctest failures
  * work arounds needed: clisp, lcalc
  * missing/failed spkgs: cvxopt
 * pre 2.8:
  * various people (David Kirby) worked on this, but I am not sure if Sage ever passed 100% of doctests
That latest Sage release, 4.2.1, will build on Solaris as long as you do '''not''' have Sun Studio installed, though there are a couple of tricks you can use to get it to build if you do have Sun Studio installed.
Line 25: Line 11:
== ToDo == Sage 4.3 or later, which will be released in January 2010, should build and run on any SPARC hardware which runs Solaris 10. Sage has been built on several Solaris 10 SPARC systems, ranging from old machines to current models and from the first release of Solaris 10 (03/2005 edition) to the latest (05/2009 edition). So Sage should build on your Solaris 10 SPARC machine. Specific hardware/software combinations on which Sage has been built are
Line 27: Line 13:
 * make doctests pass 100%
 * open track tickets for all known issue
 * Sun T5240 !CoolThreads server with:
   * 2 x 1167 MHz T2+ Coolthreads processors
   * 16 cores
   * 128 threads
   * 32 GB RAM
   * Solaris 10 update 6 (05/2009 edition).
 * A Sun Blade 2000 workstation with:
   * 2 x 1200 MHz UltraSPARC III+ processors.
   * 8 GB RAM
   * Solaris 10 update 7 (05/2009 release) which at the time of writing (December 2009) is the latest release of Solaris 10.
 * Sun Netra T1 server with:
   * 1 x 500 MHz UltraSPARC-IIe processor
   * 1536 MB RAM
   * Solaris 10 03/2005 (the very first Solaris 10 release).

Sage will run in a Solaris zone, so if you want to make a public access server, with negligible security risks, then you can do so.

There are a few problems with the build on Solaris 10, all of which we hope to resolve.

 * Only GCC >= 4.0.1 can be used to build Sage. Supporting Sun Studio is an aim, but it's unlikely to happen soon.
 * As stated above, if Sun Studio is installed, Sage 4.2.1 will not build. This is easy to fix - more details below.
 * Sage currently only builds in 32-bit mode on Solaris 10.
 * Sage has a large test suite, which is run regularly by Sage developers. Not all the tests pass on Solaris 10. We are looking into reasons why this might be so.

=== Solaris 10 on x86 hardware. ===

This has not been tested, but would have a high probability of working. Let us know if you try it.

=== Open Solaris (also known as Solaris 11) on SPARC hardware ===
This has not been tested and will almost certainly not work.

We are afraid to say nobody currently developing Sage uses Open Solaris on SPARC hardware. Given the number of users of Open Solaris on SPARC hardware is so small, it is doubtful much effort will be put into a port. But if others wish to submit patches, they can do.

=== Open Solaris (also known as Solaris 11) on x86 hardware ===
Unfortunately, as of December 2009, the latest release of Sage will not build on Open Solaris. We are actively working on resolving this.

== How to build Sage on Solaris 10 with SPARC hardware ==

As stated above, this should work, but the process is not as simple as one might like it to be.

=== Stage `1 - make sure you have a suitable gcc, if not build one or download one ===

Sage has been built with gcc 4.4.1 and 4.4.2, but should work with any gcc >= 4.0.1 that

Solaris 10 only ships with an old version of gcc (3.4.3), which is not built with Fortran support. Sage needs a newer version of gcc than that, and it '''must''' be configured to support Fortran. (I believe the binary from Sunfreeware does not support Fortran). If you do not have gcc >= 4.0.1 with Fortran support, you will need to:

 * Download and install GMP from http://gmplib.org/ as this is a perquisite for building gcc.
 * Download and install MPFR from http://www.mpfr.org/ as this is a perquisite for building gcc.
 * Download and install gcc from http://gcc.gnu.org/

Older releases of Solaris 10 ship with a pretty broken gcc in /usr/sfw/bin. You might need to apply patch 123647 on old releases. Exactly how old, and what version of the patch is not know, but anything released in mid-2008 should be fine.

'''It is highly recommended that you configure gcc to use both the Sun linker and Sun assembler'''. A configuration which is known to work is:

{{{
drkirkby@kestrel:~$ gcc -v
Using built-in specs.
Target: sparc-sun-solaris2.10
Configured with: ../gcc-4.4.2/configure --prefix=/opt/kirkby/gcc-4.4.2/
--with-gmp=/usr/local/ --with-mpfr=/usr/local
--with-build-time-tools=/usr/ccs/bin --enable-languages=c,c++,fortran
Thread model: posix
gcc version 4.4.2 (GCC)
}}}


=== Stage 2 Set up a build environment. ===
Sage needs the GNU versions of ''make'' and ''tar'' to build. They must be called ''make'' and ''tar'' too, and not '''gmake'' or ''gtar''. You do not need particularly new versions of these tools, so those in /usr/sfw/bin will be fine. It is suggested you do this as follows

{{{
$ mkdir $HOME/bins-for-sage
$ cp /usr/sfw/bin/gmake $HOME/bins-for-sage/make
$ cp /usr/sfw/bin/gtar $HOME/bins-for-sage/tar
}}}

=== Stage 3 Type 'make' and wait for Sage to build ===

=== Stage 4. Start using Sage! ===

Running Sage on Sun's Solaris operating system.

This page, which is primarily maintained by David Kirkby, describes the current status of Sage on the various versions of Solaris and on various hardware (SPARC and x86).

Although it is Christmas Eve as I write this, I suspect a Solaris server running Sage will be available before the end of 2009 at http://t2nb.math.washington.edu:8000/ That's a Sun T5240 kindly donated by Sun. But it is not installed just yet, but will be in the next few days.

Solaris 10 on SPARC hardware.

That latest Sage release, 4.2.1, will build on Solaris as long as you do not have Sun Studio installed, though there are a couple of tricks you can use to get it to build if you do have Sun Studio installed.

Sage 4.3 or later, which will be released in January 2010, should build and run on any SPARC hardware which runs Solaris 10. Sage has been built on several Solaris 10 SPARC systems, ranging from old machines to current models and from the first release of Solaris 10 (03/2005 edition) to the latest (05/2009 edition). So Sage should build on your Solaris 10 SPARC machine. Specific hardware/software combinations on which Sage has been built are

  • Sun T5240 CoolThreads server with:

    • 2 x 1167 MHz T2+ Coolthreads processors
    • 16 cores
    • 128 threads
    • 32 GB RAM
    • Solaris 10 update 6 (05/2009 edition).
  • A Sun Blade 2000 workstation with:
    • 2 x 1200 MHz UltraSPARC III+ processors.
    • 8 GB RAM
    • Solaris 10 update 7 (05/2009 release) which at the time of writing (December 2009) is the latest release of Solaris 10.
  • Sun Netra T1 server with:
    • 1 x 500 MHz UltraSPARC-IIe processor
    • 1536 MB RAM
    • Solaris 10 03/2005 (the very first Solaris 10 release).

Sage will run in a Solaris zone, so if you want to make a public access server, with negligible security risks, then you can do so.

There are a few problems with the build on Solaris 10, all of which we hope to resolve.

  • Only GCC >= 4.0.1 can be used to build Sage. Supporting Sun Studio is an aim, but it's unlikely to happen soon.

  • As stated above, if Sun Studio is installed, Sage 4.2.1 will not build. This is easy to fix - more details below.
  • Sage currently only builds in 32-bit mode on Solaris 10.
  • Sage has a large test suite, which is run regularly by Sage developers. Not all the tests pass on Solaris 10. We are looking into reasons why this might be so.

Solaris 10 on x86 hardware.

This has not been tested, but would have a high probability of working. Let us know if you try it.

Open Solaris (also known as Solaris 11) on SPARC hardware

This has not been tested and will almost certainly not work.

We are afraid to say nobody currently developing Sage uses Open Solaris on SPARC hardware. Given the number of users of Open Solaris on SPARC hardware is so small, it is doubtful much effort will be put into a port. But if others wish to submit patches, they can do.

Open Solaris (also known as Solaris 11) on x86 hardware

Unfortunately, as of December 2009, the latest release of Sage will not build on Open Solaris. We are actively working on resolving this.

How to build Sage on Solaris 10 with SPARC hardware

As stated above, this should work, but the process is not as simple as one might like it to be.

Stage `1 - make sure you have a suitable gcc, if not build one or download one

Sage has been built with gcc 4.4.1 and 4.4.2, but should work with any gcc >= 4.0.1 that

Solaris 10 only ships with an old version of gcc (3.4.3), which is not built with Fortran support. Sage needs a newer version of gcc than that, and it must be configured to support Fortran. (I believe the binary from Sunfreeware does not support Fortran). If you do not have gcc >= 4.0.1 with Fortran support, you will need to:

Older releases of Solaris 10 ship with a pretty broken gcc in /usr/sfw/bin. You might need to apply patch 123647 on old releases. Exactly how old, and what version of the patch is not know, but anything released in mid-2008 should be fine.

It is highly recommended that you configure gcc to use both the Sun linker and Sun assembler. A configuration which is known to work is:

drkirkby@kestrel:~$ gcc -v
Using built-in specs.
Target: sparc-sun-solaris2.10
Configured with: ../gcc-4.4.2/configure --prefix=/opt/kirkby/gcc-4.4.2/ 
--with-gmp=/usr/local/ --with-mpfr=/usr/local 
--with-build-time-tools=/usr/ccs/bin --enable-languages=c,c++,fortran
Thread model: posix
gcc version 4.4.2 (GCC) 

Stage 2 Set up a build environment.

Sage needs the GNU versions of make and tar to build. They must be called make and tar too, and not gmake or gtar. You do not need particularly new versions of these tools, so those in /usr/sfw/bin will be fine. It is suggested you do this as follows

$ mkdir $HOME/bins-for-sage
$ cp /usr/sfw/bin/gmake $HOME/bins-for-sage/make
$ cp /usr/sfw/bin/gtar $HOME/bins-for-sage/tar

Stage 3 Type 'make' and wait for Sage to build

Stage 4. Start using Sage!