Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Maintainer: George Eleftheriou <eleftg>
- # Contributor: Jed Brown <jed@59A2.org>
- pkgname=mpich
- pkgver=3.0
- pkgrel=4
- pkgdesc="An improved implementation of the Message Passing Interface."
- url="https://mpich.org"
- arch=("any")
- license=("custom")
- depends=('python2' 'gcc-fortran' 'libxml2' 'openssh' 'numactl' 'pciutils')
- makedepends=('texlive-core' 'sowing')
- optdepends=("java-environment")
- install="${pkgname}.install"
- source=("http://www.mpich.org/static/downloads/${pkgver}/${pkgname}-${pkgver}.tar.gz"
- "mpich.profile")
- sha256sums=('3aa763585a589393319e8b4f19e46010d5b5e7c5935657027671fff4d1c7d349'
- 'b9716441a544511bf88618edeb40c3eb80f1b5d0d9369c30d750251feed02284')
- options=('!libtool')
- build() {
- cd ${srcdir}/${pkgname}-${pkgver}
- # CFLAGS etc are normally written into the wrapper compilers. This
- # gives surprising results, e.g. when the user wants to compile their
- # program without optimization.
- export MPICHLIB_CFLAGS="${CFLAGS}"; unset CFLAGS
- export MPICHLIB_CXXFLAGS="${CXXFLAGS}"; unset CXXFLAGS
- export MPICHLIB_CPPFLAGS="${CPPFLAGS}"; unset CPPFLAGS
- export MPICHLIB_FFLAGS="${FFLAGS}"; unset FFLAGS
- export MPICHLIB_F90FLAGS="${F90FLAGS}"; unset F90FLAGS
- export MPICHLIB_LDFLAGS="${LDFLAGS}"; unset LDFLAGS
- mkdir -p build
- cd build
- ../configure --prefix=/opt/mpich --enable-shared --enable-sharedlibs=gcc \
- --enable-error-checking=runtime --enable-error-messages=all \
- --enable-timer-type=clock_gettime \
- --with-python=python2
- make
- make mandoc
- }
- check() {
- cd ${srcdir}/${pkgname}-${pkgver}/build
- # CFLAGS etc are normally written into the wrapper compilers. This
- # gives surprising results, e.g. when the user wants to compile their
- # program without optimization.
- export MPICHLIB_CFLAGS=${CFLAGS}; unset CFLAGS
- export MPICHLIB_CXXFLAGS=${CXXFLAGS}; unset CXXFLAGS
- export MPICHLIB_CPPFLAGS=${CPPFLAGS}; unset CPPFLAGS
- export MPICHLIB_FFLAGS=${FFLAGS}; unset FFLAGS
- export MPICHLIB_F90FLAGS=${F90FLAGS}; unset F90FLAGS
- export MPICHLIB_LDFLAGS=${LDFLAGS}; unset LDFLAGS
- make check
- }
- package() {
- cd "${srcdir}/${pkgname}-${pkgver}/build"
- make DESTDIR="${pkgdir}" install
- ln -sf mpiexec.hydra "${pkgdir}/opt/mpich/bin/mpiexec"
- ln -sf mpiexec "${pkgdir}/opt/mpich/bin/mpirun"
- ln -sf mpiexec.hydra "${pkgdir}/opt/mpich/bin/mpirun.hydra"
- install -D -m644 "${srcdir}/${pkgname}-${pkgver}/COPYRIGHT" "${pkgdir}/usr/share/licenses/mpich/license.txt"
- install -D -m755 "${srcdir}/${pkgname}.profile" "${pkgdir}/etc/profile.d/mpich.sh"
- mkdir -p "${pkgdir}/etc/ld.so.conf.d"
- echo /opt/mpich/lib > "${pkgdir}/etc/ld.so.conf.d/mpich.conf"
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement