Hey Francois. I too thought that perhaps the spkg supplied flags would override any changes with custom flags. However the custom flags seem to be appended to the spkg provided ones. For example
with custom CFLAGS building 'sage.algebras.quatalg.quaternion_algebra_element' extension gcc -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -march=opteron - O2 -pipe -fPIC with CFLAGS unset building 'sage.algebras.quatalg.quaternion_algebra_element' extension gcc -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict- prototypes -fPIC The no-strict-aliasing get's lost! I'll give your suggestion a whirl, but it will take some time to rebuild things. Steve On Dec 1, 4:06 am, François Bissey <f.r.bis...@massey.ac.nz> wrote: > On Tue, 01 Dec 2009 14:42:43 strogdon wrote: > > > Now when I unpack the sage-4.2.1.spkg tarball and insert > > > unset CFLAGS > > unset CXXFLAGS > > > near the top of the spkg-install script, repackage the tarball and > > issue the above 'make' with custom CFLAGS; both sage and the > > documentation build and 'sage -c quit' returns no errors. By altering > > spkg-install in the above fashion every package in sage is exposed to > > the custom CFLAGS with the exception of sage-4.2.1.spkg. A similar > > hack to unset CFLAGS for the amd64 architecture > > is utilized by Christopher Schwan and Francois Bissey (http:// > > github.com/cschwan/sage-on-gentoo) to build a partially split sage. It > > would appear that these custom amd64 flags cannot be used to > > successfully build the sage-4.2.1.spkg tarball. Is there any known > > reason why these custom CFLAGS cannot be used? Gentoo custom flags for > > 32 bit architectures do not seem to have this build problem. On an > > amd64 laptop I have, the CFLAGS setting > > > CFLAGS="-march=k8 -O2 -pipe" > > > also results in a sage that fails. > > I am biting Steve. The current filtering in the ebuild is a terribly > gross. We have compiler flag filtering functions. > Although I think your question is interesting some flags cause > a failure in the compilation of the sage spkg (doesn't spkg-install > provide its own flags overriding yours?). > We should try to find what exactly is causing the fault. Can you try without > the -march=k8 please? If you are using >=gcc-4.3 could you also try > -march=native? > > Francois -- 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