#7056: Fix build issues so Sage builds with the Sun Studio Compiler suite.
------------------------+---------------------------------------------------
   Reporter:  drkirkby  |       Owner:  tbd     
       Type:  defect    |      Status:  new     
   Priority:  major     |   Milestone:  sage-4.3
  Component:  solaris   |    Keywords:          
Work_issues:            |      Author:          
   Reviewer:            |      Merged:          
------------------------+---------------------------------------------------
Description changed by drkirkby:

Old description:

> '''Introduction'''
>
> Sun's compiler on Solaris produces faster code than gcc, and is more
> reliable with 64-bit code than gcc. This ticket outlines the issues that
> need to be resolved to get Sage to build on Sun Studio, and are specific
> to Sun Studio. As more are discovered, I'll add them to the description,
> so it's easy to them all, rather than find them buried well down the
> page.
>
> In many cases, the bugs can potentially affect all compilers, but are
> only observed on Sun Studio.
>
> '''Hardware used for testing'''
>
> Attempts were made to build Sage on the following two Solaris machines.
> Where a problem is detected on only one, or is suspect it might occur on
> only one machine, then the hostname is stated.
>
> ||'''Hostname'''||'''Hardware'''||'''Processor'''||'''CPUs'''||'''Cores'''||'''Speed'''||'''Architecture'''||'''OS
> version'''||Compiler||
> ||swan||Sun Blade 2000||UltraSPARC-III+||2||2||1200 MHz||sun4u||Solaris
> 10 update 7||Sun Studio 12.1||
> ||t2||Sun T5240||SPARC T2+||2||16||1167 MHz||sun4v||Solaris 10 update
> 7||Sun Studio 12||
>

> '''Bugs'''
>
> The actual bugs found, along with the trac number are listed below. The
> hostname is stated it if might be relevant.
>
> If the description is in italics, and marked with note number 11, then
> the problem in itself would not prevent Sage being built with Sun Studio,
> but would impact performance adversely.
>
> ||'''Description'''||'''hostname'''||'''Trac #'''||'''Note(s)'''||
>
> ||Update prereq from 0.3 to 0.4||||#7021||1,7||
> ||zn_poly-0.9 uses gcc, irrespective of setting of CC||||#7039||2||
> ||symmetrica ignores CC||||#7032||2||
> ||ATLAS ignores CC variable, then dumps core when trying to build with
> Sun Studio on Solaris||swan||#7048||2,3||
> ||Flint ignores CC and CXX||||#7024||2||
> ||lapack sends GNU option -fPIC to Sun fortran compiler||||#7047||||
> ||eclib 20080310.p7 has code Sun's C++ compiler does not
> understand||||#7044||||
> ||Code actually in Sage (not other project) ignores CC and uses
> gcc||||#7040||2||
> ||ntl 5.4.2.p9 passes -fPIC to Sun linker with Sun Studio||||#7043||||
> ||givaro 3.2.13rc2 says GMP is not installed, even though MPIR
> is||swan||#7025||4,5||
> ||linbox 1.1.6.p0 says GMP is not installed, even though MPIR
> is||swan||#7026||4,5||
> ||R sends the correct Sun flags to C and C++ compilers, but not
> Fortran||||#7035||||
> ||GAP purposely unsets CC which screws up Sun Studio build||||#7041||6||
> ||libm4ri thinks the C compiler is broken||swan||#7037||||
> ||rubiks ignores CXX and uses g++ even if CXX is Sun
> compiler||||#7036||7||
> ||ratpoints 2.1.2.p2 ignores CC and uses gcc whatever||||#7038||2||
> ||libfplll can't find _gmpz_init in -lgmp||||#7033||5||
> ||update libgcrypt to the latest version 1.4.4||||#7045||7||
> ||f2c ignores CC and uses gcc anyway||||#7027||2||
> ||PolyBoRi pass GNU specific options to the Sun compiler||||#7034||8||
> ||quaddouble-2.2.p9 believe Sun's C++ compiler is broken||||#7030||9||
> ||singular believe Sun's C++ compiler is broken||||#7031||9||
> ||Sun C++ compiler does not accept pynac C++ code||||#7029||||
> ||matplotlib 0.99.0 tries to use C compiler for C++ code.||||#7028||||
> ||cliquer-1.2 ignores CC and uses gcc instead of Sun
> compiler.||swan||#7057||10||
> ||''linbox reports "using frickin' slow GSL C-blas" if building with Sun
> Studio compiler''||||#7058||11||
> ||update libgcrypt to the latest version 1.4.4||||#7045||7||
> ||ECL snapshot of 13th Sept 2009 fails with Sun Studio 12.1||||#7062||
> ||lcalc fails - Sun Studio compiler does not accept code. (I'm not
> surprised)||||#7065||12||
> ||sympow ignores CC and uses gcc even when CC is set to Sun's
> compiler||||#7066||||
> ||cddlib 094f fails to build with Sun Studio - fabs() unresolved.
> Probably needs -lm||||#7067||13||
> ||gfan 0.3.p4 Shows numerous missing header files with Sun
> compiler.||||#7068||||
> ||tachyon-0.98beta.p9 ignores CC and uses gcc, so can't build with Sun
> Studio. Also uses -O6 which might be dangerous.||||#7069||||
> ||palp-1.1.p1 ignores CC variable and uses gcc, so fails with Sun
> Studio.||||#7071||||
> ||scipy 0.7.p2 has a GNUism, sending GNU flags to the Sun
> compiler.||||#7072||||
> ||scipy_sandbox 20071020.p4 has a GNUism, sending GNU flags to the Sun
> compiler.||||#7073||||
> ||cvxopt-0.9.p8 sends GNU options to Sun Fortran compiler and has bad C
> code.||||#7074||||
> ||Update sqlite to latest release - needed for Sun's
> compiler||||#6759||7||
> ||Error building 'modified sage library code' when including
> paripriv.h||||#6579||14||
>
> '''Notes'''
>
> 1) This update should have benefits to Sage on any platform, with any
> compiler. It is however '''absolutely essential''' this is fixed for Sun
> Studio.
>
> 2) Although discovered when testing with Sun Studio, the bug relates to
> the failure of a program to properly observe CC, CXX or SAGE_FORTRAN, so
> it can be expected to exist with any compiler.
>
> 3) The core dump was observed on hostname 'swan'. The failure to observe
> CC can be expected on any platform, but dumping core may be only on this
> machine.
>
> 4) Checked only on the hostname. This may or may not be specific to that
> machine.
>
> 5) Tickets #7025, #7026 and #7033 are very closely related, as they all
> relate to a failure of a program to reconsise GMP being installed. Of
> course, it is not installed, but MPIR is, which is a substitute.
>
> 6) Although easy to fix, to do some introduces a major impact on the time
> to build Sage.
>
> 7) A fix is available, but either awaiting review, needing work, or
> reviewed and awaiting to be in the next release.
>
> 8) This uses SCons, and in general anything using SCons appears to be a
> problem on Solaris.
>
> 9) #7030 and #7031 are closely related, as both believe the Sun C++
> compiler is broken, which it is not.
>
> 10) cliquer is seriously messed up, sometimes using gcc when you want it
> to use cc, and other times trying to use cc when you want it to use gcc!
> I believe it is incorrect use of SCons, so CC and CXX are not set
> properly.
>
> 11) This does not actually prevent linbox building, but is just an
> indication performance will sufffer. Later ticket #7026 will cause the
> build to fail when using Sun Studio.
>
> 12) gcc gives tons of warnings with this code, so I'm not at all
> surprised the Sun compiler rejects it. The author should be encouraged to
> sort out why his/her code should generate so many warnings/errors.
>
> 13) The fix looks quite easy.
>
> 14) This stops Sage building with gcc too, though one can circumvent this
> by commenting out 3 lines. The effect of commenting these out is not
> known.

New description:

 '''Introduction'''

 Sun's compiler on Solaris produces faster code than gcc, and is more
 reliable with 64-bit code than gcc. This ticket outlines the issues that
 need to be resolved to get Sage to build on Sun Studio, and are specific
 to Sun Studio. As more are discovered, I'll add them to the description,
 so it's easy to them all, rather than find them buried well down the page.

 In many cases, the bugs can potentially affect all compilers, but are only
 observed on Sun Studio.

 '''Hardware used for testing'''

 Attempts were made to build Sage on the following two Solaris machines.
 Where a problem is detected on only one, or is suspect it might occur on
 only one machine, then the hostname is stated.

 
||'''Hostname'''||'''Hardware'''||'''Processor'''||'''CPUs'''||'''Cores'''||'''Speed'''||'''Architecture'''||'''OS
 version'''||Compiler||
 ||swan||Sun Blade 2000||UltraSPARC-III+||2||2||1200 MHz||sun4u||Solaris 10
 update 7||Sun Studio 12.1||
 ||t2||Sun T5240||SPARC T2+||2||16||1167 MHz||sun4v||Solaris 10 update
 7||Sun Studio 12||


 '''Bugs'''

 The actual bugs found, along with the trac number are listed below. The
 hostname is stated it if might be relevant.

 If the description is in italics, and marked with note number 11, then the
 problem in itself would not prevent Sage being built with Sun Studio, but
 would impact performance adversely.

 ||'''Description'''||'''hostname'''||'''Trac #'''||'''Note(s)'''||

 ||Update prereq from 0.3 to 0.4||||#7021||1,7||
 ||zn_poly-0.9 uses gcc, irrespective of setting of CC||||#7039||2||
 ||symmetrica ignores CC||||#7032||2||
 ||ATLAS ignores CC variable, then dumps core when trying to build with Sun
 Studio on Solaris||swan||#7048||2,3||
 ||Flint ignores CC and CXX||||#7024||2||
 ||lapack sends GNU option -fPIC to Sun fortran compiler||||#7047||||
 ||eclib 20080310.p7 has code Sun's C++ compiler does not
 understand||||#7044||||
 ||Code actually in Sage (not other project) ignores CC and uses
 gcc||||#7040||2||
 ||ntl 5.4.2.p9 passes -fPIC to Sun linker with Sun Studio||||#7043||||
 ||givaro 3.2.13rc2 says GMP is not installed, even though MPIR
 is||swan||#7025||4,5||
 ||linbox 1.1.6.p0 says GMP is not installed, even though MPIR
 is||swan||#7026||4,5||
 ||R sends the correct Sun flags to C and C++ compilers, but not
 Fortran||||#7035||||
 ||GAP purposely unsets CC which screws up Sun Studio build||||#7041||6||
 ||libm4ri thinks the C compiler is broken||swan||#7037||||
 ||rubiks ignores CXX and uses g++ even if CXX is Sun
 compiler||||#7036||7||
 ||ratpoints 2.1.2.p2 ignores CC and uses gcc whatever||||#7038||2||
 ||libfplll can't find _gmpz_init in -lgmp||||#7033||5||
 ||update libgcrypt to the latest version 1.4.4||||#7045||7||
 ||f2c ignores CC and uses gcc anyway||||#7027||2||
 ||PolyBoRi pass GNU specific options to the Sun compiler||||#7034||8||
 ||quaddouble-2.2.p9 believe Sun's C++ compiler is broken||||#7030||9||
 ||singular believe Sun's C++ compiler is broken||||#7031||9||
 ||Sun C++ compiler does not accept pynac C++ code||||#7029||||
 ||matplotlib 0.99.0 tries to use C compiler for C++ code.||||#7028||||
 ||cliquer-1.2 ignores CC and uses gcc instead of Sun
 compiler.||swan||#7057||10||
 ||''linbox reports "using frickin' slow GSL C-blas" if building with Sun
 Studio compiler''||||#7058||11||
 ||update libgcrypt to the latest version 1.4.4||||#7045||7||
 ||ECL snapshot of 13th Sept 2009 fails with Sun Studio 12.1||||#7062||
 ||lcalc fails - Sun Studio compiler does not accept code. (I'm not
 surprised)||||#7065||12||
 ||sympow ignores CC and uses gcc even when CC is set to Sun's
 compiler||||#7066||||
 ||cddlib 094f fails to build with Sun Studio - fabs() unresolved. Probably
 needs -lm||||#7067||13||
 ||gfan 0.3.p4 Shows numerous missing header files with Sun
 compiler.||||#7068||||
 ||tachyon-0.98beta.p9 ignores CC and uses gcc, so can't build with Sun
 Studio. Also uses -O6 which might be dangerous.||||#7069||||
 ||palp-1.1.p1 ignores CC variable and uses gcc, so fails with Sun
 Studio.||||#7071||||
 ||scipy 0.7.p2 has a GNUism, sending GNU flags to the Sun
 compiler.||||#7072||||
 ||scipy_sandbox 20071020.p4 has a GNUism, sending GNU flags to the Sun
 compiler.||||#7073||||
 ||cvxopt-0.9.p8 sends GNU options to Sun Fortran compiler and has bad C
 code.||||#7074||||
 ||Update sqlite to latest release - needed for Sun's
 compiler||||#6759||7||
 ||Error building 'modified sage library code' when including
 paripriv.h||||#6579||14||
 ||libm4ri thinks the C compiler is broken||||#7037||||

 '''Notes'''

 1) This update should have benefits to Sage on any platform, with any
 compiler. It is however '''absolutely essential''' this is fixed for Sun
 Studio.

 2) Although discovered when testing with Sun Studio, the bug relates to
 the failure of a program to properly observe CC, CXX or SAGE_FORTRAN, so
 it can be expected to exist with any compiler.

 3) The core dump was observed on hostname 'swan'. The failure to observe
 CC can be expected on any platform, but dumping core may be only on this
 machine.

 4) Checked only on the hostname. This may or may not be specific to that
 machine.

 5) Tickets #7025, #7026 and #7033 are very closely related, as they all
 relate to a failure of a program to reconsise GMP being installed. Of
 course, it is not installed, but MPIR is, which is a substitute.

 6) Although easy to fix, to do some introduces a major impact on the time
 to build Sage.

 7) A fix is available, but either awaiting review, needing work, or
 reviewed and awaiting to be in the next release.

 8) This uses SCons, and in general anything using SCons appears to be a
 problem on Solaris.

 9) #7030 and #7031 are closely related, as both believe the Sun C++
 compiler is broken, which it is not.

 10) cliquer is seriously messed up, sometimes using gcc when you want it
 to use cc, and other times trying to use cc when you want it to use gcc! I
 believe it is incorrect use of SCons, so CC and CXX are not set properly.

 11) This does not actually prevent linbox building, but is just an
 indication performance will sufffer. Later ticket #7026 will cause the
 build to fail when using Sun Studio.

 12) gcc gives tons of warnings with this code, so I'm not at all surprised
 the Sun compiler rejects it. The author should be encouraged to sort out
 why his/her code should generate so many warnings/errors.

 13) The fix looks quite easy.

 14) This stops Sage building with gcc too, though one can circumvent this
 by commenting out 3 lines. The effect of commenting these out is not
 known.

--

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/7056#comment:11>
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].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=.


Reply via email to