William Stein wrote:

> Also, the suggestion(s) to put the -m64 stuff in sage-env make a huge 
> amount of sense to me.  The more that is factored out and less redundant 
> in the spkg's the better.  In fact, that's a good general principle in 
> coding.

OK, so what should we factor out? (I'll use the GNU names here, as most 
people are more familiar with them, but my aim would be to use whatever 
is appropriate for the compiler. )

* -m64 :  We all agree on.
* -Wall : Seems sensible to me.
* -g : But with an environment variable to override that.
* -O3 : ???

If there was an environment variable SAGE_OPTIMIZATION, then one could 
use that instead of -O3. In fact, I'd probably set SAGE_OPTIMIZATION 
myself, to -O1 most of the time, to reduce compile time. (Though when I 
get my quad core 3.333 GHz Xeon, which is on order, perhaps comppile 
time will be less of an issue!!)


> This code below *should* have been in sage-env, not every single 
> spkg-install.  If that had been the case, I doubt you would be so 
> annoyed by it, since you could trivially just delete the Darwin part:
> 
> if [ `uname` = "Darwin" -a $SAGE64="yes"]
>  CFLAGS="$FLAGS -m64"
>  CXXFLAGS="$CXXFLAGS -m64"
> fi
> 

Very true.

It find it most annoying. Mainly since it only works on OS X, and 
Micheal new of plans for a 64-bit Solaris port. He would have also known 
the correct flag was -m64 on any compiler for any of the supported 
platforms.

It really would be beneficial to remove that SAGE64 stuff from every 
spkg-install.

> 
>     Hence it's probably safer to have each spkg-install start with
> 
>     CFLAGS=$SAGE64_CFLAG
> 
>     and add others as needed.
> 
> 
> This violates the "factor it out" rule.  In fact I am *highly* 
> suspicious of any sentence of the form "have each spkg-install ...".  If 
> there is anything that somebody wants to put in every spkg-install, then 
> it should be factored out. 

Yes, you have convinced me there.

> William Stein


--~--~---------~--~----~------------~-------~--~----~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel-unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to