summaryrefslogtreecommitdiff
path: root/libraries
diff options
context:
space:
mode:
authorKyle Guinn <elyk03@gmail.com>2014-01-01 04:20:52 -0600
committerRobby Workman <rworkman@slackbuilds.org>2014-01-31 00:54:15 -0600
commit6f6e9bf6e8e94e54a08e46e20357eb513af48a9d (patch)
tree91b384405a0310c3a6a81ab6e0e525c16e7b46e2 /libraries
parent06d88577d57923b4599c47d57a9ac921cd3d0660 (diff)
downloadslackbuilds-6f6e9bf6e8e94e54a08e46e20357eb513af48a9d.tar.gz
libraries/KLU: Updated for version 1.2.1.
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'libraries')
-rw-r--r--libraries/KLU/KLU.SlackBuild25
-rw-r--r--libraries/KLU/KLU.info10
-rw-r--r--libraries/KLU/README3
-rw-r--r--libraries/KLU/autotoolize.diff195
4 files changed, 140 insertions, 93 deletions
diff --git a/libraries/KLU/KLU.SlackBuild b/libraries/KLU/KLU.SlackBuild
index db70e9b16d..b3337262a0 100644
--- a/libraries/KLU/KLU.SlackBuild
+++ b/libraries/KLU/KLU.SlackBuild
@@ -1,10 +1,29 @@
#!/bin/sh
# Slackware build script for KLU
-# Written by Kyle Guinn <elyk03@gmail.com>
+
+# Copyright 2013 Kyle Guinn <elyk03@gmail.com>, USA
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=KLU
-VERSION=${VERSION:-1.1.2}
+VERSION=${VERSION:-1.2.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -69,9 +88,11 @@ CFLAGS="$SLKCFLAGS" \
--docdir=/usr/doc/$PRGNAM-$VERSION \
--enable-shared \
--disable-static \
+ --disable-dependency-tracking \
--build=$ARCH-slackware-linux
make
+make check
make install-strip DESTDIR=$PKG
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
diff --git a/libraries/KLU/KLU.info b/libraries/KLU/KLU.info
index 0d64bfb4ce..309a759842 100644
--- a/libraries/KLU/KLU.info
+++ b/libraries/KLU/KLU.info
@@ -1,10 +1,10 @@
PRGNAM="KLU"
-VERSION="1.1.2"
-HOMEPAGE="http://www.cise.ufl.edu/research/sparse/klu/"
-DOWNLOAD="http://www.cise.ufl.edu/research/sparse/klu/KLU-1.1.2.tar.gz"
-MD5SUM="234ea0466d19559408bda3ab573bdef9"
+VERSION="1.2.1"
+HOMEPAGE="https://www.cise.ufl.edu/research/sparse/klu/"
+DOWNLOAD="https://www.cise.ufl.edu/research/sparse/klu/KLU-1.2.1.tar.gz"
+MD5SUM="3ab15b997a5c8fd37d33c290e03b29e5"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
-REQUIRES="BTF CHOLMOD"
+REQUIRES="%README% SuiteSparse_config AMD COLAMD BTF"
MAINTAINER="Kyle Guinn"
EMAIL="elyk03@gmail.com"
diff --git a/libraries/KLU/README b/libraries/KLU/README
index 61f613d070..fe8941f406 100644
--- a/libraries/KLU/README
+++ b/libraries/KLU/README
@@ -2,3 +2,6 @@ KLU is a sparse LU factorization algorithm well-suited for use in circuit
simulation.
This package is part of SuiteSparse.
+
+CHOLMOD is an optional dependency and will be used if found.
+It is primarily used for this package's test suite.
diff --git a/libraries/KLU/autotoolize.diff b/libraries/KLU/autotoolize.diff
index 690e34a9ed..a29a03a0ba 100644
--- a/libraries/KLU/autotoolize.diff
+++ b/libraries/KLU/autotoolize.diff
@@ -2,8 +2,8 @@ diff --git a/Demo/Makefile.am b/Demo/Makefile.am
new file mode 100644
--- /dev/null
+++ b/Demo/Makefile.am
-@@ -0,0 +1,44 @@
-+AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(BTF_CFLAGS) $(COLAMD_CFLAGS) $(CHOLMOD_CFLAGS)
+@@ -0,0 +1,46 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(COLAMD_CFLAGS) $(BTF_CFLAGS) $(CHOLMOD_CFLAGS)
+LDADD = $(top_builddir)/Source/libklu.la
+
+EXTRA_DIST = \
@@ -14,12 +14,13 @@ new file mode 100644
+# adding bogus dependencies for the .out files listed above.
+%.out: %
+
-+check_PROGRAMS = klu_simple kludemo kluldemo
-+
++check_PROGRAMS = klu_simple
+TESTS = klu_simple
-+
+klu_simple_SOURCES = klu_simple.c
+
++if CHOLMOD
++check_PROGRAMS += kludemo kluldemo
++
+kludemo_SOURCES = kludemo.c
+kludemo_LDADD = $(LDADD) $(CHOLMOD_LIBS) -lm
+
@@ -27,78 +28,85 @@ new file mode 100644
+kluldemo_LDADD = $(LDADD) $(CHOLMOD_LIBS) -lm
+
+MATRICES = \
-+ ../Matrix/1c.mtx \
-+ ../Matrix/arrowc.mtx \
-+ ../Matrix/arrow.mtx \
-+ ../Matrix/impcol_a.mtx \
-+ ../Matrix/w156.mtx \
-+ ../Matrix/ctina.mtx
++ $(top_srcdir)/Matrix/1c.mtx \
++ $(top_srcdir)/Matrix/arrowc.mtx \
++ $(top_srcdir)/Matrix/arrow.mtx \
++ $(top_srcdir)/Matrix/impcol_a.mtx \
++ $(top_srcdir)/Matrix/w156.mtx \
++ $(top_srcdir)/Matrix/ctina.mtx
+
+check-local: kludemo kluldemo $(MATRICES)
-+ -./kludemo < ../Matrix/1c.mtx
-+ -./kludemo < ../Matrix/arrowc.mtx
-+ -./kludemo < ../Matrix/arrow.mtx
-+ -./kludemo < ../Matrix/impcol_a.mtx
-+ -./kludemo < ../Matrix/w156.mtx
-+ -./kludemo < ../Matrix/ctina.mtx
-+ -./kluldemo < ../Matrix/1c.mtx
-+ -./kluldemo < ../Matrix/arrowc.mtx
-+ -./kluldemo < ../Matrix/arrow.mtx
-+ -./kluldemo < ../Matrix/impcol_a.mtx
-+ -./kluldemo < ../Matrix/w156.mtx
-+ -./kluldemo < ../Matrix/ctina.mtx
++ -./kludemo < $(top_srcdir)/Matrix/1c.mtx
++ -./kludemo < $(top_srcdir)/Matrix/arrowc.mtx
++ -./kludemo < $(top_srcdir)/Matrix/arrow.mtx
++ -./kludemo < $(top_srcdir)/Matrix/impcol_a.mtx
++ -./kludemo < $(top_srcdir)/Matrix/w156.mtx
++ -./kludemo < $(top_srcdir)/Matrix/ctina.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/1c.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/arrowc.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/arrow.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/impcol_a.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/w156.mtx
++ -./kluldemo < $(top_srcdir)/Matrix/ctina.mtx
++endif
diff --git a/Doc/Makefile.am b/Doc/Makefile.am
new file mode 100644
--- /dev/null
+++ b/Doc/Makefile.am
-@@ -0,0 +1,41 @@
-+# Generating KLU_UserGuide.pdf seems to be broken, so
-+# just distribute the copy that came in the tarball.
-+EXTRA_DIST = \
-+ ChangeLog \
-+ lesser.txt \
-+ palamadai_e.pdf \
-+ KLU_UserGuide.pdf
+@@ -0,0 +1,48 @@
++EXTRA_DIST = ChangeLog lesser.txt
+
+dist_noinst_DATA = KLU_UserGuide.tex KLU_UserGuide.bib
-+pdf_DATA = KLU_UserGuide.pdf palamadai_e.pdf
-+
-+#SRC = \
-+# klu_h.tex \
-+# btf_h.tex \
-+# klu_simple_c.tex
-+#
-+#klu_h.tex: ../Include/klu.h
-+# echo '\\begin{verbatim}' > $@
-+# expand -8 $< >> $@
-+# echo '\end{verbatim}' >> $@
-+#
-+## FIXME: Probably shouldn't rely on this location for btf.h.
++dist_pdf_DATA = KLU_UserGuide.pdf palamadai_e.pdf
++
++SRC = \
++ klu_h.tex \
++ btf_h.tex \
++ klu_simple_c.tex
++
++KLU_UserGuide.pdf KLU_UserGuide.aux: $(SRC)
++.INTERMEDIATE: KLU_UserGuide.aux $(SRC)
++
++define verbatim =
++echo '\begin{verbatim}' > $@
++expand -8 $< >> $@
++echo '\end{verbatim}' >> $@
++endef
++
++klu_h.tex: $(top_srcdir)/Include/klu.h
++ $(verbatim)
++
++# FIXME: We don't know the location of btf.h.
++# Insert a placeholder for now.
+#btf_h.tex: /usr/include/btf.h
-+# echo '\\begin{verbatim}' > $@
-+# expand -8 $< >> $@
-+# echo '\end{verbatim}' >> $@
-+#
-+#klu_simple_c.tex: ../Demo/klu_simple.c
-+# echo '\\begin{verbatim}' > $@
-+# expand -8 $< >> $@
-+# echo '\end{verbatim}' >> $@
-+#
-+#KLU_UserGuide.pdf: KLU_UserGuide.tex KLU_UserGuide.bib $(SRC)
-+# pdflatex KLU_UserGuide
-+# bibtex KLU_UserGuide
-+# pdflatex KLU_UserGuide
-+# pdflatex KLU_UserGuide
-+#
-+#clean-local:
-+# -$(RM) *.aux *.bbl *.blg *.log *.toc
-+# -$(RM) $(SRC)
++# $(verbatim)
++btf_h.tex:
++ echo '\begin{verbatim}' > $@
++ echo 'See your btf.h local install' >> $@
++ echo '\end{verbatim}' >> $@
++
++klu_simple_c.tex: $(top_srcdir)/Demo/klu_simple.c
++ $(verbatim)
++
++TEX = TEXINPUTS="$(srcdir):" pdflatex -interaction nonstopmode -file-line-error
++BIB = BIBINPUTS="$(srcdir):" bibtex
++%.pdf: %.tex %.bbl
++ $(TEX) $*
++ while grep -q "Rerun to get cross-references right" $*.log; do \
++ $(TEX) $*; \
++ done
++%.bbl: %.aux %.bib
++ $(BIB) $*
++%.aux: %.tex
++ $(TEX) $*
++
++CLEANFILES = *.aux *.bbl *.blg *.log *.toc $(SRC)
++MAINTAINERCLEANFILES = $(dist_pdf_DATA)
diff --git a/Include/Makefile.am b/Include/Makefile.am
new file mode 100644
--- /dev/null
+++ b/Include/Makefile.am
-@@ -0,0 +1,2 @@
-+pkgincludedir = $(includedir)/klu
+@@ -0,0 +1 @@
+pkginclude_HEADERS = klu.h klu_internal.h klu_version.h
diff --git a/Makefile.am b/Makefile.am
new file mode 100644
@@ -131,7 +139,7 @@ new file mode 100644
--- /dev/null
+++ b/Source/Makefile.am
@@ -0,0 +1,40 @@
-+AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(BTF_CFLAGS) $(COLAMD_CFLAGS)
++AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(COLAMD_CFLAGS) $(BTF_CFLAGS)
+
+noinst_LTLIBRARIES = libklud.la libkluz.la libklul.la libkluzl.la
+
@@ -169,68 +177,82 @@ new file mode 100644
+
+lib_LTLIBRARIES = libklu.la
+libklu_la_SOURCES =
-+libklu_la_LIBADD = libklud.la libkluz.la libklul.la libkluzl.la $(AMD_LIBS) $(BTF_LIBS) $(COLAMD_LIBS)
-+libklu_la_LDFLAGS = -no-undefined -version-info 2:2:1
++libklu_la_LIBADD = libklud.la libkluz.la libklul.la libkluzl.la $(AMD_LIBS) $(COLAMD_LIBS) $(BTF_LIBS)
++libklu_la_LDFLAGS = -no-undefined -version-number 1:2:1
diff --git a/User/Makefile.am b/User/Makefile.am
new file mode 100644
--- /dev/null
+++ b/User/Makefile.am
-@@ -0,0 +1,11 @@
-+AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(BTF_CFLAGS) $(COLAMD_CFLAGS) $(CHOLMOD_CFLAGS) $(UFCONFIG_CFLAGS)
+@@ -0,0 +1,12 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Include $(AMD_CFLAGS) $(COLAMD_CFLAGS) $(BTF_CFLAGS) $(CHOLMOD_CFLAGS) $(SUITESPARSECONFIG_CFLAGS)
+
+EXTRA_DIST = README.txt
+
-+pkgincludedir = $(includedir)/klu
++if CHOLMOD
+pkginclude_HEADERS = klu_cholmod.h
+
+lib_LTLIBRARIES = libklu_cholmod.la
+libklu_cholmod_la_SOURCES = klu_cholmod.c klu_l_cholmod.c
+libklu_cholmod_la_LIBADD = $(CHOLMOD_LIBS)
-+libklu_cholmod_la_LDFLAGS = -no-undefined -version-info 2:2:1
++libklu_cholmod_la_LDFLAGS = -no-undefined -version-number 1:2:1
++endif
diff --git a/configure.ac b/configure.ac
new file mode 100644
--- /dev/null
+++ b/configure.ac
-@@ -0,0 +1,49 @@
-+AC_PREREQ([2.68])
-+AC_INIT([KLU],[1.1.2],[davis@cise.ufl.edu])
+@@ -0,0 +1,62 @@
++# -*- Autoconf -*-
++# Process this file with autoconf to produce a configure script.
++
++AC_PREREQ([2.69])
++AC_INIT([KLU],[1.2.1],[DrTimothyAldenDavis@gmail.com],[klu],[http://www.suitesparse.com/])
+AC_CONFIG_SRCDIR([Source/klu.c])
-+AC_CONFIG_HEADER([config.h])
++AC_CONFIG_HEADERS([config.h])
+AM_INIT_AUTOMAKE([foreign])
+LT_INIT
+
++# Checks for programs.
+AC_PROG_INSTALL
+AC_PROG_CC
+
+LIBS_SAVED=$LIBS
+
++# Checks for libraries.
+AC_CHECK_LIB([m], [sqrt])
+
-+AC_CHECK_HEADERS([limits.h stdlib.h])
-+
+PKG_PROG_PKG_CONFIG
-+PKG_CHECK_MODULES([UFCONFIG],[ufconfig],
++PKG_CHECK_MODULES([SUITESPARSECONFIG],[suitesparseconfig],
+ [],
-+ [AC_MSG_ERROR([cannot find ufconfig])])
++ [AC_MSG_ERROR([cannot find suitesparseconfig])])
+PKG_CHECK_MODULES([AMD],[amd],
+ [],
+ [AC_MSG_ERROR([cannot find amd])])
-+PKG_CHECK_MODULES([BTF],[btf],
-+ [],
-+ [AC_MSG_ERROR([cannot find btf])])
+PKG_CHECK_MODULES([COLAMD],[colamd],
+ [],
+ [AC_MSG_ERROR([cannot find colamd])])
-+PKG_CHECK_MODULES([CHOLMOD],[cholmod],
++PKG_CHECK_MODULES([BTF],[btf],
+ [],
-+ [AC_MSG_ERROR([cannot find cholmod])])
++ [AC_MSG_ERROR([cannot find btf])])
++PKG_CHECK_MODULES([CHOLMOD],[cholmod],
++ [cholmod="yes"],
++ [cholmod="no"])
++if test "x$cholmod" != "xyes"; then
++ AC_MSG_WARN([cannot find cholmod, disabling some functionality])
++fi
++
++# Checks for header files.
++AC_CHECK_HEADERS([limits.h stdlib.h])
+
++# Checks for typedefs, structures, and compiler characteristics.
+AC_TYPE_SIZE_T
+
++# Checks for library functions.
+AC_CHECK_FUNCS([sqrt])
+
+LIBS=$LIBS_SAVED
+
++AM_CONDITIONAL([CHOLMOD], [test "x$cholmod" = "xyes"])
++
+AC_CONFIG_FILES([
+ klu.pc
+ Makefile
@@ -245,7 +267,7 @@ diff --git a/klu.pc.in b/klu.pc.in
new file mode 100644
--- /dev/null
+++ b/klu.pc.in
-@@ -0,0 +1,12 @@
+@@ -0,0 +1,13 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
@@ -254,7 +276,8 @@ new file mode 100644
+Name: @PACKAGE_NAME@
+Description: Sparse LU factorization for circuit simulation
+Version: @PACKAGE_VERSION@
-+Requires.private: amd btf colamd
++URL: @PACKAGE_URL@
++Requires.private: amd colamd btf
+Libs: -L${libdir} -lklu
+Libs.private: -lm
+Cflags: -I${includedir}/klu