69 lines
2.5 KiB
Text
69 lines
2.5 KiB
Text
|
#!/bin/sh
|
||
|
# sit class file
|
||
|
#
|
||
|
# Christoph Niethammer <niethammer@hlrs.de> (C) 2012
|
||
|
#
|
||
|
# laki sit command:
|
||
|
# PREFIX_BASE=/opt COMPILER=gnu COMPILER_VERSION=4.7.3 MPI=openmpi MPI_VERSION=1.6.5 ./sit numlib/zoltan/3.8-parmetis-4.0.3-scotch-6.0.0
|
||
|
#
|
||
|
# hermit sit command:
|
||
|
# PREFIX_BASE=/opt/hlrs COMPILER=pgi COMPILER_VERSION=13.9.0 ./sit numlib/zoltan/3.8-parmetis-4.0.3-scotch-6.0.0
|
||
|
|
||
|
CATEGORY="numlib"
|
||
|
PACKAGE="zoltan"
|
||
|
VERSION="3.8"
|
||
|
ADD_PACKAGES="parmetis-4.0.3-scotch-6.0.0"
|
||
|
URL="http://www.labri.fr/perso/pelegrin/scotch/"
|
||
|
INSTALLER="Elke Flehmig <flehmig@hlrs.de>"
|
||
|
|
||
|
# Archive A and package name P
|
||
|
A=${PACKAGE}_distrib_v${VERSION}.tar.gz
|
||
|
P=Zoltan_v${VERSION}
|
||
|
|
||
|
case $PLATFORM in
|
||
|
hermit|hermit1)
|
||
|
echo "Building for hermit."
|
||
|
# target prefix - show compiler version before additional packages:
|
||
|
PREFIX="${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$COMPILER-$COMPILER_VERSION-$ADD_PACKAGES"
|
||
|
|
||
|
SCOTCH=numlib/scotch/6.0.0
|
||
|
PARMETIS=numlib/parmetis/4.0.3
|
||
|
metis=numlib/metis/5.1.0
|
||
|
CC_CMD=cc
|
||
|
CXX_CMD=CC
|
||
|
;;
|
||
|
laki|*)
|
||
|
echo "Building for laki."
|
||
|
# target prefix - show mpi and compiler version before additional packages:
|
||
|
PREFIX="${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$MPI-$MPI_VERSION-$ADD_PACKAGES"
|
||
|
|
||
|
SCOTCH=numlib/scotch/6.0.0-openmpi-1.6.5-gnu-4.7.3
|
||
|
PARMETIS=numlib/parmetis/4.0.3-openmpi-1.6.5-gnu-4.7.3
|
||
|
METIS=numlib/metis/5.1.0
|
||
|
CC_CMD=mpicc
|
||
|
CXX_CMD=mpicxx
|
||
|
;;
|
||
|
esac
|
||
|
|
||
|
CONFIGURE_OPTS="CC=mpicc CXX=mpicxx --with-id-type=ullong --with-scotch --with-scotch-incdir=$PREFIX_BASE/$SCOTCH/include --with-scotch-libdir=$PREFIX_BASE/$SCOTCH/lib --with-parmetis --with-parmetis-incdir=$PREFIX_BASE/$PARMETIS/include --with-parmetis-libdir=$PREFIX_BASE/$PARMETIS/lib --with-libdirs=\"-L$PREFIX_BASE/$METIS/lib\" --with-incdirs=\"-I$PREFIX_BASE/$METIS/include\" --with-libs=\"-lscotch\""
|
||
|
|
||
|
src_pretest() {
|
||
|
sit_info "Checking zoltan ..."
|
||
|
make check || sit_fail "Checking zoltan failed"
|
||
|
}
|
||
|
|
||
|
src_postinst() {
|
||
|
# as examples and doc are already installed with zoltan, set a link:
|
||
|
cd $PREFIX
|
||
|
case $PLATFORM in
|
||
|
hermit|hermit1)
|
||
|
ln -s ${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$COMPILER-$COMPILER_VERSION/example
|
||
|
ln -s ${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$COMPILER-$COMPILER_VERSION/doc
|
||
|
;;
|
||
|
laki|*)
|
||
|
ln -s ${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$MPI-$MPI_VERSION/example
|
||
|
ln -s ${PREFIX_BASE}/${CATEGORY}/${PACKAGE}/${VERSION}-$MPI-$MPI_VERSION/doc
|
||
|
;;
|
||
|
esac
|
||
|
}
|