# $Id: PKGBUILD 130989 2011-07-09 12:22:58Z ronald $ # Maintainer: Ronald van Haren # Contributor: Jan de Groot # Contributor: damir # Contributor: Jason Taylor pkgname=blas pkgver=3.3.1 pkgrel=2 url="http://www.netlib.org/blas" makedepends=('gcc-fortran') depends=('gcc-libs') pkgdesc="Basic Linear Algebra Subprograms" arch=('i686' 'x86_64' 'mips64el') license=("custom") source=(http://www.netlib.org/lapack/lapack-${pkgver}.tgz lapack-3.1.1-make.inc.patch Makefile.blas LICENSE.blas) sha1sums=('3ce437e05f0e9a3c8148ec41922f6efeef0ebdac' '71bf7696f1c841339163e82d863dd62e484eb1cf' '3dbee0a5e9a98a2ddf5a58046f5997804e9874ed' '2491a151a37f0162b25fc4e4e9a8ac444b574a76') build() { cd "${srcdir}/lapack-${pkgver}" cp -f "${srcdir}/Makefile.blas" BLAS/SRC/Makefile patch -Np1 -i "${srcdir}/lapack-3.1.1-make.inc.patch" cp -f INSTALL/make.inc.gfortran make.inc export FC=gfortran pushd BLAS/SRC make clean FFLAGS="${CFLAGS/-O?/-O0}" make dcabs1.o FFLAGS="${CFLAGS} -fPIC" CFLAGS="${CFLAGS} -fPIC" make shared cp libblas.so.${pkgver} "${srcdir}/lapack-${pkgver}/" popd ln -s libblas.so.${pkgver} libblas.so } package_blas() { install -m755 -d "${pkgdir}/usr/lib" install -m755 "${srcdir}/lapack-${pkgver}/libblas.so.${pkgver}" \ "${pkgdir}/usr/lib/" ln -sf libblas.so.${pkgver} "${pkgdir}/usr/lib/libblas.so" ln -sf libblas.so.${pkgver} "${pkgdir}/usr/lib/libblas.so.3" install -m755 -d "${pkgdir}/usr/share/licenses/blas" install -m644 "${srcdir}/LICENSE.blas" \ "${pkgdir}/usr/share/licenses/blas/LICENSE" }