suitesparse stable port information

Package: suitesparse
Version: 3.6.1
Revision: 1
Source: http://www.cise.ufl.edu/research/sparse/SuiteSparse/SuiteSparse-%v.tar.gz
Source-MD5: 88a44890e8f61cdbb844a76b7259d876
SourceDirectory: SuiteSparse
BuildDepends: fink (>= 0.24.12)
Conflicts: %n-metis
Replaces: %n-metis
BuildConflicts: coreutils-default

PatchFile: %n.patch
PatchFile-MD5: 6afa1a57d31746042d4183207f2de947
PatchScript: <<
%{default_script}
sed -i.bak -e 's,^CFLAGS = -O,&3 -fstrict-aliasing,' C{,X}Sparse/Lib/Makefile
sed -i -e 's|-no-cpp-precomp||g' ./UFconfig/UFconfig.mk
<<
# avoid race condidtion
UseMaxBuildJobs: false
CompileScript: <<
#! /bin/sh -ev
# Compile SuiteSparse without METIS.
export METIS_PREFIX=
export CHOLMOD_CONFIG='-DNPARTITION'
echo **** Start: Message from SuiteSparse CompileScript ****
echo Compiling SuiteSparse WITHOUT METIS
echo METIS_PREFIX = $METIS_PREFIX
echo CHOLMOD_CONFIG = $CHOLMOD_CONFIG
echo **** Stop: Message from SuiteSparse CompileScript ****
make default
<<
InstallScript: <<
#! /bin/sh -ev

install -d %i/lib
find . -name 'lib*.a' -exec install -m 644 \{\} %i/lib \;
rm %i/lib/libcsparse.a
ranlib %i/lib/lib*.a

install -d %i/include/%N
install -p -m 644 \
`find . -name '*.h'|egrep -v '^\./(CSparse/|CXSparse_n|UMFPACK/Source/)|/(MATLAB|Demo|Tcov)/|_(internal|version)\.h$'` \
%i/include/%N

for f in `ls -1 {,*/,CHOLMOD/*/}*.txt|egrep -v '_newfiles|MATLAB'|sed -e 's,^,./,' -e 's,/[^/]*$,,'|sort -u`
do install -d %i/share/doc/%n/$f; install -p -m 644 $f/*.txt %i/share/doc/%n/$f; done
for f in `ls -1d */Doc|fgrep -v _newfiles|sed -e 's,/[^/]*$,,'`
do install -d %i/share/doc/%n/$f; install -p -m 644 $f/Doc/* %i/share/doc/%n/$f; done

cd %i/share/doc/%n
# replace duplicates by symlinks
for n in lesser gpl; do
l=`ls -1 {,*/}*/$n.txt`
target=`tail -n1<<<"$l"`
list=`sed -e '$d'<<<"$l"`
for f in $list; do g=`sed -e 's,[^/]\+,..,g' -e 's,\.\.$,,' <<<"$f"`; ln -fs $g$target $f; done
done
# clean up
find . \( -name Makefile \
-o -name '*.bib' -o -name '*.tex' -o -name '*.stex' -o -name '*.sed*' -o -name '*.awk' -o -name '*diff' -o -name '*proto' \
\) -exec rm \{\} \;
cd -
<<
Description: Suite of Sparse matrix packages
License: GPL/LGPL
Maintainer: Jack Howarth
Homepage: http://www.cise.ufl.edu/research/sparse/SuiteSparse/

suitesparse stable port .patch

diff -uNr SuiteSparse/KLU/Include/klu_internal.h SuiteSparse.patched/KLU/Include/klu_internal.h
--- SuiteSparse/KLU/Include/klu_internal.h 2009-03-24 14:55:04.000000000 -0400
+++ SuiteSparse.patched/KLU/Include/klu_internal.h 2011-07-24 09:50:47.000000000 -0400
@@ -9,7 +9,6 @@

#include "klu.h"
#include "btf.h"
-#include "klu_version.h"

/* ========================================================================== */
/* make sure debugging and printing is turned off */
@@ -36,6 +35,8 @@
#include
#include
#include
+/* moved klu_version.h after math.h to circumvent compile error on ppc */
+#include "klu_version.h"

#undef ASSERT
#ifndef NDEBUG
diff -uNr SuiteSparse/UFconfig/UFconfig.mk SuiteSparse.patched/UFconfig/UFconfig.mk
--- SuiteSparse/UFconfig/UFconfig.mk 2011-05-10 16:47:15.000000000 -0400
+++ SuiteSparse.patched/UFconfig/UFconfig.mk 2011-07-24 09:53:37.000000000 -0400
@@ -54,7 +54,7 @@
F77LIB =

# C and Fortran libraries
-LIB = -lm
+# LIB = -lm

# For compiling MATLAB mexFunctions (MATLAB 7.5 or later)
MEX = mex -O -largeArrayDims -lmwlapack -lmwblas
@@ -91,8 +91,8 @@
# naming the BLAS and LAPACK library (*.a or *.so) files.

# This is probably slow ... it might connect to the Standard Reference BLAS:
-BLAS = -lblas -lgfortran
-LAPACK = -llapack
+# BLAS = -lblas -lgfortran
+# LAPACK = -llapack

# NOTE: this next option for the "Goto BLAS" has nothing to do with a "goto"
# statement. Rather, the Goto BLAS is written by Dr. Kazushige Goto.
@@ -132,13 +132,13 @@
# The path is relative to where it is used, in CHOLMOD/Lib, CHOLMOD/MATLAB, etc.
# You may wish to use an absolute path. METIS is optional. Compile
# CHOLMOD with -DNPARTITION if you do not wish to use METIS.
-METIS_PATH = ../../metis-4.0
-METIS = ../../metis-4.0/libmetis.a
+# METIS_PATH = ../../metis-4.0
+# METIS = ../../metis-4.0/libmetis.a

# If you use CHOLMOD_CONFIG = -DNPARTITION then you must use the following
# options:
-# METIS_PATH =
-# METIS =
+METIS_PATH =
+METIS =

#------------------------------------------------------------------------------
# UMFPACK configuration:
@@ -194,7 +194,7 @@
# -DNSUNPERF for Solaris only. If defined, do not use the Sun
# Performance Library

-CHOLMOD_CONFIG =
+CHOLMOD_CONFIG = -DNPARTITION

#------------------------------------------------------------------------------
# SuiteSparseQR configuration:
@@ -208,7 +208,7 @@
# -DHAVE_TBB enable the use of Intel's Threading Building Blocks (TBB)

# default, without timing, without TBB:
-SPQR_CONFIG =
+SPQR_CONFIG = -DNPARTITION
# with timing and TBB:
# SPQR_CONFIG = -DTIMING -DHAVE_TBB
# with timing
@@ -328,11 +328,11 @@
# Macintosh
#------------------------------------------------------------------------------

-# CC = gcc
-# CFLAGS = -O3 -fno-common -no-cpp-precomp -fexceptions
-# LIB = -lstdc++
-# BLAS = -framework Accelerate
-# LAPACK = -framework Accelerate
+CC = gcc
+CFLAGS = -O3 -fno-common -no-cpp-precomp -fexceptions
+LIB = -lstdc++
+BLAS = -framework Accelerate
+LAPACK = -framework Accelerate

#------------------------------------------------------------------------------
# IBM RS 6000

suitesparse _unstable_ port .patch