aboutsummaryrefslogtreecommitdiff
path: root/academic/metis
diff options
context:
space:
mode:
authorKyle Guinn <elyk03@gmail.com>2010-08-24 00:15:01 -0400
committerErik Hanson <erik@slackbuilds.org>2010-08-29 15:32:11 -0500
commit1fdd97021286188c2ec47939c0c2a0727c13ab10 (patch)
tree6a091a4fe8540c520ecdcc924f8ba46e33dcdf87 /academic/metis
parentd115764b92914556077db689dbf167404cf9070f (diff)
academic/metis: Added (matrix ordering)
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
Diffstat (limited to 'academic/metis')
-rw-r--r--academic/metis/README3
-rw-r--r--academic/metis/autotoolize.diff188
-rw-r--r--academic/metis/metis.SlackBuild82
-rw-r--r--academic/metis/metis.info10
-rw-r--r--academic/metis/slack-desc19
5 files changed, 302 insertions, 0 deletions
diff --git a/academic/metis/README b/academic/metis/README
new file mode 100644
index 000000000000..24efe7172884
--- /dev/null
+++ b/academic/metis/README
@@ -0,0 +1,3 @@
+METIS is a set of serial programs for partitioning graphs, partitioning
+finite element meshes, and producing fill reducing orderings for sparse
+matrices.
diff --git a/academic/metis/autotoolize.diff b/academic/metis/autotoolize.diff
new file mode 100644
index 000000000000..e9f868669562
--- /dev/null
+++ b/academic/metis/autotoolize.diff
@@ -0,0 +1,188 @@
+diff --git a/Doc/Makefile.am b/Doc/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Doc/Makefile.am
+@@ -0,0 +1,5 @@
++dist_noinst_DATA = manual.ps
++pdf_DATA = manual.pdf
++
++%.pdf: %.ps
++ ps2pdf $<
+diff --git a/Graphs/Makefile.am b/Graphs/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Graphs/Makefile.am
+@@ -0,0 +1,2 @@
++EXTRA_DIST = 0README
++dist_noinst_DATA = 4elt.graph metis.mesh test.mgraph
+diff --git a/Lib/Makefile.am b/Lib/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Lib/Makefile.am
+@@ -0,0 +1,61 @@
++pkgincludedir = $(includedir)/metis
++pkginclude_HEADERS = defs.h macros.h metis.h proto.h rename.h struct.h
++
++SRC = \
++ balance.c \
++ bucketsort.c \
++ ccgraph.c \
++ coarsen.c \
++ compress.c \
++ debug.c \
++ estmem.c \
++ fm.c \
++ fortran.c \
++ frename.c \
++ graph.c \
++ initpart.c \
++ kmetis.c \
++ kvmetis.c \
++ kwayfm.c \
++ kwayrefine.c \
++ kwayvolfm.c \
++ kwayvolrefine.c \
++ match.c \
++ mbalance.c \
++ mbalance2.c \
++ mcoarsen.c \
++ memory.c \
++ mesh.c \
++ meshpart.c \
++ mfm.c \
++ mfm2.c \
++ mincover.c \
++ minitpart.c \
++ minitpart2.c \
++ mkmetis.c \
++ mkwayfmh.c \
++ mkwayrefine.c \
++ mmatch.c \
++ mmd.c \
++ mpmetis.c \
++ mrefine.c \
++ mrefine2.c \
++ mutil.c \
++ myqsort.c \
++ ometis.c \
++ parmetis.c \
++ pmetis.c \
++ pqueue.c \
++ refine.c \
++ separator.c \
++ sfm.c \
++ srefine.c \
++ stat.c \
++ subdomains.c \
++ timing.c \
++ util.c
++
++lib_LTLIBRARIES = libmetis.la
++libmetis_la_SOURCES = $(SRC)
++libmetis_la_LIBADD = -lm
++libmetis_la_LDFLAGS = -no-undefined -version-info 4:1:0
+diff --git a/Makefile.am b/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Makefile.am
+@@ -0,0 +1,5 @@
++SUBDIRS = Lib Programs Graphs Test Doc
++EXTRA_DIST = CHANGES FILES INSTALL VERSION metis.pc.in
++
++pkgconfigdir = $(libdir)/pkgconfig
++pkgconfig_DATA = metis.pc
+diff --git a/Programs/Makefile.am b/Programs/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Programs/Makefile.am
+@@ -0,0 +1,23 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Lib
++LDADD = $(top_builddir)/Lib/libmetis.la
++
++bin_PROGRAMS = \
++ pmetis \
++ kmetis \
++ oemetis \
++ onmetis \
++ mesh2dual \
++ mesh2nodal \
++ partdmesh \
++ partnmesh \
++ graphchk
++
++pmetis_SOURCES = pmetis.c io.c
++kmetis_SOURCES = kmetis.c io.c
++oemetis_SOURCES = oemetis.c io.c smbfactor.c
++onmetis_SOURCES = onmetis.c io.c smbfactor.c
++mesh2dual_SOURCES = mesh2dual.c io.c
++mesh2nodal_SOURCES = mesh2nodal.c io.c
++partdmesh_SOURCES = partdmesh.c io.c
++partnmesh_SOURCES = partnmesh.c io.c
++graphchk_SOURCES = graphchk.c io.c
+diff --git a/Test/Makefile.am b/Test/Makefile.am
+new file mode 100644
+--- /dev/null
++++ b/Test/Makefile.am
+@@ -0,0 +1,11 @@
++AM_CPPFLAGS = -I$(top_srcdir)/Lib
++LDADD = $(top_builddir)/Lib/libmetis.la
++
++check_PROGRAMS = mtest
++mtest_SOURCES = mtest.c ../Programs/io.c
++
++GRAPHS = \
++ ../Graphs/4elt.graph
++
++check-local: $(check_PROGRAMS) $(GRAPHS)
++ -./mtest ../Graphs/4elt.graph
+diff --git a/configure.ac b/configure.ac
+new file mode 100644
+--- /dev/null
++++ b/configure.ac
+@@ -0,0 +1,31 @@
++AC_PREREQ([2.65])
++AC_INIT([METIS], [4.0.1], [karypis@cs.umn.edu])
++AC_CONFIG_SRCDIR([Lib/metis.h])
++AC_CONFIG_HEADER([config.h])
++AM_INIT_AUTOMAKE([foreign])
++LT_INIT
++
++AC_PROG_INSTALL
++AC_PROG_CC
++
++LIBS_SAVED=$LIBS
++
++AC_CHECK_LIB([m], [sqrt])
++
++AC_CHECK_HEADERS([malloc.h stdlib.h string.h strings.h])
++
++AC_FUNC_MALLOC
++AC_FUNC_REALLOC
++AC_CHECK_FUNCS([pow sqrt strtol])
++
++LIBS=$LIBS_SAVED
++
++AC_CONFIG_FILES([
++ Makefile
++ metis.pc
++ Doc/Makefile
++ Graphs/Makefile
++ Lib/Makefile
++ Programs/Makefile
++ Test/Makefile])
++AC_OUTPUT
+diff --git a/metis.pc.in b/metis.pc.in
+new file mode 100644
+--- /dev/null
++++ b/metis.pc.in
+@@ -0,0 +1,10 @@
++prefix=@prefix@
++exec_prefix=@exec_prefix@
++libdir=@libdir@
++includedir=@includedir@
++
++Name: @PACKAGE_NAME@
++Description: Software for partitioning unstructured graphs and meshes
++Version: @PACKAGE_VERSION@
++Libs: -L${libdir} -lmetis
++Cflags: -I${includedir}/metis
diff --git a/academic/metis/metis.SlackBuild b/academic/metis/metis.SlackBuild
new file mode 100644
index 000000000000..5416295ed93c
--- /dev/null
+++ b/academic/metis/metis.SlackBuild
@@ -0,0 +1,82 @@
+#!/bin/sh
+
+# Slackware build script for METIS
+# Written by Kyle Guinn <elyk03@gmail.com>
+
+PRGNAM=metis
+VERSION=${VERSION:-4.0.1}
+SRCVERSION=${SRCVERSION:-4.0}
+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="CHANGES FILES INSTALL VERSION"
+
+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-$SRCVERSION
+tar xvf $CWD/$PRGNAM-$SRCVERSION.tar.gz
+cd $PRGNAM-$SRCVERSION
+chown -R root:root .
+chmod -R u+w,go+r-w,a-st .
+
+# The C standard reserves all names that begin with underscores. Metis
+# ignores this and now we have naming conflicts with glibc. Right now only
+# __log2 conflicts, but this should fix the problem for good.
+sed -i 's/__/metis__/g' Lib/rename.h
+
+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/academic/metis/metis.info b/academic/metis/metis.info
new file mode 100644
index 000000000000..7d976ba7b234
--- /dev/null
+++ b/academic/metis/metis.info
@@ -0,0 +1,10 @@
+PRGNAM="metis"
+VERSION="4.0.1"
+HOMEPAGE="http://glaros.dtc.umn.edu/gkhome/metis/metis/overview"
+DOWNLOAD="http://glaros.dtc.umn.edu/gkhome/fetch/sw/metis/metis-4.0.tar.gz"
+MD5SUM="0aa546419ff7ef50bd86ce1ec7f727c7"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="Kyle Guinn"
+EMAIL="elyk03@gmail.com"
+APPROVED="dsomero"
diff --git a/academic/metis/slack-desc b/academic/metis/slack-desc
new file mode 100644
index 000000000000..9f198406852f
--- /dev/null
+++ b/academic/metis/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------------------------------------------------------|
+metis: METIS (serial graph partitioning and fill-reducing matrix ordering)
+metis:
+metis: METIS is a set of serial programs for partitioning graphs,
+metis: partitioning finite element meshes, and producing fill reducing
+metis: orderings for sparse matrices.
+metis:
+metis:
+metis:
+metis:
+metis:
+metis: