summaryrefslogtreecommitdiffstats
path: root/libraries/AMD
diff options
context:
space:
mode:
author Kyle Guinn <elyk03@gmail.com>2010-08-23 23:58:38 -0400
committer Erik Hanson <erik@slackbuilds.org>2010-08-29 15:32:10 -0500
commit5b7e5746dde0c0a8bf91b885be04509b8e6820b4 (patch)
tree8539448aa1d1d6b954562d7016c745f9905c4c6c /libraries/AMD
parent44296cf70d6c95a39e9e4aa261701c6bbc30dad1 (diff)
downloadslackbuilds-5b7e5746dde0c0a8bf91b885be04509b8e6820b4.tar.gz
slackbuilds-5b7e5746dde0c0a8bf91b885be04509b8e6820b4.tar.xz
libraries/AMD: Added (sparse matrix ordering routines)
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'libraries/AMD')
-rw-r--r--libraries/AMD/AMD.SlackBuild76
-rw-r--r--libraries/AMD/AMD.info10
-rw-r--r--libraries/AMD/README8
-rw-r--r--libraries/AMD/autotoolize.diff158
-rw-r--r--libraries/AMD/slack-desc19
5 files changed, 271 insertions, 0 deletions
diff --git a/libraries/AMD/AMD.SlackBuild b/libraries/AMD/AMD.SlackBuild
new file mode 100644
index 0000000000..c677c09cac
--- /dev/null
+++ b/libraries/AMD/AMD.SlackBuild
@@ -0,0 +1,76 @@
+#!/bin/sh
+
+# Slackware build script for AMD
+# Written by Kyle Guinn <elyk03@gmail.com>
+
+PRGNAM=AMD
+VERSION=${VERSION:-2.2.1}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$(uname -m)" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$(uname -m) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+DOCS="README.txt Doc/ChangeLog Doc/License Doc/lesser.txt"
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM
+chown -R root:root .
+chmod -R u+w,go+r-w,a-st .
+
+patch -p1 < $CWD/autotoolize.diff
+autoreconf -vif
+
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+./configure \
+ --prefix=/usr \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ --mandir=/usr/man \
+ --docdir=/usr/doc/$PRGNAM-$VERSION \
+ --build=$ARCH-slackware-linux
+
+make
+make install-strip DESTDIR=$PKG
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/libraries/AMD/AMD.info b/libraries/AMD/AMD.info
new file mode 100644
index 0000000000..dbfbb1598e
--- /dev/null
+++ b/libraries/AMD/AMD.info
@@ -0,0 +1,10 @@
+PRGNAM="AMD"
+VERSION="2.2.1"
+HOMEPAGE="http://www.cise.ufl.edu/research/sparse/amd/"
+DOWNLOAD="http://www.cise.ufl.edu/research/sparse/amd/AMD-2.2.1.tar.gz"
+MD5SUM="b3e9679ba20635ac4847f01c01d6e992"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="Kyle Guinn"
+EMAIL="elyk03@gmail.com"
+APPROVED="dsomero"
diff --git a/libraries/AMD/README b/libraries/AMD/README
new file mode 100644
index 0000000000..b41e9df179
--- /dev/null
+++ b/libraries/AMD/README
@@ -0,0 +1,8 @@
+AMD is a set of routines for ordering a sparse matrix prior to Cholesky
+factorization (or for LU factorization with diagonal pivoting). There are
+versions in both C and Fortran. Note that this software has nothing to do
+with AMD the company. This package runs on any platform.
+
+This package is part of SuiteSparse.
+
+Requires UFconfig.
diff --git a/libraries/AMD/autotoolize.diff b/libraries/AMD/autotoolize.diff
new file mode 100644
index 0000000000..1bc7eeefec
--- /dev/null
+++ b/libraries/AMD/autotoolize.diff
@@ -0,0 +1,158 @@
+diff --git a/Demo/Makefile.am b/Demo/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Demo/Makefile.am
+@@ -0,0 +1,54 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Include
++LDADD = $(top_builddir)/Source/libamd.la
++
++EXTRA_DIST = \
++ amd_demo.out \
++ amd_demo2.out \
++ amd_l_demo.out \
++ amd_simple.out \
++ amd_f77cross.out \
++ amd_f77demo.out \
++ amd_f77simple.out
++
++# Disable the .out implicit pattern rule. Prevents GNU make from
++# adding bogus dependencies for the .out files listed above.
++%.out: %
++
++check_PROGRAMS = \
++ amd_demo \
++ amd_demo2 \
++ amd_l_demo \
++ amd_simple \
++ amd_f77cross \
++ amd_f77demo \
++ amd_f77simple
++
++amd_demo_SOURCES = amd_demo.c
++amd_demo2_SOURCES = amd_demo2.c
++amd_l_demo_SOURCES = amd_l_demo.c
++amd_simple_SOURCES = amd_simple.c
++
++check_LTLIBRARIES = libamd_f77wrapper.la
++libamd_f77wrapper_la_SOURCES = amd_f77wrapper.c
++libamd_f77wrapper_la_CPPFLAGS = $(AM_CPPFLAGS) -DDINT
++
++amd_f77cross_SOURCES = amd_f77cross.f
++amd_f77cross_LDADD = $(LDADD) $(top_builddir)/Source/libamdf77.la libamd_f77wrapper.la
++amd_f77demo_SOURCES = amd_f77demo.f
++amd_f77demo_LDADD = $(LDADD) $(top_builddir)/Source/libamdf77.la
++amd_f77simple_SOURCES = amd_f77simple.f
++amd_f77simple_LDADD = $(LDADD) $(top_builddir)/Source/libamdf77.la
++
++check-local: $(check_PROGRAMS) $(check_PROGRAMS:=.out)
++ @for i in $(check_PROGRAMS); do \
++ echo "Testing $$i"; \
++ ./$$i$(EXEEXT) > my_$$i.out; \
++ if diff -u $$i.out my_$$i.out; then \
++ echo "Test $$i PASSED."; \
++ else \
++ echo "Test $$i FAILED."; \
++ fi; \
++ done
++
++clean-local:
++ -$(RM) my_*.out
+diff --git a/Doc/Makefile.am b/Doc/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Doc/Makefile.am
+@@ -0,0 +1,13 @@
++EXTRA_DIST = ChangeLog License lesser.txt
++
++dist_noinst_DATA = AMD_UserGuide.tex AMD_UserGuide.bib
++pdf_DATA = AMD_UserGuide.pdf
++
++%.pdf: %.tex %.bib
++ pdflatex $*
++ bibtex $*
++ pdflatex $*
++ pdflatex $*
++
++clean-local:
++ -$(RM) *.aux *.bbl *.blg *.log *.toc
+diff --git a/Makefile.am b/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Makefile.am
+@@ -0,0 +1,3 @@
++SUBDIRS = Source Demo Doc
++EXTRA_DIST = README.txt
++include_HEADERS = Include/amd.h Include/amd_internal.h
+diff --git a/Source/Makefile.am b/Source/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Source/Makefile.am
+@@ -0,0 +1,33 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Include
++
++AMDSRC = \
++ amd_1.c \
++ amd_2.c \
++ amd_aat.c \
++ amd_control.c \
++ amd_defaults.c \
++ amd_dump.c \
++ amd_info.c \
++ amd_order.c \
++ amd_postorder.c \
++ amd_post_tree.c \
++ amd_preprocess.c \
++ amd_valid.c
++
++lib_LTLIBRARIES = libamd.la libamdf77.la
++noinst_LTLIBRARIES = libamdi.la libamdl.la
++
++libamdi_la_SOURCES = $(AMDSRC)
++libamdi_la_LIBADD = -lm
++libamdi_la_CPPFLAGS = $(AM_CPPFLAGS) -DDINT
++
++libamdl_la_SOURCES = $(AMDSRC)
++libamdl_la_LIBADD = -lm
++libamdl_la_CPPFLAGS = $(AM_CPPFLAGS) -DDLONG
++
++libamd_la_SOURCES = amd_global.c
++libamd_la_LIBADD = libamdl.la libamdi.la
++libamd_la_LDFLAGS = -no-undefined -version-info 4:1:2
++
++libamdf77_la_SOURCES = amd.f amdbar.f
++libamdf77_la_LDFLAGS = -no-undefined -version-info 4:1:2
+diff --git a/configure.ac b/configure.ac
+new file mode 100644
+--- /dev/null
++++ b/configure.ac
+@@ -0,0 +1,30 @@
++AC_PREREQ([2.65])
++AC_INIT([AMD], [2.2.1], [davis@cise.ufl.edu])
++AC_CONFIG_SRCDIR([Source/amd_global.c])
++AC_CONFIG_HEADER([config.h])
++AM_INIT_AUTOMAKE([foreign])
++LT_INIT
++
++AC_PROG_INSTALL
++AC_PROG_CC
++AC_PROG_F77
++
++LIBS_SAVED=$LIBS
++
++AC_CHECK_LIB([m], [sqrt])
++
++AC_CHECK_HEADERS([limits.h stddef.h stdlib.h])
++AC_CHECK_HEADERS([UFconfig.h])
++
++AC_TYPE_SIZE_T
++
++AC_CHECK_FUNCS([sqrt])
++
++LIBS=$LIBS_SAVED
++
++AC_CONFIG_FILES([
++ Makefile
++ Demo/Makefile
++ Doc/Makefile
++ Source/Makefile])
++AC_OUTPUT
diff --git a/libraries/AMD/slack-desc b/libraries/AMD/slack-desc
new file mode 100644
index 0000000000..deae94e5af
--- /dev/null
+++ b/libraries/AMD/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+AMD: AMD (sparse matrix ordering routines)
+AMD:
+AMD: AMD is a set of routines for ordering a sparse matrix prior to
+AMD: Cholesky factorization (or for LU factorization with diagonal
+AMD: pivoting). There are versions in both C and Fortran. Note that
+AMD: this software has nothing to do with AMD the company. This package
+AMD: runs on any platform.
+AMD:
+AMD:
+AMD:
+AMD: