sagemath / sage

Main repository of SageMath
https://www.sagemath.org
Other
1.38k stars 469 forks source link

rubiks ignores CXX and uses g++ even if CXX is Sun compiler #7036

Closed bac7d3ea-3f1b-4826-8464-f0b53d5e12d2 closed 14 years ago

bac7d3ea-3f1b-4826-8464-f0b53d5e12d2 commented 15 years ago

Using

CC was set to the Sun C compiler, CXX to the Sun C++ compiler and SAGE_FORTRAN to the Sun Fortran 95 compiler.

rubiks-20070912.p9 totally ignores the setting of CC, and uses gcc which it finds in the path. This is unfortunately not an uncommon problem.

rubiks-20070912.p9/src/dik/globals.h
rubiks-20070912.p9/src/dik/permcube.c
Finished extraction
****************************************************
Host system
uname -a:
SunOS swan 5.10 Generic_139555-08 sun4u sparc SUNW,Sun-Blade-1000
****************************************************
****************************************************
CC Version
/opt/xxxsunstudio12.1/bin/cc -v
usage: cc [ options] files.  Use 'cc -flags' for details
****************************************************
Building Rubiks cube solvers
make[2]: Entering directory `/export/home/drkirkby/sage/gcc32/sage-4.1.2.alpha2/spkg/build/rubiks-20070912.p9/src'
for dir in dietz/cu2 dietz/mcube dietz/solver dik reid; do \
        (cd ${dir} && make all)\
done
make[3]: Entering directory `/export/home/drkirkby/sage/gcc32/sage-4.1.2.alpha2/spkg/build/rubiks-20070912.p9/src/dietz/cu2'
g++ -O2 -c cu2.cpp
g++ -O2 -c main.cpp

Component: build

Keywords: GNUism gcc CC

Author: David Kirkby

Reviewer: Mike Hansen

Merged: sage-4.3.alpha0

Issue created by migration from https://trac.sagemath.org/ticket/7036

bac7d3ea-3f1b-4826-8464-f0b53d5e12d2 commented 15 years ago

Author: David Kirkby

bac7d3ea-3f1b-4826-8464-f0b53d5e12d2 commented 15 years ago
comment:3

Having looked at this package, I can see it was broken in numerous ways.

Basically, the makefiles were a total mess.

The revised .spkg has been tested on

There are now no hard-coded options, or compilers. Everything can be set from spkg-install, and is set sensibly. I've tested this with both 32 and 64-bit builds on Solaris, using both the GNU and Sun compilers. Also tested on sage.math. Also tested on bsd.math in both

The new spkg can be found here. http://sage.math.washington.edu/home/kirkby/Solaris-fixes/rubiks-20070912.p10/rubiks-20070912.p10.spkg

The spkg-install is here http://sage.math.washington.edu/home/kirkby/Solaris-fixes/rubiks-20070912.p10/spkg-install

The revised Makefiles, patches etc are in this directory:

http://sage.math.washington.edu/home/kirkby/Solaris-fixes/rubiks-20070912.p10

Be warned, the patches are bigger than the makefiles - the chances are so many.

mwhansen commented 14 years ago
comment:4

Looks good to me.

mwhansen commented 14 years ago

Reviewer: Mike Hansen

bac7d3ea-3f1b-4826-8464-f0b53d5e12d2 commented 14 years ago
comment:5

Since you gave this a positive review, I've changed the title from '[with spkg; needs review] ' to '[with spkg; positive review]'

Now this new radio button has been added to trac that allows one to specify a positive review, should one still add '[with spkg; needs review]' to the title, or the 'needs review' bit ignored?

Dave

mwhansen commented 14 years ago

Merged: sage-4.3.alpha0

3e348175-8b6a-4a61-a4ea-d4ccdaa8fd86 commented 13 years ago

Description changed:

--- 
+++ 
@@ -3,7 +3,7 @@
 * Solaris 10 update 7 on SPARC
 * sage-4.1.2.alpha2
 * Sun Studio 12.1
-* An updated configure script to allow the Sun compiler to be used http://sagetrac.org/sage_trac/ticket/7021 
+* An updated configure script to allow the Sun compiler to be used #7021 

 CC was set to the Sun C compiler, CXX to the Sun C++ compiler and SAGE_FORTRAN to the Sun Fortran 95 compiler.